Page 1 of 1

Compiling under Debian 6 VPS

Posted: 28 Nov 2011, 15:17
by AF
I've cloned git master into my home directory (~/spring/spring/<thar be files here>), and ran cmake ., which ran fine, followed by make spring VERBOSE=1

It stays at:

Code: Select all

[  8%] Building CXX object rts/lib/assimp/code/CMakeFiles/assimp.dir/IFCReaderGen.cpp.o
cd /root/spring/spring/rts/lib/assimp/code && /usr/bin/c++   -DSYNCCHECK -DSPRING_DATADIR=\"/usr/local/share/games/spring\" -DSTREFLOP_SSE -DASSIMP_BUILD_DLL_EXPORT -msse -mfpmath=sse            -frounding-math -mieee-fp -pipe -fno-strict-aliasing -fvisibility=hidden -fvisibility-inlines-hidden -pthread  -O2      -Wno-unknown-pragmas -DNDEBUG -g -I/root/spring/spring/rts -I/root/spring/spring/rts/lib/assimp/include -I/root/spring/spring/rts/lib/assimp/code/../contrib/unzip   -o CMakeFiles/assimp.dir/IFCReaderGen.cpp.o -c /root/spring/spring/rts/lib/assimp/code/IFCReaderGen.cpp
I ran make spring earlier today and it reached that file, and took a while. I went to lunch and came back an hour later and my terminal window was identical.

Here is a more detailed log:

http://pastebin.com/FKhiNSNw

Re: Compiling under Debian 6 VPS

Posted: 28 Nov 2011, 16:40
by Tobi
Did you check if it was still using CPU, and how much RAM it was using / whether it was swapping?

Since it is a huge file maybe gcc required more memory than the RAM available in the VPS and it started swapping and being very slow...

Re: Compiling under Debian 6 VPS

Posted: 29 Nov 2011, 00:44
by AF
hmmm =/ that VPS has 256mb ram and a 512mb swap partition

Re: Compiling under Debian 6 VPS

Posted: 29 Nov 2011, 01:45
by dansan
Not sure what you want to run there, but if you need compiled spring in debian6 on that VPS my suggestion:

You can use a more powerful machine for the compiling, without touching distcc or anything fancy like this:

Code: Select all

0. get a local running linux with enough free disk space for all from VPS
1. rsync -aAHSxv root@VPS/ /mnt/VPS_SYNC/
1.1 "-x" makes rsync stay in the file system - if you have more than just "/", rsync those to the right places below /mnt/VPS_SYNC/
2. chroot /mnt/VPS_SYNC/
3. [inside debian6 chroot] cd /root/spring
4. [inside debian6 chroot] cmake .
5. rsync -aAHSxv /mnt/VPS_SYNC/root/spring/ root@VPS/root/spring/
6. ssh root@VPS
7. [debian6 VPS] cd /root/spring
8. [debian6 VPS] make install
For updates of spring rsync just [/mnt/VPS_SYNC|root@VPS]/root/spring, after updates of system rsync "root@VPS/"->"/mnt/VPS_SYNC/" with "--exclude /root/spring".

Do not run updates inside the chroot, and sync them to the VPS.
Do not sync anything with direction to the VPS except spring-folder.

You should not compile spring as root, but use an unpriv. user account. Just "make install" needs root perms. Change paths accordingly.

Re: Compiling under Debian 6 VPS

Posted: 29 Nov 2011, 21:46
by AF
Oh its a new VPS I haven't set up users yet and it's got no outwards facing stuff yet anyways, I'll probably cart off the contents of ~ and reinstall it soon