Marcus Rueckert wrote:
On 2007-08-28 18:44:39 +0200, Dirk Stoecker wrote:
I added a new project qgis, which fails under 64bit openSUSE (due to the libraries).
http://build.opensuse.org/package/show?package=qgis&project=home%3Adstoecker
My question is: How can I tell cmake, that the installation directory of the final library is /usr/lib64 and not /usr/lib.
The CMakeList.txt files must also be patched, as it hardcodes the path for the subdirectory: How can I fix that? Is there a variable I could enter instead of /lib/?
Copying the files after the install step seems to be an option, but not a good one I would say.
Any cmake-using-package packagers here?
install 10.3 and kde4-filesystem. that will give you an /etc/rpm/macros.kde4. that has an macro called cmake_kde4
[[[ %cmake_kde4(d:) \ export CFLAGS=$RPM_OPT_FLAGS \ _kde_libsuffix=$(echo %_lib | cut -b4-) \ bdir=. \ %{-d:dir=%{-d*} \ mkdir $dir \ cd $dir \ bdir=.. } \ cmake -DCMAKE_INSTALL_PREFIX=%{_kde_prefix} -DLIB_SUFFIX="$_kde_libsuffix" -DCMAKE_BUILD_TYPE=%{_kde_build_type} $bdir \ %{nil} ]]]
you could minimize it to: cmake -DCMAKE_INSTALL_PREFIX=%{_prefix} -DLIB_SUFFIX="$(echo %_lib | cut -b4-)"
LIB_SUFFIX is not a CMake variable. It is defined by KDE4 to install the libraries in the right directory. # Suffix for Linux SET(LIB_SUFFIX CACHE STRING "Define suffix of directory name (32/64)" ) SET(LIB_INSTALL_DIR "${EXEC_INSTALL_PREFIX}/lib${LIB_SUFFIX}" CACHE PATH "The subdirectory relative to the install prefix where libraries will be installed (default is prefix/lib)" FORCE ) The CMakeLists.txt have to be fixed!
hope this helps
darix
-- andreas -- http://www.cynapses.org/ - cybernetic synapses