error: cannot install 'libx52util.la' to a directory not ending in /usr/local/lib
Closed this issue · 11 comments
This is a new "git clone/pull". Because of the substantial changes, I had to remove/wipe previous "git clone/pull". (ie. Wasn't sure "make clean" was going to work properly anymore, etc etc.)
./autogen && ./configure --prefix=/home/roger/src/x52pro-linux/install && make && make install
I get the following errors during "make install"
libtool: warning: remember to run 'libtool --finish /usr/local/lib'
libtool: warning: '../libx52/libx52.la' has not been installed in '/usr/local/lib'
libtool: warning: '../libx52/libx52.la' has not been installed in '/usr/local/lib'
libtool: error: error: cannot install 'libx52util.la' to a directory not ending in /usr/local/lib
Looks like the previous is defined within:
./libx52/libx52.la:libdir='/usr/local/lib'
./util/libx52util.la:libdir='/usr/local/lib'
I just tried and couldn't reproduce the problem. Can you try to run git clean -xfd
from the root folder and try the steps again? There's a possibility that if there was any old content leftover by mistake, it could cause the issue you were seeing.
Based on http://stackoverflow.com/questions/10279829/installing-glib-in-non-standard-prefix-fails and https://bz.apache.org/bugzilla/show_bug.cgi?id=35098#c9, a make clean
is always required after running configure, even on a fresh download. git clean -xfd
just takes it one step further and deletes all files that are not part of the repo, including the ones ignored by .gitignore
.
Thanks for the note concerning "git clean -xfd".
However, I already did previously perform a rm -rf ./x52pro-linux, which removed the root .git folders.
I'll redo everything again and see what happens. Gentoo does not use /usr/local unless those packages are binary only or proprietary, nor do I use /usr/local. Usually when I see this, it's usually because of the developer's custom settings are still preserved within the main repository. Also note, I was not installing the package within my root /usr or /usr/local, and am specifying a local or $HOME folder for installing the compiled targets.
I did as you advised, and these are now the warnings I see. (I see no failures any more.)
libtool: warning: relinking 'libx52util.la'
libtool: warning: remember to run 'libtool --finish /home/roger/src/x52pro-linux/x52pro-linux/x52pro-linux-0.1.0/_inst/lib'
libtool: warning: '../libx52/libx52.la' has not been installed in '/home/roger/src/x52pro-linux/x52pro-linux/x52pro-linux-0.1.0/_inst/lib'
libtool: warning: '../libx52/libx52.la' has not been installed in '/home/roger/src/x52pro-linux/x52pro-linux/x52pro-linux-0.1.0/_inst/lib'
libtool: warning: relinking 'libx52util.la'
libtool: warning: remember to run 'libtool --finish /home/roger/src/x52pro-linux/x52pro-linux/x52pro-linux-0.1.0/_inst/lib'
I also now see the x52cli was moved to the root folder cli/! Since there were so many changes, I had doubts "make clean" would remove the objects within the sub folders, so I just "rm -rf" everything initially. Thank God for GCC color, I can now see warning and errors much easier within the terminal history. Again, just warnings and I don't know if you're worried about them. Really, they appear to be just "notes" and "reminders" if you ask me.
I don't believe I have anything custom within the repo, and to the best of my knowledge, make distcheck
does try to do an install in a non standard location, and that's passing.
Do let me know if you still have issues, and I'll try to bring up a Gentoo VM and test it there.
Was still in the process of finessing my last comment. ;-)
We can probably close this if those warnings are of no concern.
I'm still kind of learning the Autotools/Libtool framework, and it seems like it's only the *.la files, which are only used by libtool and not needed after the files are successfully installed. Refer http://osdir.com/ml/db.monetdb.bugs/2008-02/msg00222.html.
Yea, I've read the book(s) too, and simply just understand the need and what is being performed. But still find the tools extremely confusing, especially when debugging. I also understand C structs and pointers better now, but typedefs seem like just another curve ball.
But I think we can pretty much conclude, you're doing tens times better than I, with the exception I have so little time at most times of the day.
I can see things rapidly changing, and on my latest compile, I see one remaining warning.
libtool: warning: relinking 'libx52util.la'
Cheers. Looks really clean and ready for packaging.
That last warning seems to be expected behavior based on http://osdir.com/ml/libtool-gnu/2009-12/msg00069.html
when i make install
, i got
make[3]: Entering directory '/home/rongtao/rpm-4.17.0/lib'
make[4]: Entering directory '/home/rongtao/rpm-4.17.0/lib'
make[4]: Nothing to be done for 'install-exec-am'.
/usr/bin/mkdir -p '/usr/lib64'
/bin/sh ../libtool --mode=install /usr/bin/install -c librpm.la '/usr/lib64'
libtool: error: error: cannot install 'librpm.la' to a directory not ending in /usr/local/lib