AlexMasterov / dockerfiles

:whale: Common Dockerfiles, used for development
56 stars 18 forks source link

alpine-v8-lib build issues #1

Closed smebberson closed 8 years ago

smebberson commented 8 years ago

@AlexMasterov, thanks for making your v8-lib script open source! I can't get it to build though, I did a copy and paste into a Dockerfile and received the following error:

/usr/lib/gcc/x86_64-alpine-linux-musl/5.3.0/../../../../x86_64-alpine-linux-musl/bin/ld.gold: fatal error: /tmp/v8/out/native/obj.target/third_party/icu/libicuuc.so: Not supported
collect2: error: ld returned 1 exit status
third_party/icu/icuuc.target.native.mk:413: recipe for target '/tmp/v8/out/native/obj.target/third_party/icu/libicuuc.so' failed
make[1]: *** [/tmp/v8/out/native/obj.target/third_party/icu/libicuuc.so] Error 1
make[1]: Leaving directory '/tmp/v8/out'
Makefile:314: recipe for target 'native' failed
make: *** [native] Error 2

As mentioned the Dockerfile is an exact copy and paste of yours. For what it is worth, I'm running this from a Vagrant vm using Ubuntu 14.04 LTS:

Do you get that error?

AlexMasterov commented 8 years ago

Thank you for your interest. Try to increase the RAM-memory on Vagrant (2048 is fine).

I tried to do automated build. The logs looks fine, but the build has timed out..

smebberson commented 8 years ago

@AlexMasterov. Thanks for getting back to me.

So, I upgraded the RAM:

vagrant:/vagrant$ free
             total       used       free     shared    buffers     cached
Mem:       2050100    1846052     204048       6376      92348    1297556

But I'm still getting the same error?

  SOLINK(target) /tmp/v8/out/native/obj.target/third_party/icu/libicuuc.so
/usr/lib/gcc/x86_64-alpine-linux-musl/5.3.0/../../../../x86_64-alpine-linux-musl/bin/ld.gold: fatal error: /tmp/v8/out/native/obj.target/third_party/icu/libicuuc.so: Not supported
collect2: error: ld returned 1 exit status
third_party/icu/icuuc.target.native.mk:413: recipe for target '/tmp/v8/out/native/obj.target/third_party/icu/libicuuc.so' failed
make[1]: *** [/tmp/v8/out/native/obj.target/third_party/icu/libicuuc.so] Error 1
make[1]: Leaving directory '/tmp/v8/out'
Makefile:314: recipe for target 'native' failed
make: *** [native] Error 2

I had a look at the log on your automated build, and you're right, it gets past this step no problems. Do you have any ideas on what else it might be?

AlexMasterov commented 8 years ago

@smebberson I had a strange problem with heavy steps compile when the VM has enough resources. And logs were useless.

Try to remove a job key from make command (same problem with resources). Try FROM alpine:edge (I have a difference with the accumulation of resources). Try without docker-compose: docker build -t alpine-v8-lib .

If you want, I can share a ready image with the latest V8 (32 Mb) or just the archive with libraries (26 Mb).

AlexMasterov commented 8 years ago

Sorry, but I can't reproduce the problem :(

VirtualBox     5.1.2 (i7-4770K, 8 Gb)
Vagrant        1.8.5 (cpus: 4, ram: 2048, swap: 1024, Debian)
docker         1.12.0, build Thu Jul 28 21:40:59 2016
docker-compose 1.8.0, build 94f7016

Try alpine-v8-lib_5.4.329.tar (30 Mb)

docker load -i alpine-v8-lib_5.4.329.tar
smebberson commented 8 years ago

@AlexMasterov, thanks for your input. I'll play around with a few things (including a refresh of the VM) and see what I can get happening. So fragile!

Thanks for the archive :)

I'll get back to you here with what I find.

smebberson commented 8 years ago

Okay, I got it to build. I did the following:

Everything builds :)

AlexMasterov commented 8 years ago

Force to use the system-wide binutils during compilation v8

I forgot about that :) Interesting..