install fails
Closed this issue · 8 comments
using osx High Sierra v10.13.4
OSX 10.13.3
installed qt5, cairo, poppler
installed xCode
Thanks in advance for your help :)
dcs-MacBook-Pro:server dc$ yarn add pdf-fill-form
yarn add v1.4.0
[1/4] 🔍 Resolving packages...
[2/4] 🚚 Fetching packages...
[3/4] 🔗 Linking dependencies...
[4/4] 📃 Building fresh packages...
[1/2] ⠂ iconv: CXX(target) Release/obj.target/iconv/src/binding.o
[2/2] ⠂ pdf-fill-form: ^~~~~~~~~~~~~~~~
[-/2] ⠂ waiting...
[-/2] ⠂ waiting...
error An unexpected error occurred: "/data/dev/react-auth/server/node_modules/pdf-fill-form: Command failed.
Exit code: 1
Command: sh
Arguments: -c node-gyp rebuild
Directory: /data/dev/react-auth/server/node_modules/pdf-fill-form
Output:
gyp info it worked if it ends with ok
gyp info using node-gyp@3.6.2
gyp info using node@9.5.0 | darwin | x64
gyp info spawn /usr/bin/python
gyp info spawn args [ '/usr/local/Cellar/node/9.5.0/libexec/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 '/data/dev/react-auth/server/node_modules/pdf-fill-form/build/config.gypi',
gyp info spawn args '-I',
gyp info spawn args '/usr/local/Cellar/node/9.5.0/libexec/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
gyp info spawn args '-I',
gyp info spawn args '/Users/dc/.node-gyp/9.5.0/include/node/common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=/Users/dc/.node-gyp/9.5.0',
gyp info spawn args '-Dnode_gyp_dir=/usr/local/Cellar/node/9.5.0/libexec/lib/node_modules/npm/node_modules/node-gyp',
gyp info spawn args '-Dnode_lib_file=/Users/dc/.node-gyp/9.5.0/<(target_arch)/node.lib',
gyp info spawn args '-Dmodule_root_dir=/data/dev/react-auth/server/node_modules/pdf-fill-form',
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=.' ]
xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance
xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
CXX(target) Release/obj.target/pdf_fill_form/src/pdf-fill-form.o
In file included from ../src/pdf-fill-form.cc:1:
In file included from ../../nan/nan.h:190:
../../nan/nan_maybe_43_inl.h:88:15: warning: 'ForceSet' is deprecated [-Wdeprecated-declarations]
return obj->ForceSet(GetCurrentContext(), key, value, attribs);
^
/Users/dc/.node-gyp/9.5.0/include/node/v8.h:3114:3: note: 'ForceSet' has been explicitly marked deprecated here
V8_DEPRECATED("Use CreateDataProperty / DefineOwnProperty",
^
/Users/dc/.node-gyp/9.5.0/include/node/v8config.h:321:29: note: expanded from macro 'V8_DEPRECATED'
declarator attribute((deprecated))
^
In file included from ../src/pdf-fill-form.cc:2:
../src/NodePoppler.h:5:10: fatal error: 'QtCore/QBuffer' file not found
#include <QtCore/QBuffer>
^~~~~~~~~~~~~~~~
1 warning and 1 error generated.
make: *** [Release/obj.target/pdf_fill_form/src/pdf-fill-form.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: make
failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/Cellar/node/9.5.0/libexec/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23)
gyp ERR! stack at ChildProcess.emit (events.js:160:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:12)
gyp ERR! System Darwin 17.4.0
gyp ERR! command "/usr/local/Cellar/node/9.5.0/bin/node" "/usr/local/Cellar/node/9.5.0/libexec/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /data/dev/react-auth/server/node_modules/pdf-fill-form
gyp ERR! node -v v9.5.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok".
same
Me too.
same
Please try the latest version from master -branch that contains updates by @florianbepunkt
Hello: installing from linux I have a similar problem
MMMMMMMMMMMMMMMMMMMMMMMMMmds+. mrelemerson@mrelemerson-UX310UQK
MMm----::-://////////////oymNMd+` --------------------------------
MMd /++ -sNMd: OS: Linux Mint 19 Tara x86_64
MMNso/` dMM `.::-. .-::.` .hMN: Host: UX310UQK 1.0
ddddMMh dMM :hNMNMNhNMNMNh: `NMm Kernel: 4.15.0-33-generic
NMm dMM .NMN/-+MMM+-/NMN` dMM Uptime: 11 hours, 24 mins
NMm dMM -MMm `MMM dMM. dMM Packages: 2251
NMm dMM -MMm `MMM dMM. dMM Shell: bash 4.4.19
NMm dMM .mmd `mmm yMM. dMM Resolution: 1920x1080
NMm dMM` ..` ... ydm. dMM DE: Cinnamon 3.8.8
hMM- +MMd/-------...-:sdds dMM WM: Mutter (Muffin)
-NMm- :hNMNNNmdddddddddy/` dMM WM Theme: Mint-Y-Dark (Canta-compact)
-dMNs-``-::::-------.`` dMM Theme: Canta-compact [GTK2/3]
`/dMNmy+/:-------------:/yMMM Icons: Numix [GTK2/3]
./ydNMMMMMMMMMMMMMMMMMMMMM Terminal: gnome-terminal
.MMMMMMMMMMMMMMMMMMM CPU: Intel i7-7500U (4) @ 3.500GHz
GPU: NVIDIA GeForce 940MX
GPU: Intel HD Graphics 620
Memory: 3709MiB / 7857MiB
yarn add file:/home/mrelemerson/Downloads/pdf-fill-form
yarn add v1.9.4
[1/4] Resolving packages...
[2/4] Fetching packages...
[------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------] 0/581(node:4749) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
info fsevents@1.2.4: The platform "linux" is incompatible with this module.
info "fsevents@1.2.4" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[1/3] ⠠ typechecker
[2/3] ⠠ nodemon
error /home/mrelemerson/workspace/isend/backend/node_modules/pdf-fill-form: Command failed.
Exit code: 1
Command: node-gyp rebuild
Arguments:
Directory: /home/mrelemerson/workspace/isend/backend/node_modules/pdf-fill-form
Output:
gyp info it worked if it ends with ok
gyp info using node-gyp@3.7.0
gyp info using node@10.9.0 | linux | x64
gyp info spawn /usr/bin/python2
gyp info spawn args [ '/home/mrelemerson/.nvm/versions/node/v10.9.0/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/mrelemerson/workspace/isend/backend/node_modules/pdf-fill-form/build/config.gypi',
gyp info spawn args '-I',
gyp info spawn args '/home/mrelemerson/.nvm/versions/node/v10.9.0/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
gyp info spawn args '-I',
gyp info spawn args '/home/mrelemerson/.node-gyp/10.9.0/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/mrelemerson/.node-gyp/10.9.0',
gyp info spawn args '-Dnode_gyp_dir=/home/mrelemerson/.nvm/versions/node/v10.9.0/lib/node_modules/npm/node_modules/node-gyp',
gyp info spawn args '-Dnode_lib_file=/home/mrelemerson/.node-gyp/10.9.0/<(target_arch)/node.lib',
gyp info spawn args '-Dmodule_root_dir=/home/mrelemerson/workspace/isend/backend/node_modules/pdf-fill-form',
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 make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
make: Entering directory '/home/mrelemerson/workspace/isend/backend/node_modules/pdf-fill-form/build'
CXX(target) Release/obj.target/pdf_fill_form/src/pdf-fill-form.o
In file included from ../../nan/nan.h:190:0,
from ../src/pdf-fill-form.cc:1:
../../nan/nan_maybe_43_inl.h: In function ‘Nan::Maybe<bool> Nan::ForceSet(v8::Local<v8::Object>, v8::Local<v8::Value>, v8::Local<v8::Value>, v8::PropertyAttribute)’:
../../nan/nan_maybe_43_inl.h:88:15: error: ‘class v8::Object’ has no member named ‘ForceSet’
return obj->ForceSet(GetCurrentContext(), key, value, attribs);
^~~~~~~~
In file included from ../src/pdf-fill-form.cc:1:0:
../../nan/nan.h: In function ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’:
../../nan/nan.h:817:60: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
v8::Isolate::GetCurrent(), target, func, argc, argv);
^
In file included from ../../nan/nan.h:47:0,
from ../src/pdf-fill-form.cc:1:
/home/mrelemerson/.node-gyp/10.9.0/include/node/node.h:172:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/home/mrelemerson/.node-gyp/10.9.0/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
In file included from ../src/pdf-fill-form.cc:1:0:
../../nan/nan.h: In function ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::String>, int, v8::Local<v8::Value>*)’:
../../nan/nan.h:831:62: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, v8::Local<v8::String>, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
v8::Isolate::GetCurrent(), target, symbol, argc, argv);
^
In file included from ../../nan/nan.h:47:0,
from ../src/pdf-fill-form.cc:1:
/home/mrelemerson/.node-gyp/10.9.0/include/node/node.h:165:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/home/mrelemerson/.node-gyp/10.9.0/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
In file included from ../src/pdf-fill-form.cc:1:0:
../../nan/nan.h: In function ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, const char*, int, v8::Local<v8::Value>*)’:
../../nan/nan.h:845:62: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, const char*, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
v8::Isolate::GetCurrent(), target, method, argc, argv);
^
In file included from ../../nan/nan.h:47:0,
from ../src/pdf-fill-form.cc:1:
/home/mrelemerson/.node-gyp/10.9.0/include/node/node.h:158:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/home/mrelemerson/.node-gyp/10.9.0/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
In file included from ../src/pdf-fill-form.cc:1:0:
../../nan/nan.h: In member function ‘v8::Local<v8::Value> Nan::Callback::Call_(v8::Isolate*, v8::Local<v8::Object>, int, v8::Local<v8::Value>*) const’:
../../nan/nan.h:1453:5: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
));
^
In file included from ../../nan/nan.h:47:0,
from ../src/pdf-fill-form.cc:1:
/home/mrelemerson/.node-gyp/10.9.0/include/node/node.h:172:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/home/mrelemerson/.node-gyp/10.9.0/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
pdf_fill_form.target.mk:129: recipe for target 'Release/obj.target/pdf_fill_form/src/pdf-fill-form.o' failed
make: Leaving directory '/home/mrelemerson/workspace/isend/backend/node_modules/pdf-fill-form/build'
make: *** [Release/obj.target/pdf_fill_form/src/pdf-fill-form.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/home/mrelemerson/.nvm/versions/node/v10.9.0/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:262:23)
gyp ERR! stack at ChildProcess.emit (events.js:182:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:239:12)
gyp ERR! System Linux 4.15.0-33-generic
gyp ERR! command "/home/mrelemerson/.nvm/versions/node/v10.9.0/bin/node" "/home/mrelemerson/.nvm/versions/node/v10.9.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/mrelemerson/workspace/isend/backend/node_modules/pdf-fill-form
gyp ERR! node -v v10.9.0
gyp ERR! node-gyp -v v3.7.0
git log
commit d4773d85c407498fda9c77967b00fc7f83395a96 (HEAD -> master, origin/master, origin/HEAD)
Author: Tommi Pisto <tpisto@users.noreply.github.com>
Date: Wed Jul 25 15:14:51 2018 +0300
Update README.md
commit a0c6eccf602ea95fcfa87756d12527bc8d7940bd
Merge: ae9a046 ebdf21c
Author: Tommi Pisto <tpisto@users.noreply.github.com>
Date: Wed Jul 25 15:13:39 2018 +0300
Merge pull request #55 from florianbepunkt/master
Compile changes to make module compile on OSX
commit ebdf21c2556f3ff0e78944b03ac4e72702fdb693
Author: Florian Bischoff <mail@florian-bischoff.de>
Date: Sat Jun 16 11:08:36 2018 +0200
updated set of CMAKE_OSX_DEPLOYMENT_TARGET
upped mmacosx-version-min under xcode_settings.OTHER_CFLAGS
commit f7ed3c5e7d1c5a77aef40400ec137606349784b5
Author: Florian Bischoff <mail@florian-bischoff.de>
Date: Wed Dec 20 12:09:25 2017 +0100
prepend QtCore/ for mac compatability
commit dbda82a56d105a13423a167b7ef5248908b5da4e
Author: Florian Bischoff <mail@florian-bischoff.de>
Date: Wed Dec 20 12:05:58 2017 +0100
Update NodePoppler.cc
@mrelemerson have you tried to use pr #56 or manually upping nan version?
@florianbepunkt manually updating the nan worked, thank you very much.
{
"author": "Tommi Pisto <tommi@pis.to>",
"name": "pdf-fill-form",
"description": "Fill PDF forms and return rendered PDF in buffer. No temporary files created.",
"keywords": [
"pdf",
"forms",
"poppler",
"qt5",
"cairo"
],
"version": "3.2.1",
"repository": {
"type": "git",
"url": "git://github.com/tpisto/pdf-fill-form.git"
},
"gypfile": true,
"main": "./lib/pdf-fill-form.js",
"engines": {
"node": ">4.4.0"
},
"dependencies": {
"nan": "~2.11.0"
},
"devDependencies": {},
"optionalDependencies": {}
}
mrelemerson@mrelemerson-UX310UQK:~/workspace/isend/backend$ yarn add file:/home/mrelemerson/Downloads/pdf-fill-form
yarn add v1.9.4
[1/4] Resolving packages...
[2/4] Fetching packages...
[------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------] 0/584(node:12455) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
info fsevents@1.2.4: The platform "linux" is incompatible with this module.
info "fsevents@1.2.4" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
success Saved lockfile.
success Saved 1 new dependency.
info Direct dependencies
└─ pdf-fill-form@3.2.1
info All dependencies
└─ pdf-fill-form@3.2.1
Done in 9.21s.
I just pushed latest version to npm that includes great work by @florianbepunkt