gemini-testing / png-img

Lite libpng wrapper for node.js
MIT License
29 stars 13 forks source link

Isn't working with latest node 14 #58

Closed aTei closed 3 years ago

aTei commented 3 years ago

error /home/atei/Projects/halalbooking/node_modules/gemini-core/node_modules/png-img

gyp info it worked if it ends with ok
gyp info using node-gyp@5.1.0
gyp info using node@14.15.4 | linux | x64
gyp info find Python using Python version 2.7.17 found at "/usr/bin/python"
gyp http GET https://nodejs.org/download/release/v14.15.4/node-v14.15.4-headers.tar.gz
gyp http 200 https://nodejs.org/download/release/v14.15.4/node-v14.15.4-headers.tar.gz
gyp http GET https://nodejs.org/download/release/v14.15.4/SHASUMS256.txt
gyp http 200 https://nodejs.org/download/release/v14.15.4/SHASUMS256.txt
gyp info spawn /usr/bin/python
gyp info spawn args [
gyp info spawn args   '/usr/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args   'binding.gyp',
gyp info spawn args   '-f',
gyp info spawn args   'make',
gyp info spawn args   '-I',
gyp info spawn args   '/home/atei/Projects/halalbooking/node_modules/gemini-core/node_modules/png-img/build/config.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/usr/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/home/atei/.cache/node-gyp/14.15.4/include/node/common.gypi',
gyp info spawn args   '-Dlibrary=shared_library',
gyp info spawn args   '-Dvisibility=default',
gyp info spawn args   '-Dnode_root_dir=/home/atei/.cache/node-gyp/14.15.4',
gyp info spawn args   '-Dnode_gyp_dir=/usr/lib/node_modules/npm/node_modules/node-gyp',
gyp info spawn args   '-Dnode_lib_file=/home/atei/.cache/node-gyp/14.15.4/<(target_arch)/node.lib',
gyp info spawn args   '-Dmodule_root_dir=/home/atei/Projects/halalbooking/node_modules/gemini-core/node_modules/png-img',
gyp info spawn args   '-Dnode_engine=v8',
gyp info spawn args   '--depth=.',
gyp info spawn args   '--no-parallel',
gyp info spawn args   '--generator-output',
gyp info spawn args   'build',
gyp info spawn args   '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
make: Entering directory '/home/atei/Projects/halalbooking/node_modules/gemini-core/node_modules/png-img/build'
  CC(target) Release/obj.target/libpng/third_party/libpng/png.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngerror.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngget.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngmem.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngpread.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngread.o
../third_party/libpng/pngread.c: In function ‘png_create_colormap_entry’:
../third_party/libpng/pngread.c:1905:38: warning: this statement may fall through [-Wimplicit-fallthrough=]
                entry[afirst ? 0 : 3] = (png_byte)alpha;
                ~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
../third_party/libpng/pngread.c:1906:13: note: here
             case 3:
             ^~~~
../third_party/libpng/pngread.c:1913:34: warning: this statement may fall through [-Wimplicit-fallthrough=]
                entry[1 ^ afirst] = (png_byte)alpha;
                ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
../third_party/libpng/pngread.c:1914:13: note: here
             case 1:
             ^~~~
  CC(target) Release/obj.target/libpng/third_party/libpng/pngrio.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngrtran.o
../third_party/libpng/pngrtran.c: In function ‘png_set_crc_action’:
../third_party/libpng/pngrtran.c:50:10: warning: this statement may fall through [-Wimplicit-fallthrough=]
          png_warning(png_ptr,
          ^~~~~~~~~~~~~~~~~~~~~
             "Can't discard critical data on CRC error");
             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../third_party/libpng/pngrtran.c:52:7: note: here
       case PNG_CRC_ERROR_QUIT:                                /* Error/quit */
       ^~~~
  CC(target) Release/obj.target/libpng/third_party/libpng/pngrutil.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngset.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngtest.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngtrans.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngwio.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngwrite.o
../third_party/libpng/pngwrite.c: In function ‘png_set_filter’:
../third_party/libpng/pngwrite.c:1010:18: warning: this statement may fall through [-Wimplicit-fallthrough=]
          case 7: png_app_error(png_ptr, "Unknown row filter for method 0");
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../third_party/libpng/pngwrite.c:1013:10: note: here
          case PNG_FILTER_VALUE_NONE:
          ^~~~
  CC(target) Release/obj.target/libpng/third_party/libpng/pngwtran.o
  CC(target) Release/obj.target/libpng/third_party/libpng/pngwutil.o
  AR(target) Release/obj.target/third_party/libpng/png.a
  COPY Release/png.a
  CC(target) Release/obj.target/zlib/third_party/zlib/adler32.o
  CC(target) Release/obj.target/zlib/third_party/zlib/compress.o
  CC(target) Release/obj.target/zlib/third_party/zlib/crc32.o
  CC(target) Release/obj.target/zlib/third_party/zlib/deflate.o
  CC(target) Release/obj.target/zlib/third_party/zlib/gzclose.o
  CC(target) Release/obj.target/zlib/third_party/zlib/gzlib.o
  CC(target) Release/obj.target/zlib/third_party/zlib/gzread.o
  CC(target) Release/obj.target/zlib/third_party/zlib/gzwrite.o
  CC(target) Release/obj.target/zlib/third_party/zlib/infback.o
../third_party/zlib/infback.c: In function ‘inflateBack’:
../third_party/zlib/infback.c:479:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = LEN;
             ~~~~~~~~~~~~^~~~~
../third_party/zlib/infback.c:481:9: note: here
         case LEN:
         ^~~~
  CC(target) Release/obj.target/zlib/third_party/zlib/inffast.o
  CC(target) Release/obj.target/zlib/third_party/zlib/inflate.o
../third_party/zlib/inflate.c: In function ‘inflateMark’:
../third_party/zlib/inflate.c:1507:61: warning: left shift of negative value [-Wshift-negative-value]
     if (strm == Z_NULL || strm->state == Z_NULL) return -1L << 16;
                                                             ^~
../third_party/zlib/inflate.c: In function ‘inflate’:
../third_party/zlib/inflate.c:720:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = EXLEN;
             ~~~~~~~~~~~~^~~~~~~
../third_party/zlib/inflate.c:721:9: note: here
         case EXLEN:
         ^~~~
../third_party/zlib/inflate.c:732:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = EXTRA;
             ~~~~~~~~~~~~^~~~~~~
../third_party/zlib/inflate.c:733:9: note: here
         case EXTRA:
         ^~~~
../third_party/zlib/inflate.c:754:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = NAME;
             ~~~~~~~~~~~~^~~~~~
../third_party/zlib/inflate.c:755:9: note: here
         case NAME:
         ^~~~
../third_party/zlib/inflate.c:775:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = COMMENT;
             ~~~~~~~~~~~~^~~~~~~~~
../third_party/zlib/inflate.c:776:9: note: here
         case COMMENT:
         ^~~~
../third_party/zlib/inflate.c:795:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = HCRC;
             ~~~~~~~~~~~~^~~~~~
../third_party/zlib/inflate.c:796:9: note: here
         case HCRC:
         ^~~~
../third_party/zlib/inflate.c:818:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = DICT;
             ~~~~~~~~~~~~^~~~~~
../third_party/zlib/inflate.c:819:9: note: here
         case DICT:
         ^~~~
../third_party/zlib/inflate.c:825:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = TYPE;
             ~~~~~~~~~~~~^~~~~~
../third_party/zlib/inflate.c:826:9: note: here
         case TYPE:
         ^~~~
../third_party/zlib/inflate.c:827:16: warning: this statement may fall through [-Wimplicit-fallthrough=]
             if (flush == Z_BLOCK || flush == Z_TREES) goto inf_leave;
                ^
../third_party/zlib/inflate.c:828:9: note: here
         case TYPEDO:
         ^~~~
../third_party/zlib/inflate.c:877:16: warning: this statement may fall through [-Wimplicit-fallthrough=]
             if (flush == Z_TREES) goto inf_leave;
                ^
../third_party/zlib/inflate.c:878:9: note: here
         case COPY_:
         ^~~~
../third_party/zlib/inflate.c:879:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = COPY;
             ~~~~~~~~~~~~^~~~~~
../third_party/zlib/inflate.c:880:9: note: here
         case COPY:
         ^~~~
../third_party/zlib/inflate.c:1018:16: warning: this statement may fall through [-Wimplicit-fallthrough=]
             if (flush == Z_TREES) goto inf_leave;
                ^
../third_party/zlib/inflate.c:1019:9: note: here
         case LEN_:
         ^~~~
../third_party/zlib/inflate.c:1020:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = LEN;
             ~~~~~~~~~~~~^~~~~
../third_party/zlib/inflate.c:1021:9: note: here
         case LEN:
         ^~~~
../third_party/zlib/inflate.c:1069:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = LENEXT;
             ~~~~~~~~~~~~^~~~~~~~
../third_party/zlib/inflate.c:1070:9: note: here
         case LENEXT:
         ^~~~
../third_party/zlib/inflate.c:1079:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = DIST;
             ~~~~~~~~~~~~^~~~~~
../third_party/zlib/inflate.c:1080:9: note: here
         case DIST:
         ^~~~
../third_party/zlib/inflate.c:1106:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = DISTEXT;
             ~~~~~~~~~~~~^~~~~~~~~
../third_party/zlib/inflate.c:1107:9: note: here
         case DISTEXT:
         ^~~~
../third_party/zlib/inflate.c:1122:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = MATCH;
             ~~~~~~~~~~~~^~~~~~~
../third_party/zlib/inflate.c:1123:9: note: here
         case MATCH:
         ^~~~
../third_party/zlib/inflate.c:1197:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = LENGTH;
             ~~~~~~~~~~~~^~~~~~~~
../third_party/zlib/inflate.c:1198:9: note: here
         case LENGTH:
         ^~~~
../third_party/zlib/inflate.c:1210:25: warning: this statement may fall through [-Wimplicit-fallthrough=]
             state->mode = DONE;
             ~~~~~~~~~~~~^~~~~~
../third_party/zlib/inflate.c:1211:9: note: here
         case DONE:
         ^~~~
  CC(target) Release/obj.target/zlib/third_party/zlib/inftrees.o
  CC(target) Release/obj.target/zlib/third_party/zlib/trees.o
  CC(target) Release/obj.target/zlib/third_party/zlib/uncompr.o
  CC(target) Release/obj.target/zlib/third_party/zlib/zutil.o
  AR(target) Release/obj.target/third_party/zlib/zlib.a
  COPY Release/zlib.a
  CXX(target) Release/obj.target/png_img/src/init.o
  CXX(target) Release/obj.target/png_img/src/PngImgAdapter.o
../src/PngImgAdapter.cc: In static member function ‘static Nan::NAN_METHOD_RETURN_TYPE PngImgAdapter::Get(Nan::NAN_METHOD_ARGS_TYPE)’:
../src/PngImgAdapter.cc:93:79: error: no matching function for call to ‘v8::Object::Set(v8::Local<v8::String>, Nan::imp::FactoryBase<v8::Number>::return_t)’
     obj->Set(Nan::New<String>("r").ToLocalChecked(), Nan::New<Number>(pPxl->r));
                                                                               ^
In file included from /home/atei/.cache/node-gyp/14.15.4/include/node/node.h:67:0,
                 from ../../../../nan/nan.h:56,
                 from ../src/./PngImgAdapter.h:4,
                 from ../src/PngImgAdapter.cc:1:
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3670:37: note: candidate: v8::Maybe<bool> v8::Object::Set(v8::Local<v8::Context>, v8::Local<v8::Value>, v8::Local<v8::Value>)
   V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                     ^~~
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3670:37: note:   candidate expects 3 arguments, 2 provided
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3673:37: note: candidate: v8::Maybe<bool> v8::Object::Set(v8::Local<v8::Context>, uint32_t, v8::Local<v8::Value>)
   V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                     ^~~
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3673:37: note:   candidate expects 3 arguments, 2 provided
../src/PngImgAdapter.cc:94:79: error: no matching function for call to ‘v8::Object::Set(v8::Local<v8::String>, Nan::imp::FactoryBase<v8::Number>::return_t)’
     obj->Set(Nan::New<String>("g").ToLocalChecked(), Nan::New<Number>(pPxl->g));
                                                                               ^
In file included from /home/atei/.cache/node-gyp/14.15.4/include/node/node.h:67:0,
                 from ../../../../nan/nan.h:56,
                 from ../src/./PngImgAdapter.h:4,
                 from ../src/PngImgAdapter.cc:1:
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3670:37: note: candidate: v8::Maybe<bool> v8::Object::Set(v8::Local<v8::Context>, v8::Local<v8::Value>, v8::Local<v8::Value>)
   V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                     ^~~
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3670:37: note:   candidate expects 3 arguments, 2 provided
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3673:37: note: candidate: v8::Maybe<bool> v8::Object::Set(v8::Local<v8::Context>, uint32_t, v8::Local<v8::Value>)
   V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                     ^~~
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3673:37: note:   candidate expects 3 arguments, 2 provided
../src/PngImgAdapter.cc:95:79: error: no matching function for call to ‘v8::Object::Set(v8::Local<v8::String>, Nan::imp::FactoryBase<v8::Number>::return_t)’
     obj->Set(Nan::New<String>("b").ToLocalChecked(), Nan::New<Number>(pPxl->b));
                                                                               ^
In file included from /home/atei/.cache/node-gyp/14.15.4/include/node/node.h:67:0,
                 from ../../../../nan/nan.h:56,
                 from ../src/./PngImgAdapter.h:4,
                 from ../src/PngImgAdapter.cc:1:
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3670:37: note: candidate: v8::Maybe<bool> v8::Object::Set(v8::Local<v8::Context>, v8::Local<v8::Value>, v8::Local<v8::Value>)
   V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                     ^~~
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3670:37: note:   candidate expects 3 arguments, 2 provided
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3673:37: note: candidate: v8::Maybe<bool> v8::Object::Set(v8::Local<v8::Context>, uint32_t, v8::Local<v8::Value>)
   V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                     ^~~
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3673:37: note:   candidate expects 3 arguments, 2 provided
../src/PngImgAdapter.cc:96:79: error: no matching function for call to ‘v8::Object::Set(v8::Local<v8::String>, Nan::imp::FactoryBase<v8::Number>::return_t)’
     obj->Set(Nan::New<String>("a").ToLocalChecked(), Nan::New<Number>(pPxl->a));
                                                                               ^
In file included from /home/atei/.cache/node-gyp/14.15.4/include/node/node.h:67:0,
                 from ../../../../nan/nan.h:56,
                 from ../src/./PngImgAdapter.h:4,
                 from ../src/PngImgAdapter.cc:1:
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3670:37: note: candidate: v8::Maybe<bool> v8::Object::Set(v8::Local<v8::Context>, v8::Local<v8::Value>, v8::Local<v8::Value>)
   V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                     ^~~
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3670:37: note:   candidate expects 3 arguments, 2 provided
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3673:37: note: candidate: v8::Maybe<bool> v8::Object::Set(v8::Local<v8::Context>, uint32_t, v8::Local<v8::Value>)
   V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                     ^~~
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3673:37: note:   candidate expects 3 arguments, 2 provided
../src/PngImgAdapter.cc: In lambda function:
../src/PngImgAdapter.cc:104:84: error: no matching function for call to ‘v8::Object::Get(v8::Local<v8::String>)’
         Nan::Utf8String val(obj->Get(Nan::New<String>(key.c_str()).ToLocalChecked()));
                                                                                    ^
In file included from /home/atei/.cache/node-gyp/14.15.4/include/node/node.h:67:0,
                 from ../../../../nan/nan.h:56,
                 from ../src/./PngImgAdapter.h:4,
                 from ../src/PngImgAdapter.cc:1:
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3717:43: note: candidate: v8::MaybeLocal<v8::Value> v8::Object::Get(v8::Local<v8::Context>, v8::Local<v8::Value>)
   V8_WARN_UNUSED_RESULT MaybeLocal<Value> Get(Local<Context> context,
                                           ^~~
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3717:43: note:   candidate expects 2 arguments, 1 provided
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3720:43: note: candidate: v8::MaybeLocal<v8::Value> v8::Object::Get(v8::Local<v8::Context>, uint32_t)
   V8_WARN_UNUSED_RESULT MaybeLocal<Value> Get(Local<Context> context,
                                           ^~~
/home/atei/.cache/node-gyp/14.15.4/include/node/v8.h:3720:43: note:   candidate expects 2 arguments, 1 provided
png_img.target.mk:120: recipe for target 'Release/obj.target/png_img/src/PngImgAdapter.o' failed
make: Leaving directory '/home/atei/Projects/halalbooking/node_modules/gemini-core/node_modules/png-img/build'
make: *** [Release/obj.target/png_img/src/PngImgAdapter.o] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:315:20)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
gyp ERR! System Linux 5.4.0-65-generic
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/atei/Projects/halalbooking/node_modules/gemini-core/node_modules/png-img
gyp ERR! node -v v14.15.4
Hypnosphi commented 3 years ago

It seems fixed in png-img@3 & gemini-core@6

DudaGod commented 3 years ago

It seems fixed in png-img@3 & gemini-core@6

Yeah, it has already been fixed. I close this issue.