Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4.2.0 and 4.2.1 errors out on ubuntu 12.04 #74

Closed
daveallen opened this issue Oct 22, 2015 · 9 comments
Closed

4.2.0 and 4.2.1 errors out on ubuntu 12.04 #74

daveallen opened this issue Oct 22, 2015 · 9 comments

Comments

@daveallen
Copy link

g++ '-DV8_TARGET_ARCH_X64' '-DENABLE_DISASSEMBLER' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-DICU_UTIL_DATA_IMPL=ICU_UTIL_DATA_STATIC' -I../deps/v8 -pthread -Wa
ll -Wextra -Wno-unused-parameter -m64 -B/tmp/node-build.20151022160705.24506/node-v4.2.1/third_party/binutils/Linux_x64/Release/bin -fno-strict-aliasing -m64 -O3 -ffunction-sections -fdata-sections -fno-omit-frame-pointer -fdata-sections -ffunction-sections -O3 -fno-rtti -fno-exceptions -std=gnu++0x -MMD -MF /tmp/node-build.20151022160705.24506/node-v4.2.1/out/Release/.deps//tmp/node-build.20151022160705.24506/node-v4.2.1/out/Release/obj.target/v8_base/deps/v8/src/accessors.o.d.raw -c -o /tmp/node-build.20151022160705.24506/node-v4.2.1/out/Release/obj.target/v8_base/deps/v8/src/accessors.o ../deps/v8/src/accessors.cc
In file included from ../deps/v8/src/v8.h:29:0,
from ../deps/v8/src/accessors.cc:5:
../deps/v8/include/v8.h:469:1: error: expected unqualified-id before 'using'
../deps/v8/include/v8.h:852:1: error: expected unqualified-id before 'using'
In file included from ../deps/v8/src/base/platform/platform.h:29:0,
from ../deps/v8/src/utils.h:18,
from ../deps/v8/src/v8.h:34,
from ../deps/v8/src/accessors.cc:5:
../deps/v8/src/base/platform/mutex.h:36:13: error: variable 'v8::base::Mutex v8::base::final' has initializer but incomplete type
../deps/v8/src/base/platform/mutex.h:37:2: error: expected primary-expression before 'public'
../deps/v8/src/base/platform/mutex.h:37:2: error: expected '}' before 'public'
../deps/v8/src/base/platform/mutex.h:37:2: error: expected ',' or ';' before 'public'
../deps/v8/src/base/platform/mutex.h:39:11: error: expected constructor, destructor, or type conversion before ';' token
../deps/v8/src/base/platform/mutex.h: In function 'v8::base::NativeHandle& v8::base::native_handle()':
../deps/v8/src/base/platform/mutex.h:63:12: error: 'native_handle_' was not declared in this scope
../deps/v8/src/base/platform/mutex.h: At global scope:
../deps/v8/src/base/platform/mutex.h:65:39: error: non-member function 'const NativeHandle& v8::base::native_handle()' cannot have cv-qualifier
../deps/v8/src/base/platform/mutex.h: In function 'const NativeHandle& v8::base::native_handle()':
../deps/v8/src/base/platform/mutex.h:65:39: error: new declaration 'const NativeHandle& v8::base::native_handle()'
../deps/v8/src/base/platform/mutex.h:62:17: error: ambiguates old declaration 'v8::base::NativeHandle& v8::base::native_handle()'
../deps/v8/src/base/platform/mutex.h:66:12: error: 'native_handle_' was not declared in this scope
../deps/v8/src/base/platform/mutex.h: At global scope:
../deps/v8/src/base/platform/mutex.h:69:2: error: expected unqualified-id before 'private'
../deps/v8/src/base/platform/mutex.h:89:3: error: 'friend' used outside of class
../deps/v8/src/base/platform/mutex.h:91:3: error: expected unqualified-id before 'const'
../deps/v8/src/base/platform/mutex.h:91:3: error: expected ')' before 'const'
../deps/v8/src/base/platform/mutex.h:91:3: error: 'void v8::base::operator=(const v8::base::Mutex&)' must be a nonstatic member function
../deps/v8/src/base/platform/mutex.h:104:9: error: 'LazyStaticInstance' does not name a type
../deps/v8/src/base/platform/mutex.h:130:22: error: variable 'v8::RecursiveMutex v8::final' has initializer but incomplete type
../deps/v8/src/base/platform/mutex.h:131:2: error: expected primary-expression before 'public'
../deps/v8/src/base/platform/mutex.h:131:2: error: expected '}' before 'public'
../deps/v8/src/base/platform/mutex.h:131:2: error: expected ',' or ';' before 'public'
../deps/v8/src/base/platform/mutex.h:133:20: error: expected constructor, destructor, or type conversion before ';' token
../deps/v8/src/base/platform/mutex.h:155:11: error: 'Mutex' does not name a type
../deps/v8/src/base/platform/mutex.h:157:3: error: 'NativeHandle' does not name a type
../deps/v8/src/base/platform/mutex.h:160:9: error: 'NativeHandle' does not name a type
../deps/v8/src/base/platform/mutex.h:164:2: error: expected unqualified-id before 'private'
../deps/v8/src/base/platform/mutex.h:170:3: error: expected unqualified-id before 'const'
../deps/v8/src/base/platform/mutex.h:170:3: error: expected ')' before 'const'
../deps/v8/src/base/platform/mutex.h:170:3: error: 'void v8::operator=(const v8::RecursiveMutex&)' must be a nonstatic member function
../deps/v8/src/base/platform/mutex.h:184:9: error: 'LazyStaticInstance' does not name a type
../deps/v8/src/base/platform/mutex.h:202:17: error: template declaration of 'LockGuard final'
../deps/v8/src/base/platform/mutex.h:203:2: error: expected primary-expression before 'public'
../deps/v8/src/base/platform/mutex.h:203:2: error: expected '}' before 'public'
../deps/v8/src/base/platform/mutex.h:205:14: error: declaration of '~LockGuard' as non-member
../deps/v8/src/base/platform/mutex.h:207:2: error: expected unqualified-id before 'private'
../deps/v8/src/base/platform/mutex.h:210:3: error: expected unqualified-id before 'const'
../deps/v8/src/base/platform/mutex.h:210:3: error: expected ')' before 'const'
../deps/v8/src/base/platform/mutex.h:210:3: error: 'void operator=(const LockGuard&)' must be a nonstatic member function
../deps/v8/src/base/platform/mutex.h:211:1: error: expected declaration before '}' token
../deps/v8/src/base/platform/mutex.h: In function 'const NativeHandle& v8::base::native_handle()':
../deps/v8/src/base/platform/mutex.h:67:3: warning: control reaches end of non-void function [-Wreturn-type]
../deps/v8/src/base/platform/mutex.h: In function 'v8::base::NativeHandle& v8::base::native_handle()':
../deps/v8/src/base/platform/mutex.h:64:3: warning: control reaches end of non-void function [-Wreturn-type]
make[1]: *** [/tmp/node-build.20151022160705.24506/node-v4.2.1/out/Release/obj.target/v8_base/deps/v8/src/accessors.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory `/tmp/node-build.20151022160705.24506/node-v4.2.1/out'
make: *** [node] Error 2

@jasonkarns
Copy link
Member

is 4.2.0 the oldest version that doesn't compile? Have 4.0/4.1 or older versions compiled successfully for you?

@daveallen
Copy link
Author

0.12.7 was the last one that I can build. I tested 4.0.0, 4.1.0, 4.2.0, 4.2.1 and those failed with the same error.

@jasonkarns
Copy link
Member

I'm going to keep this issue open in case someone can figure out the build issue. But for now (unless you actually need to compile from source) I recommend you just pull the distro down manually from http://nodejs.org/dist/v4.2.1/

Extract the tarball into $(nodenv root)/versions and you're good to go (though you'll probably want to rename that version). We're currently working on getting distro-installation into node-build as a first class installation method, which would remove the need for everyone to do their own compilation. But for now, we're still operating as a pure fork of ruby-build which doesn't do distros.

@daveallen
Copy link
Author

Thanks! I am here because of ruby-build. I use node-build without nodenv to install versions on my servers and then switch the app to point to what ever version we need. Also allows us to use multiple apps that use different versions on the same server for collaboration servers so we can use our whole system on one machine.
Thanks for node-build!

@daveallen
Copy link
Author

Found a fix.
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install gcc-4.9 g++-4.9
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.9 50
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.9 50

This is what it takes. I just added this to Chef in my node-build cookbook.
Thanks Again!!

@jasonkarns
Copy link
Member

@daveallen so it seems you had to use gcc 4.9. Could I ask which version of gcc was it that failed?

@daveallen
Copy link
Author

It was 4.6.3.

@jasonkarns jasonkarns mentioned this issue Oct 29, 2015
@jasonkarns
Copy link
Member

closing in favor of #72

@shreyas130989
Copy link

Thanks daveallen,
Your fix worked for me :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants