Page 1 of 1

GG: scons trying to install files during build process

Posted: Wed Dec 17, 2008 9:02 am
by obgr_seneca
Strangely enough I'm now facing a different problem, when trying to build with some test-directory as prefix, I'm getting an error-message about some boost-header, that will be solved in the near future, as Zach said in another topic.
Now I tried installing it for real into /usr and I'm getting the following:

Code: Select all

g++ -o tutorial/minimal.o -c -pthread -Wall -O2 -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/include/freetype2 -I. -Ilibltdl -I/usr/include/SDL tutorial/minimal.cpp
Install file: "libGiGi.so" as "/usr/lib/libGiGi.so.0.6.0"
scons: *** [/usr/lib/libGiGi.so.0.6.0] /usr/lib/libGiGi.so.0.6.0: Permission denied
So you have to be root during the "scons" step of the installation, normaly this should only be necessary during "scons install".
Normally this wouldn't be a problem if you just tried to install GG, but if you try to build an rpm-package, you won't get any further here.
So why is this installation of libGiGi during the compile run necessary? Can't that be changed back to the old behaviour?

Oliver

Re: GG: scons trying to install files during build process

Posted: Fri Dec 19, 2008 11:11 pm
by obgr_seneca
Could anyone at least try to confirm it?

Steps to reproduce: Sty user for the following steps: Then run

Code: Select all

scons configure prefix=/usr
and then

Code: Select all

scons
It should cancel the compile telling you it doesn't have the rights to write some file to /usr/lib/
This should not be the case, it shouldn't try to install anything before the

Code: Select all

scons install
step.
And does anyone have an idea, why it is behaving like that? I tried to look into some files but didn't find anything, but I don't know much about scons...

Oliver

Re: GG: scons trying to install files during build process

Posted: Mon Dec 22, 2008 11:25 am
by loonycyborg
I confirm this issue.

Re: GG: scons trying to install files during build process

Posted: Mon Dec 22, 2008 11:43 am
by loonycyborg
It happens because GG's scons script now builds tutorials too. Based on LIBS and LIBPATH scons figures out that tutorial binaries depend on GG libs located in install target dir and tries to build them. Solution: prepend "." to LIBPATH so it'll depend on libs in GG's compile dir.

Code: Select all

Index: SConstruct
===================================================================
--- SConstruct  (revision 688)
+++ SConstruct  (working copy)
@@ -643,7 +643,7 @@

     # The tutorials depend on libGiGiSDL, so we add targets for them here
     tutorial_env = sdl_env.Copy()
-    tutorial_env.AppendUnique(LIBPATH = ['.'])
+    tutorial_env.PrependUnique(LIBPATH = ['.'])
     tutorial_env.AppendUnique(LIBS = ['GiGi', 'GiGiSDL'])
     if str(Platform()) == 'win32':
         tutorial_env.AppendUnique(LIBS = [

Re: GG: scons trying to install files during build process

Posted: Mon Dec 22, 2008 8:48 pm
by obgr_seneca
Thanks!

That solved it...

GG and FO built just fine now!

Oliver

Re: GG: scons trying to install files during build process

Posted: Tue Dec 30, 2008 2:55 am
by tzlaine
Nice catch. Committed.