Closed jobermayr closed 10 years ago
This looks wrong to me, and would break the existing packaging.
Debian ships this file list: https://packages.debian.org/wheezy/amd64/libtxc-dxtn-s2tc0/filelist
and it seems to work fine there.
What I could however agree to would be keeping the old names, and adding just the symlink libtxc_dxtn.so -> libtxc_dxtn.so.1.
[rpolzer@heizluefter s2tc -> master]$ ./configure
[rpolzer@heizluefter s2tc -> master]$ make
[rpolzer@heizluefter s2tc -> master]$ make DESTDIR=/tmp/s2tc install
...
/bin/sh ./libtool --mode=install /usr/bin/install -c libtxc_dxtn.la '/tmp/s2tc/usr/local/lib'
libtool: install: /usr/bin/install -c .libs/libtxc_dxtn.so.0.0.0 /tmp/s2tc/usr/local/lib/libtxc_dxtn.so.0.0.0
libtool: install: (cd /tmp/s2tc/usr/local/lib && { ln -s -f libtxc_dxtn.so.0.0.0 libtxc_dxtn.so.0 || { rm -f libtxc_dxtn.so.0 && ln -s libtxc_dxtn.so.0.0.0 libtxc_dxtn.so.0; }; })
libtool: install: (cd /tmp/s2tc/usr/local/lib && { ln -s -f libtxc_dxtn.so.0.0.0 libtxc_dxtn.so || { rm -f libtxc_dxtn.so && ln -s libtxc_dxtn.so.0.0.0 libtxc_dxtn.so; }; })
As you can see, it does install the .so symlink. If it doesn't do that on your system, I'd suggest contacting your distribution about properly configuring autoconf/automake/libtool.
Your decision is wrong. Main Linux distributions consider .so files as development files and ship them in extra -devel packages which are not installed by default. But you need !!! only !!! the .so file for dlopen (see my intial comment). Why do you need to install 3 files when only one is required and why do you want to strew confusion for packagers?
To clarify above comment: They consider .so files as development files only if also .so.* are there.
s3tc also ships only libtxc_dxtn.so: http://cgit.freedesktop.org/~mareko/libtxc_dxtn/tree/Makefile.am
Then it should be part of the distribution to filter what to install and what not. The part I really don't like it is subverting what libtool is doing there regarding file naming - if we decide to only create the .so, we should do it via libtool options and not by first using libtool, then wildly renaming stuff. Can you name any existing open source package doing this? If this is common practice, I will comply. But I've never seen a package doing stuff like that.
I however did now check what the other libtxc_dxtn does:
http://cgit.freedesktop.org/~mareko/libtxc_dxtn/tree/Makefile.am
does this work for you the way you want? I can add the flags that way then (I have nothing against the flags, but against the nonstandard make hackery).
Also, this library can be directly linked to (as done by the s2tc binary) instead of dlopening it.
Pushed a version with that under the branch name no-version-suffix. Can you test it?
https://github.com/divVerent/s2tc/blob/master/s2tc_compress.cpp#L577 https://github.com/divVerent/s2tc/blob/master/s2tc_decompress.cpp#L111