I am going to compile the SDDS source on my Debian lenny/sid x64.
If I compile it as STATIC library, it goes well. But there are some problem if I build it as a shared library.
It complains that:
$ make
make -C O.linux-x86_64 -f ../Makefile TOP=../../../../.. T_A=linux-x86_64 install
make[1]: Entering directory `/usr/local/epics/extensions/src/SDDS/SDDSaps/sddsplots/O.linux-x86_64'
make[1]: *** No rule to make target `../../../../../lib/linux-x86_64/libXaw.a', needed by `sddsplot'. Stop.
make[1]: Leaving directory `/usr/local/epics/extensions/src/SDDS/SDDSaps/sddsplots/O.linux-x86_64'
make: *** [install.linux-x86_64] Error 2
It only appears on my Debian x64, and everything is fine if I compile it on my Debian x32.
How can I solve it?
Thanks,
Guobao
compile SDDS as SHARED_LIBRARIES on Debian X64
Re: compile SDDS as SHARED_LIBRARIES on Debian X64
Well the first question is do you have /usr/lib64/libXaw.so or /usr/lib64/libXaw.a installed? Usually if it finds those it won't go looking in ../../../../../lib/linux-x86_64
You can change where it looks by editing epics/extensions/configure/os/CONFIG_SITE.linux-x86_64.linux-x86_64 and changing the X11_LIB variable.
You can change where it looks by editing epics/extensions/configure/os/CONFIG_SITE.linux-x86_64.linux-x86_64 and changing the X11_LIB variable.
Re: compile SDDS as SHARED_LIBRARIES on Debian X64
Yes, I installed the all those libraries in the stand directory, and I can list them as below:
$ls /usr/lib/libXaw.* /usr/lib64/libXaw.*
/usr/lib64/libXaw.a /usr/lib64/libXaw.so /usr/lib64/libXaw.so.7 /usr/lib/libXaw.a /usr/lib/libXaw.so /usr/lib/libXaw.so.7
I also think it should not go looking into ../../../../../lib/linux-x86_64.
It might be worth noticing that when I compile it as static, there is no problem.
Thanks,
Guobao
$ls /usr/lib/libXaw.* /usr/lib64/libXaw.*
/usr/lib64/libXaw.a /usr/lib64/libXaw.so /usr/lib64/libXaw.so.7 /usr/lib/libXaw.a /usr/lib/libXaw.so /usr/lib/libXaw.so.7
I also think it should not go looking into ../../../../../lib/linux-x86_64.
It might be worth noticing that when I compile it as static, there is no problem.
Thanks,
Guobao
Re: compile SDDS as SHARED_LIBRARIES on Debian X64
I found what is the problem now.
The CONFIG_SITE.linux-x86_64.linux-x86_64 is missed under configure/os/.
But I still wonder why the static compile passed without it for a x64 machine.
Guobao
The CONFIG_SITE.linux-x86_64.linux-x86_64 is missed under configure/os/.
But I still wonder why the static compile passed without it for a x64 machine.
Guobao
soliday wrote:Well the first question is do you have /usr/lib64/libXaw.so or /usr/lib64/libXaw.a installed? Usually if it finds those it won't go looking in ../../../../../lib/linux-x86_64
You can change where it looks by editing epics/extensions/configure/os/CONFIG_SITE.linux-x86_64.linux-x86_64 and changing the X11_LIB variable.
Re: compile SDDS as SHARED_LIBRARIES on Debian X64
It looks like our epics.extensions.configure.tar.gz is pretty old and doesn't contain support for linux-x86_64. Did you get your build rules from another location or are you using the ones we supplied? I just updated epics.extensions.configure.tar.gz and oag.apps.configure.tar.gz on our web site to include support for linux-x86_64. Without it, the file I referenced earlier, epics/extensions/configure/os/CONFIG_SITE.linux-x86_64.linux-x86_64 would not exist on your system. That is unless you got the build rules from somewhere else.
As for the differences between building with STATIC_BUILD=YES and STATIC_BUILD=NO you can see the differences in the SDDS/SDDSaps/sddsplot/Makefile.OAG.
If with the new build rules you still have trouble, you can get it to work by editing SDDS/SDDSaps/sddsplot/Makefile.OAG and changing the line from:
PROD_LIBS_Linux += Xaw Xmu Xt Xext X11
to:
OP_SYS_LDLIBS = -lXaw -lXmu -lXt -lXext -lX11
As for the differences between building with STATIC_BUILD=YES and STATIC_BUILD=NO you can see the differences in the SDDS/SDDSaps/sddsplot/Makefile.OAG.
If with the new build rules you still have trouble, you can get it to work by editing SDDS/SDDSaps/sddsplot/Makefile.OAG and changing the line from:
PROD_LIBS_Linux += Xaw Xmu Xt Xext X11
to:
OP_SYS_LDLIBS = -lXaw -lXmu -lXt -lXext -lX11
Re: compile SDDS as SHARED_LIBRARIES on Debian X64
The rules for the static build are special in this directory. Statically linking these libraries to sddsplot will cause sddsplot to not work. So to get around it I have modified the Makefile.OAG to force it to link to a few dynamic libraries. This override is not in place for the non-static build.shengb wrote:I found what is the problem now.
The CONFIG_SITE.linux-x86_64.linux-x86_64 is missed under configure/os/.
But I still wonder why the static compile passed without it for a x64 machine.
Re: compile SDDS as SHARED_LIBRARIES on Debian X64
After I add the CONFIG_SITE.linux-x86_64.linux-x86_64 file, the whole compiling works smoothly.
Thanks for your explanation. Now the thing is clear to me why building with STATIC_BUILD=NO can work without that file.
Thanks again.
Guobao
Thanks for your explanation. Now the thing is clear to me why building with STATIC_BUILD=NO can work without that file.
Thanks again.
Guobao
soliday wrote:It looks like our epics.extensions.configure.tar.gz is pretty old and doesn't contain support for linux-x86_64. Did you get your build rules from another location or are you using the ones we supplied? I just updated epics.extensions.configure.tar.gz and oag.apps.configure.tar.gz on our web site to include support for linux-x86_64. Without it, the file I referenced earlier, epics/extensions/configure/os/CONFIG_SITE.linux-x86_64.linux-x86_64 would not exist on your system. That is unless you got the build rules from somewhere else.
As for the differences between building with STATIC_BUILD=YES and STATIC_BUILD=NO you can see the differences in the SDDS/SDDSaps/sddsplot/Makefile.OAG.
If with the new build rules you still have trouble, you can get it to work by editing SDDS/SDDSaps/sddsplot/Makefile.OAG and changing the line from:
PROD_LIBS_Linux += Xaw Xmu Xt Xext X11
to:
OP_SYS_LDLIBS = -lXaw -lXmu -lXt -lXext -lX11