Comments (7)
请问,Windows下如何自己编译呢?虽然有编译好的,但不适用于electron,所以想自己编译。
from node-images.
我的操作系统为debian 8
脚本中 libpng 的1.6.16已经无法下载,自己手动换成了 1.6.19。在使用node-gyp rebuild
时遇到如下问题,估计是什么问题。
obj.target/zlib/gyp/third-party/zlib/inffast.o
CC(target) Release/obj.target/zlib/gyp/third-party/zlib/inflate.o
CC(target) Release/obj.target/zlib/gyp/third-party/zlib/inftrees.o
CC(target) Release/obj.target/zlib/gyp/third-party/zlib/trees.o
CC(target) Release/obj.target/zlib/gyp/third-party/zlib/uncompr.o
CC(target) Release/obj.target/zlib/gyp/third-party/zlib/zutil.o
AR(target) Release/obj.target/gyp/gyp/zlib.a
COPY Release/zlib.a
CXX(target) Release/obj.target/binding/src/Image.o
../src/Image.cc:27:11: error: ‘v8::MaybeLocal’ has not been declared
using v8::MaybeLocal;
^
../src/Image.cc: In static member function ‘static void Image::Init(v8::Localv8::Object)’:
../src/Image.cc:65:33: error: ‘class v8::Object’ has no member named ‘GetIsolate’
Isolate isolate = exports->GetIsolate();
^
../src/Image.cc: In static member function ‘static void Image::ToBuffer(const v8::FunctionCallbackInfov8::Value&)’:
../src/Image.cc:425:25: error: ‘MaybeLocal’ was not declared in this scope
MaybeLocal maybeBuffer = node::Buffer::New(args.GetIsolate(), (size_t) length);
^
../src/Image.cc:425:42: error: expected primary-expression before ‘>’ token
MaybeLocal maybeBuffer = node::Buffer::New(args.GetIsolate(), (size_t) length);
^
../src/Image.cc:425:44: error: ‘maybeBuffer’ was not declared in this scope
MaybeLocal maybeBuffer = node::Buffer::New(args.GetIsolate(), (size_t) length);
^
../src/Image.cc: In constructor ‘Image::Image()’:
../src/Image.cc:53:78: warning: value computed is not used [-Wunused-value]
v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(bc));
^
../src/Image.cc:469:5: note: in expansion of macro ‘AdjustAmountOfExternalAllocatedMemory’
AdjustAmountOfExternalAllocatedMemory(size);
^
../src/Image.cc: In destructor ‘virtual Image::~Image()’:
../src/Image.cc:53:78: warning: value computed is not used [-Wunused-value]
v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(bc));
^
../src/Image.cc:479:5: note: in expansion of macro ‘AdjustAmountOfExternalAllocatedMemory’
AdjustAmountOfExternalAllocatedMemory(-size);
^
../src/Image.cc: In member function ‘ImageState PixelArray::Malloc(size_t, size_t)’:
../src/Image.cc:53:78: warning: value computed is not used [-Wunused-value]
v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(bc));
^
../src/Image.cc:524:5: note: in expansion of macro ‘AdjustAmountOfExternalAllocatedMemory’
AdjustAmountOfExternalAllocatedMemory(size);
^
../src/Image.cc: In member function ‘void PixelArray::Free()’:
../src/Image.cc:53:78: warning: value computed is not used [-Wunused-value]
v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(bc));
^
../src/Image.cc:550:9: note: in expansion of macro ‘AdjustAmountOfExternalAllocatedMemory’
AdjustAmountOfExternalAllocatedMemory(-size);
^
binding.target.mk:109: recipe for target 'Release/obj.target/binding/src/Image.o' failed
make: ** [Release/obj.target/binding/src/Image.o] Error 1
make: Leaving directory '/home/yangqw/node-images/build'
gyp ERR! build error
gyp ERR! stack Error: make
failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/home/yangqw/nodejs/node-v0.12.7-linux-x86/lib/node_modules/node-gyp/lib/build.js:276:23)
gyp ERR! stack at ChildProcess.emit (events.js:110:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:1074:12)
gyp ERR! System Linux 3.16.0-4-686-pae
gyp ERR! command "node" "/home/yangqw/nodejs/node-v0.12.7-linux-x86/bin/node-gyp" "rebuild"
gyp ERR! cwd /home/yangqw/node-images
gyp ERR! node -v v0.12.7
gyp ERR! node-gyp -v v3.2.1
gyp ERR! not ok
from node-images.
5.0 貌似接口都改了
from node-images.
有解决办法吗?
from node-images.
centos6.6上运行报错:需要安装glibc2.14,根据此文rebuild时报错
/gyp/third-party/libjpeg-turbo/jpeglib.h:902:36: error: ‘JPEG_LIB_VERSION’ undeclared (first use in this function)
from node-images.
@sdming cmake 装了么
from node-images.
@xiangshouding
已经装了,报错的信息如下
`
In file included from ../gyp/third-party/libjpeg-turbo/cdjpeg.h:17:0,
from ../gyp/third-party/libjpeg-turbo/bmp.c:33:
../gyp/third-party/libjpeg-turbo/jpeglib.h:67:1: error: unknown type name ‘JSAMPLE’
typedef JSAMPLE JSAMPROW; / ptr to one image row of pixel samples. /
^
../gyp/third-party/libjpeg-turbo/jpeglib.h:656:3: error: unknown type name ‘JSAMPLE’
JSAMPLE * sample_range_limit; / table for fast range-limiting */
^
../gyp/third-party/libjpeg-turbo/bmp.c: In function ‘loadbmp’:
../gyp/third-party/libjpeg-turbo/jpeglib.h:899:34: error: ‘JPEG_LIB_VERSION’ undeclared (first use in this function)
jpeg_CreateCompress((cinfo), JPEG_LIB_VERSION, \
`
系统信息
`
[root@centos66 node-images]# node -v
v6.9.1
[root@centos66 node-images]# npm -v
3.10.3
[root@centos66 node-images]# strings /lib64/libc.so.6 |grep GLIBC_
GLIBC_2.2.5
GLIBC_2.2.6
GLIBC_2.3
GLIBC_2.3.2
GLIBC_2.3.3
GLIBC_2.3.4
GLIBC_2.4
GLIBC_2.5
GLIBC_2.6
GLIBC_2.7
GLIBC_2.8
GLIBC_2.9
GLIBC_2.10
GLIBC_2.11
GLIBC_2.12
GLIBC_PRIVATE
[root@centos66 node-images]# rpm -qa |grep glibc
glibc-headers-2.12-1.149.el6.x86_64
glibc-common-2.12-1.149.el6.x86_64
glibc-devel-2.12-1.149.el6.x86_64
glibc-2.12-1.149.el6.x86_64
[root@centos66 node-images]# cat /proc/version
Linux version 2.6.32-504.el6.x86_64 ([email protected]) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-11) (GCC) ) #1 SMP Wed Oct 15 04:27:16 UTC 2014
`
from node-images.
Related Issues (20)
- 在使用electron 桌面开发的时候,调用imagesAPI出现Buffer报错
- Draw image on negative coordinate
- dyld: lazy symbol binding failed: Symbol not found HOT 1
- dyld[25779]: missing symbol called HOT 5
- macos error HOT 1
- M1 MacBook / Apple Silicon support?
- 原图大小超过2m之后就无法压缩了 HOT 7
- node-gyp rebuild error
- 图片大小超过2M闪退 HOT 1
- 运行代码报错MODULE_NOT_FOUND' HOT 1
- 请问mac M1平台如何自己编译darwin-arm64-binding.node? HOT 3
- 怎么给图片设置透明度 HOT 1
- 有图片裁剪吗
- 怎么使用svg
- node: symbol lookup error: /app/node_modules/images/vendor/linux-x64-binding.node: undefined symbol: _ZN2v87Isolate19CheckMemoryPressureEv HOT 10
- Is it supported base64
- Not found /var/vendor/linux-x64-binding.node
- 希望提供更多平台的binding
- Module still working? HOT 2
- node v20.11.0版本不兼容 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from node-images.