Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Trying to build Electron... /usr/bin/ld and --sysroot
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
ch1p
n00b
n00b


Joined: 08 Jul 2016
Posts: 2

PostPosted: Fri Jul 08, 2016 5:31 pm    Post subject: Trying to build Electron... /usr/bin/ld and --sysroot Reply with quote

Hello, Gentoo people.

I have a project that using Electron (https://github.com/electron/electron/) as a platform and I need to rebuild it with my patches. There are build instructions for Linux (http://electron.atom.io/docs/development/build-instructions-linux/), but apparently their primary target is Ubuntu and Debian. It works well on Ubuntu, but when I'm trying to do the same on Gentoo, I'm ending up with this:

Code:
$ ./script/build.py -c D
ninja: Entering directory `out/D'
[822/1186] SOLINK lib/libnode.so
FAILED: if [ ! -e lib/libnode.so -o ! -e lib/libnode.so.TOC ]; then /home/evgeny/dev/electron/vendor/llvm-build/Release+Asserts/bin/clang++ -shared -Wl,-z,noexecstack -Wl,--whole-archive  -Wl,--no-whole-archive -pthread --sysroot=/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot -L/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/lib/x86_64-linux-gnu -Wl,-rpath-link=/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/lib/x86_64-linux-gnu -L/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib/x86_64-linux-gnu -Wl,-rpath-link=/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib/x86_64-linux-gnu -L/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib/gcc/x86_64-linux-gnu/4.6 -Wl,-rpath-link=/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib/gcc/x86_64-linux-gnu/4.6 -L/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib -Wl,-rpath-link=/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib -m64 -o lib/libnode.so -Wl,-soname=libnode./usr/bin/ld: this linker was not configured to use sysrootsso @lib/libnode.so.rsp && { readelf -d lib/libnode.so | grep SONAME ; nm -gD -f p lib/libnode.so | cut -f1-2 -d' '; } > lib/libnode.so.TOC; else /home/evgeny/dev/electron/vendor/llvm-build/Release+Asserts/bin/clang++ -shared -Wl,-z,noexecstack -Wl,--whole-archive  -Wl,--no-whole-archive -pthread --sysroot=/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot -L/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/lib/x86_64-linux-gnu -Wl,-rpath-link=/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/lib/x86_64-linux-gnu -L/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib/x86_64-linux-gnu -Wl,-rpath-link=/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib/x86_64-linux-gnu -L/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib/gcc/x86_64-linux-gnu/4.6 -Wl,-rpath-link=/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib/gcc/x86_64-linux-gnu/4.6 -L/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib -Wl,-rpath-link=/home/evgeny/dev/electron/vendor/debian_wheezy_amd64-sysroot/usr/lib -m64 -o lib/libnode.so -Wl,-soname=libnode.so @lib/libnode.so.rsp && { readelf -d lib/libnode.so | grep SONAME ; nm -gD -f p lib/libnode.so | cut -f1-2 -d' '; } > lib/libnode.so.tmp && if ! cmp -s lib/libnode.so.tmp lib/libnode.so.TOC; then mv lib/libnode.so.tmp lib/libnode.so.TOC ; fi; fi
/usr/bin/ld: this linker was not configured to use sysroots
clang: error: linker command failed with exit code 1 (use -v to see invocation)
[822/1186] CXX obj/vendor/brightray/browser/brightray.browser_main_parts.o
ninja: build stopped: subcommand failed


Does anyone have any suggestions what is wrong with Gentoo's ld and how to fix it, or how to work around it or something?
Back to top
View user's profile Send private message
pilla
Administrator
Administrator


Joined: 07 Aug 2002
Posts: 7693
Location: Pelotas, BR

PostPosted: Fri Jul 08, 2016 10:16 pm    Post subject: Reply with quote

Hello,

Any special reason for not using the ebuild already in the portage tree?
_________________
"I'm just very selective about the reality I choose to accept." -- Calvin
Back to top
View user's profile Send private message
ch1p
n00b
n00b


Joined: 08 Jul 2016
Posts: 2

PostPosted: Sat Jul 09, 2016 11:19 am    Post subject: Reply with quote

There are two reasons: 1st is that I need the latest version, and the 2nd is that
Code:
./script/build.py -c D
is much easier for development (I need to make changes to Electron's code, build it, test, repeat).
Back to top
View user's profile Send private message
pilla
Administrator
Administrator


Joined: 07 Aug 2002
Posts: 7693
Location: Pelotas, BR

PostPosted: Sat Jul 09, 2016 11:29 am    Post subject: Reply with quote

Maybe you should start from the ebuild to see what are dependences, how the build system is prepared, etc. and then jus mimic it in your own build.

Moved to Unsupported, as you are not using the ebuilds from the tree.
_________________
"I'm just very selective about the reality I choose to accept." -- Calvin
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum