-
Notifications
You must be signed in to change notification settings - Fork 352
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Shared library install path suffix not defined #12
Comments
Is this Suse specific or for all recent Linux systems. I don"t want to break anything. |
LIB_SUFFIX=64 for 64-bit Linux systems defined by Filesystem Hierarchy Standard and it is correctly at least for openSUSE and Fedora. In any case, may give any suffix for library path by use CMake -DLIB_SUFFIX option. "64" suffix automatically sets only if LIB_SUFFIX on 64-bit system not defined explicitly, for example by %cmake macros from rpm build system. |
This libsuffix might not be used on Debian-based systems (there were some issues with missing symlinks for compatibility but I don"t want to break anything currently). You can manually set -DLIB_SUFFIX. |
Ok. Thank you ntadej. |
RPM-based distros such as Fedora or Mageia put 64bit libraries in /usr/lib64 while 32bit libraries go to /usr/lib. This is usually taken into account in CMake projects using a LIB_SUFFIX parameter that can be set to "" or "64".
I"m building a vlc-qt for openSUSE 12.2 x86_64 by following the instructions in the INSTALL file:
$ cmake . -DCMAKE_INSTALL_PREFIX=/usr
$ make
make install.
and have issue with install path of .so and .pc files - there are installs to /usr/lib, not /usr/lib64 directory. It is wrong. RPM build also provides related errors. This is because the ${LIB_SUFFIX} is not defined in CMake and not passed explicitly by -DLIB_SUFFIX=64. In addition, libvlc-qt.pc install path omit LIB_SUFFIX. I wrote a patch:
--- CMakeLists.txt.orign 2012-12-21 00:40:21.747455383 +0400
+++ CMakeLists.txt 2012-12-21 00:43:50.383082960 +0400
@@ -143,6 +143,12 @@
SET(VLCQT_BINARY ${CMAKE_BINARY_DIR}/src/libvlc-qt.so)
ENDIF(MINGW)
+# Define shared library path suffix if not defined
+IF(NOT DEFINED LIB_SUFFIX)
+ENDIF(NOT DEFINED LIB_SUFFIX)
###########
Version
--- pkgconfig/CMakeLists.txt.orign 2012-12-20 21:18:44.327638377 +0400
+++ pkgconfig/CMakeLists.txt 2012-12-20 21:48:54.215499798 +0400
@@ -27,4 +27,4 @@
################
Installation
################
-INSTALL(FILES ${CMAKE_BINARY_DIR}/pkgconfig/libvlc-qt.pc DESTINATION ${CMAKE_INSTALL_PREFIX}/lib/pkgconfig)
+INSTALL(FILES ${CMAKE_BINARY_DIR}/pkgconfig/libvlc-qt.pc DESTINATION ${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX}/pkgconfig)
The text was updated successfully, but these errors were encountered: