Hello,

I have been working with Nicolas Lécureuil, the Mandriva packager, to fix the install target of the WengoPhone.

The attached patch (for the 2.1 branch) is a rewrite of the install target, using CMake functions. It lets you specify the installation prefix using the standard CMake syntax[1]. It also gives you support for the DESTDIR variable, which is very useful for packagers.

Since I can't test it on all distributions, it would be nice if you could give it a try before I commit it. If you get weird results, you may need to rm your CMakeCache.txt file, since I changed the values of some vars.

Aurélien

[1] cmake -DCMAKE_INSTALLATION_PREFIX=/somewhere
Index: wengophone/src/presentation/qt/CMakeLists.txt
===================================================================
--- wengophone/src/presentation/qt/CMakeLists.txt       (révision 9574)
+++ wengophone/src/presentation/qt/CMakeLists.txt       (copie de travail)
@@ -519,7 +519,36 @@
 endif (APPLE)
 
 if (LINUX)
-       install(SCRIPT CMakeLists-install-linux.txt)
+       INSTALL(TARGETS
+               qtwengophone
+               RUNTIME DESTINATION bin)
+
+       INSTALL(PROGRAMS
+               ${TMP_BUILD_DIR}/libowcurl.so
+               ${TMP_BUILD_DIR}/libowwebcam.so
+               ${TMP_BUILD_DIR}/libphamrplugin.so
+               ${TMP_BUILD_DIR}/libphapi.so
+               ${TMP_BUILD_DIR}/libphspeexplugin.so
+               ${TMP_BUILD_DIR}/libportaudio.so
+               ${TMP_BUILD_DIR}/libsfp-plugin.so
+               DESTINATION lib${LIB_SUFFIX})
+
+       INSTALL(DIRECTORY
+               ${TMP_BUILD_DIR}/lang
+               DESTINATION ${DATA_INSTALL_DIR}
+               PATTERN "*.qm")
+
+       INSTALL(DIRECTORY
+               ${CMAKE_SOURCE_DIR}/wengophone/sounds
+               ${CMAKE_SOURCE_DIR}/wengophone/pics
+               pics/emoticons
+               DESTINATION ${DATA_INSTALL_DIR}
+               PATTERN ".svn" EXCLUDE
+               PATTERN "CMakeLists.txt" EXCLUDE)
+
+       INSTALL(FILES
+               ${CMAKE_SOURCE_DIR}/wengophone/COPYING
+               DESTINATION ${DATA_INSTALL_DIR})
 endif (LINUX)
 
 if (WIN32)
Index: DefineInstallationPaths.cmake
===================================================================
--- DefineInstallationPaths.cmake       (révision 9574)
+++ DefineInstallationPaths.cmake       (copie de travail)
@@ -11,10 +11,6 @@
 if (LINUX)
        set(DATA_COPY_DIR ${BUILD_DIR} 
                CACHE PATH "Data/resources (sounds, translations...) copy path")
-       set(DATA_INSTALL_DIR "/usr/share/wengophone"
+       set(DATA_INSTALL_DIR "share/wengophone"
                CACHE PATH "Data/resources (sounds, translations...) 
installation path")
-       set(APPLICATION_BIN_INSTALL_DIR "/usr/bin"
-               CACHE PATH "Application binary installation path")
-       set(LIBRARIES_INSTALL_DIR "/usr/lib${LIB_SUFFIX}/wengophone"
-               CACHE PATH "Libraries installation path")
 endif (LINUX)
_______________________________________________
Wengophone-devel mailing list
Wengophone-devel@lists.openwengo.com
http://dev.openwengo.com/mailman/listinfo/wengophone-devel

Reply via email to