A more careful look at the error message shows that it is failing when it builds the LIB (.dll), not when it builds the PROD.
Thus, the line needed is
LIB_LIBS += visa32
And for the PROD should be
PROD_LIBS += visa32
It shoud not be SYS_PROD_LIBS, because that tells it to look in other places besides where you copied it.
Mark
________________________________
From: [email protected] on behalf of zhangning2095
Sent: Sun 9/5/2010 10:07 PM
To: tech-talk
Subject: Build IOC linking external *.lib file failed
Hi,All:
I am trying to setup a IOC example in tek DPO scope, which need to use the visa32.lib in this project, I copied visa32.lib
to $(top)/myAppapp/lib folder(top is the root of this example),and in makefile in src,I add the following line:
#----------------------------------------
# ADD MACRO DEFINITIONS AFTER THIS LINE
SYS_PROD_LIBS += $(TOP)/myappApp/lib/visa32
#=============================
and build failed, could you tell me how to do ?
Thank you
Tomas
2010.9.2
PS:my enveriment is : winXP, cygwin1.5, gcc, make 3.81, perl, base 3.14.11
and this is the result :
??@zn /cygdrive/c/testapp
$ make
make -C ./configure install
make[1]: Entering directory `/cygdrive/c/testapp/configure'
make -C O.cygwin-x86 -f ../Makefile TOP=../.. T_A=cygwin-x86 install
make[2]: Entering directory `/cygdrive/c/testapp/configure/O.cygwin-x86'
perl /cygdrive/c/base-3.14.11/bin/cygwin-x86/convertRelease.pl checkRelease
make[2]: Leaving directory `/cygdrive/c/testapp/configure/O.cygwin-x86'
make[1]: Leaving directory `/cygdrive/c/testapp/configure'
make -C ./myappApp install
make[1]: Entering directory `/cygdrive/c/testapp/myappApp'
make -C ./src install
make[2]: Entering directory `/cygdrive/c/testapp/myappApp/src'
make -C O.cygwin-x86 -f ../Makefile TOP=../../.. T_A=cygwin-x86 install
make[3]: Entering directory `/cygdrive/c/testapp/myappApp/src/O.cygwin-x86'
perl /cygdrive/c/base-3.14.11/bin/cygwin-x86/makeIncludeDbd.pl base.dbd xxxSuppo
rt.dbd dbSubExample.dbd myappHello.dbd initTrace.dbd ../O.Common/myappInclude.db
d
Expanding dbd
/cygdrive/c/base-3.14.11/bin/cygwin-x86/dbExpand.exe -I . -I .. -I ../../../dbd
-I/cygdrive/c/base-3.14.11/dbd -o ../O.Common/myapp.dbd ../O.Common/myappInclud
e.dbd
Installing created dbd file ../../../dbd/myapp.dbd
g++ -o myappSupport.dll -shared -Wl,--out-implib,myappSupport.lib -Lc:/base-3.14
.11/lib/cygwin-x86 -m32 xxxRecord.o devXxxSoft.o dbSubExampl
e.o myappHello.o initTrace.o devWfSoft.o -lrecIoc -lsoftDevIoc -lmiscIoc -lrs
rvIoc -ldbtoolsIoc -lasIoc -ldbIoc -lregistryIoc -ldbStaticIoc -lca -lCom -l../
../../myappApp/lib/visa32 -lpthread -lreadline -lcurses -lm
/usr/lib/gcc/i686-pc-cygwin/3.4.4/../../../../i686-pc-cygwin/bin/ld: cannot find
-l../../../myappApp/lib/visa32
collect2: ld returned 1 exit status
make[3]: *** [myappSupport.dll] Error 1
make[3]: Leaving directory `/cygdrive/c/testapp/myappApp/src/O.cygwin-x86'
make[2]: *** [install.cygwin-x86] Error 2
make[2]: Leaving directory `/cygdrive/c/testapp/myappApp/src'
make[1]: *** [src.install] Error 2
make[1]: Leaving directory `/cygdrive/c/testapp/myappApp'
make: *** [myappApp.install] Error 2
??@zn /cygdrive/c/testapp
$
Tomas
2010-9-2
- References:
- Build IOC linking external *.lib file failed zhangning2095
- Navigate by Date:
- Prev:
RE: sscan 2-6-6 does not build with cygwin DLL release version 1.7.7-1 Wang Xiaoqiang
- Next:
issues with drvEtherIP V2.19 - ControlLogix 5000 PLC via EtherNet/IP Jeff Hill
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
<2010>
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
RE: Build IOC linking external *.lib file failed Mark Rivers
- Next:
msi and scoping Benjamin Franksen
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
<2010>
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
|