Error Compiling

Asked by Pharun

Having problems compiling from the source data. I get all the way to the end but then there is some crazy error due to spaces that some how got added to the path names. I'm running openSuse 11.1, here is the error stuff it gave me.

Checking for iconv(0, (const char **)0, 0, (char**)0, 0) in C library iconv... (cached) no

scons: warning: The env.Copy() method is deprecated; use the env.Clone() method instead.
File "/home/linuxdcpp/linux/SConstruct", line 27, in <module>
scons: done reading SConscript files.
scons: Building targets ...
g++ -o build/client/AdcCommand.o -c -I. -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_REENTRANT - D _ D A T A D I R = ' " / u s r / l o c a l / s h a r e " ' -pthread client/AdcCommand.cpp
g++: D: No such file or directory
g++: _: No such file or directory
g++: D: No such file or directory
g++: A: No such file or directory
g++: T: No such file or directory
g++: A: No such file or directory
g++: D: No such file or directory
g++: I: No such file or directory
g++: R: No such file or directory
g++: =: No such file or directory
g++: " / u s r / l o c a l / s h a r e " : No such file or directory
g++: cannot specify -o with -c or -S with multiple files
scons: *** [build/client/AdcCommand.o] Error 1
scons: building terminated because of errors.

Thanks for any help, ths is really confusing me.

Question information

Language:
English Edit question
Status:
Answered
For:
LinuxDC++ Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
dot (dot-doom) said :
#1

Greetings!
The solution is simple.

Edit SConstruct file in source dir, find there line ~180:
> env.Append(CXXFLAGS = ['-I.', '-D_GNU_SOURCE', '-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64', '-D_REENTRANT'])
> ...

Then in next lines, until the next comment block 'Build', put square brackets [] around the adding strings, e.g.:
> env.Append(CXXFLAGS = '-D_DATADIR=\'\"' + env['PREFIX'] + '/share' + '\"\'')
is replaced with
> env.Append(CXXFLAGS = ['-D_DATADIR=\'\"' + env['PREFIX'] + '/share' + '\"\''])

so the simple strings are converted to 1-item lists.

I do not know the source of problem for sure, but I suppose it is due to very complicated 'Append' function realisation.

Can you help with this problem?

Provide an answer of your own, or ask Pharun for more information if necessary.

To post a message you must log in.