John Vickers wrote:
>
> Hello.
>
> I think there are some problems with configuring & building xsane.
>
> In short, I think we need:
> - A way of specifing the location of the sane installation to build with.
> --with-sane= ??
> - A way of specifying static linking for the xsane executable.
>
> This seems like reasonably standard configury stuff. Not that I'm an
> expert on autoconf...
>
> Building xsane out-of-the-box on a Linux distribution
> which includes sane is almost bound to fail: the linked libsane
> will be the libsane from /usr/lib, and include files will be taken from
> /usr/include
>
> E.g. after configuring xsane-0.55 with --prefix=/home/pkg/test
> --disable-shared
> I see the following link command for xsane:
>
> gcc -o xsane xsane-back-gtk.o xsane-front-gtk.o xsane-gamma.o
> xsane-preview.o xsane-rc-io.o xsane-device-preferences.o
> xsane-preferences.o
> xsane-setup.o xsane-save.o xsane-scan.o xsane-icons.o xsane.o \
> ../lib/liblib.a -lgimp -L/usr/lib -L/usr/X11R6/lib -lgtk -lgdk
> -rdynamic -lgmodule -lglib -ldl -lXext -lX11 -lm -lpng -lsane -ldl
> -ltiff -ljpeg -lz -lm
>
> I think the recommendation of removing any existing Sane installation
> may not be an option for policy reasons or simply because necessary
> permissions are unavailable.
>
> My bodge to make xsane link was to configure with:
> CC="gcc -L/home/pkg/test/lib -I/home/pkg/test/include"
>
> and ewither run the executable with LD_LIBRARY_PATH=/home/pkg/test/lib
> or link a static binary based on the command line above.
>
> Solutions:
> - "One-tree-build": move xsane into the sane tree. Does this just work ?
> Is there any reason for not doing this ?
> - Put -L$(libdir) in the link command, and -I$(includedir) in the compile
> commands.
> This will work if, as seems reasonably likely, xsane is being installed
> to the same place as sane.
>
> Other problems (installation instructions):
>
> The installation instruction to do "make install" as root
> is unnecessary, and arguably a bad idea. So long as the install dirs are
> writable, there should be no problem.
>
> Similarly, editing /etc/ld.so.conf (or equivalent) is not strictly
> necessary. The dynamic library search path can be modified by setting
> LD_LIBRARY_PATH e.g. in ~/.profile.
>
> Regards,
>
> John.
John,
I just finished compiling xsane 0.56 and got the same link statements
as you. But when I run 'ldd xsane', I get:
[root@darkside bin]# ldd xsane
libgimp.so.1 => /usr/lib/libgimp.so.1 (0x4001a000)
libgtk-1.2.so.0 => /usr/lib/libgtk-1.2.so.0 (0x4002a000)
libgdk-1.2.so.0 => /usr/lib/libgdk-1.2.so.0 (0x4016b000)
libgmodule-1.2.so.0 => /usr/lib/libgmodule-1.2.so.0 (0x401a0000)
libglib-1.2.so.0 => /usr/lib/libglib-1.2.so.0 (0x401a4000)
libdl.so.2 => /lib/libdl.so.2 (0x401c9000)
libXext.so.6 => /usr/X11R6/lib/libXext.so.6 (0x401cd000)
libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x401da000)
libm.so.6 => /lib/libm.so.6 (0x4028c000)
libpng.so.2 => /usr/lib/libpng.so.2 (0x402aa000)
libsane.so.1 => /usr/local/lib/libsane.so.1 (0x402ca000)
libtiff.so.3 => /usr/lib/libtiff.so.3 (0x402cf000)
libjpeg.so.62 => /usr/lib/libjpeg.so.62 (0x402fd000)
libz.so.1 => /usr/lib/libz.so.1 (0x4031e000)
libc.so.6 => /lib/libc.so.6 (0x4032d000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)
Which shows where libsane.so.1 lives. I don't see one in /usr/lib.
Bill
-- Source code, list archive, and docs: http://www.mostang.com/sane/ To unsubscribe: echo unsubscribe sane-devel | mail majordomo@mostang.com
This archive was generated by hypermail 2b29 : Thu Feb 17 2000 - 03:31:59 PST