HI ,
I'm trying to compile 'expect' with static linkage using -static as CFLAGS .
It compiles well without the flag.
below is part log that shows failure
----------------------------------------------------------------------------------------
267 gcc -pipe \
268 -static -O2 -g -m32 -march=i686 -mtune=i686 -fmessage-length=0
-D_FORTIFY_SOURCE=2 -Wall -Wno-implicit-int -fPIC \
269 \
270 -fPIC \
271 -Wl,--export-dynamic \
272 -o expect exp_main_exp.o \
273 -L/usr/src/mcp/mcp5/BUILD/expect-5.43 -lexpect5.43.0 \
274 -L/usr/lib -ltcl8.4 \
275 -ldl -lieee -lm \
276 -Wl,-rpath,/usr/lib \
277 -Wl,-rpath,/usr/lib/expect5.43.0
278 /usr/bin/ld: cannot find -lexpect5.43.0
279 collect2: ld returned 1 exit status
280 make: *** [expect] Error 1
281 error: Bad exit status from /var/tmp/rpm-tmp.55985 (%build)
----------------------------------------------------------------------------------------
below is the succecc log i.e. without -static
----------------------------------------------------------------------------------------
gcc -pipe \
-O2 -g -m32 -march=i686 -mtune=i686 -fmessage-length=0
-D_FORTIFY_SOURCE=2 -Wall -Wno-implicit-int -fPIC \
\
-fPIC \
-Wl,--export-dynamic \
-o expect exp_main_exp.o \
-L/usr/src/mcp/mcp5/BUILD/expect-5.43 -lexpect5.43.0 \
-L/usr/lib -ltcl8.4 \
-ldl -lieee -lm \
-Wl,-rpath,/usr/lib \
-Wl,-rpath,/usr/lib/expect5.43.0
: expect
(echo 'package ifneeded Expect 5.43.0 \
[list load libexpect5.43.0.so]'\
) > pkgIndex.tcl
+ make test
(echo 'package ifneeded Expect 5.43.0 \
[list load libexpect5.43.0.so]'\
) > pkgIndex.tcl
TCL_LIBRARY=`echo /usr/src/mcp/mcp5/BUILD/tcl8.4.12/library`
LD_LIBRARY_PATH=".:/usr/lib:"
PATH=".:/usr/lib:/bin:/usr/bin:/sbin:/usr/sbin:/usr/X11R6/bin:/usr/local/bin"
TCLLIBPATH="." /usr/lib/../bin/tclsh8.4 `echo ./tests/all.tcl`
cat.test
----------------------------------------------------------------------------------------
i do not see any file as expect5.43.0 in /usr/lib in any of the case
ya /usr/lib has libexpect5.43.0.so
below is the related part of the makefile
----------------------------------------------------------------------------------------
expect: exp_main_exp.o $(PKG_LIB_FILE)
$(CC) \
-O2 -g -m32 -march=i686 -mtune=i686 -fmessage-length=0
-D_FORTIFY_SOURCE=2 ${CFLAGS_DEFAULT} ${CFLAGS_WARNING} ${SHLIB_CFLAGS} \
\
-fPIC \
-Wl,--export-dynamic \
-o expect exp_main_exp.o \
-L/usr/src/mcp/mcp5/BUILD/expect-5.43 -lexpect5.43.0 \
-L/usr/lib -ltcl8.4 \
-ldl -lieee -lm \
-Wl,-rpath,${LIB_RUNTIME_DIR} \
-Wl,-rpath,${LIB_RUNTIME_DIR}/${PACKAGE_NAME}${PACKAGE_VERSION}
$(SETUID) expect
----------------------------------------------------------------------------------------
i'm not able to makeout why it fails as -static
complete makefile without -static is attached
any suggestions ...
Share files, take polls, and discuss your passions - all under one roof.
Go to http://in.promos.yahoo.com/groups
[Non-text portions of this message have been removed]
To unsubscribe from this list, please email [EMAIL PROTECTED] & you will be
removed.
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/LINUX_Newbies/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/LINUX_Newbies/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/