[CMake] cmake error when trying to compile KMyMoney 3.97.1
Pierre Maurier
pierre.maurier at gadz.org
Sun Apr 4 04:53:25 EDT 2010
Hi,
I'm new in this mailing list and new in cmake compiling in general,
I have a cmake error when trying to compile KMyMoney 3.97.1 on OSX.
Here is the output :
===================================================================
$ cmake -D CMAKE_BUILD_TYPE='Released' ..
-- The C compiler identification is GNU
-- The CXX compiler identification is GNU
-- Checking whether C compiler has -isysroot
-- Checking whether C compiler has -isysroot - yes
-- Checking whether C compiler supports OSX deployment target flag
-- Checking whether C compiler supports OSX deployment target flag - yes
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Checking whether CXX compiler has -isysroot
-- Checking whether CXX compiler has -isysroot - yes
-- Checking whether CXX compiler supports OSX deployment target flag
-- Checking whether CXX compiler supports OSX deployment target flag - yes
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Looking for Q_WS_X11
-- Looking for Q_WS_X11 - not found.
-- Looking for Q_WS_WIN
-- Looking for Q_WS_WIN - not found.
-- Looking for Q_WS_QWS
-- Looking for Q_WS_QWS - not found.
-- Looking for Q_WS_MAC
-- Looking for Q_WS_MAC - found
-- Looking for QT_MAC_USE_COCOA
-- Looking for QT_MAC_USE_COCOA - found
-- Found Qt-Version 4.6.2 (using /opt/local/bin/qmake-mac)
-- Looking for include files CMAKE_HAVE_PTHREAD_H
-- Looking for include files CMAKE_HAVE_PTHREAD_H - found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found OpenSSL: /usr/lib/libssl.dylib
-- Found Automoc4: /opt/local/bin/automoc4
-- Found Perl: /opt/local/bin/perl
-- Phonon Version: 4.3.1
-- Found Phonon: /opt/local/libexec/qt4-mac/lib/phonon.framework
-- Found Phonon Includes:
/opt/local/libexec/qt4-mac/lib/phonon.framework/KDE;/opt/local/libexec/qt4-mac/lib/phonon.framework
-- Performing Test _OFFT_IS_64BIT
-- Performing Test _OFFT_IS_64BIT - Success
-- Performing Test HAVE_FPIE_SUPPORT
-- Performing Test HAVE_FPIE_SUPPORT - Success
-- Performing Test __KDE_HAVE_W_OVERLOADED_VIRTUAL
-- Performing Test __KDE_HAVE_W_OVERLOADED_VIRTUAL - Success
-- Performing Test __KDE_HAVE_GCC_VISIBILITY
-- Performing Test __KDE_HAVE_GCC_VISIBILITY - Success
-- Found KDE 4.4 include dir: /opt/local/include
-- Found KDE 4.4 library dir: /opt/local/lib
-- Found the KDE4 kconfig_compiler preprocessor: /opt/local/bin/kconfig_compiler
-- Found automoc4: /opt/local/bin/automoc4
-- Boost version: 1.42.0
-- Found the following Boost libraries:
-- graph
-- Found gpgme-config at /opt/local/bin/gpgme-config
-- Found gpgme v1.2.0, checking for flavours...
-- Found flavour 'vanilla', checking whether it's usable...yes
-- Found flavour 'pthread', checking whether it's usable...yes
-- Found flavour 'pth', checking whether it's usable...yes
-- Usable gpgme flavours found: vanilla pthread pth
-- Found QGpgme: /opt/local/lib/libqgpgme.dylib
-- Found KdepimLibs: /opt/local/lib/cmake/KdepimLibs/KdepimLibsConfig.cmake
-- Found shared-mime-info version: 0.71
-- Found JPEG: /opt/local/lib/libjpeg.dylib
-- Found ZLIB: /usr/lib/libz.dylib
-- Found PNG: /opt/local/lib/libpng.dylib
-- Found Doxygen: /opt/local/bin/doxygen
-- checking for modules 'libxml-2.0;libxml++-2.6;glib-2.0;glibmm-2.4'
-- package 'libxml++-2.6' not found
-- package 'glibmm-2.4' not found
-- Looking for atoll
-- Looking for atoll - found
-- Looking for vsnprintf
-- Looking for vsnprintf - found
-- Looking for strtoll
-- Looking for strtoll - found
-- Looking for round
-- Looking for round - found
-- Looking for res_init
-- Looking for res_init - not found.
-- Performing Test HAVE_RES_INIT_PROTO
-- Performing Test HAVE_RES_INIT_PROTO - Failed
-- Looking for crypt
-- Looking for crypt - not found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for dlfcn.h
-- Looking for dlfcn.h - found
-- Looking for inttypes.h
-- Looking for inttypes.h - found
-- Looking for memory.h
-- Looking for memory.h - found
-- Looking for stdlib.h
-- Looking for stdlib.h - found
-- Looking for strings.h
-- Looking for strings.h - found
-- Looking for string.h
-- Looking for string.h - found
-- Looking for sys/bitypes.h
-- Looking for sys/bitypes.h - not found
-- Looking for sys/stat.h
-- Looking for sys/stat.h - found
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for unistd.h
-- Looking for unistd.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of char*
-- Check size of char* - failed
-- Check size of int
-- Check size of int - failed
-- Check size of long
-- Check size of long - failed
-- Check size of short
-- Check size of short - failed
-- Check size of size_t
-- Check size of size_t - failed
-- Check size of unsigned long
-- Check size of unsigned long - failed
-- checking for module 'libofx'
-- found libofx, version 0.9.1
-- Found LibOfx: /opt/local/lib/libofx.dylib
-- Could not find Gwenhywfar headers and the KBanking plugin will not
be compiled. If you do have the Gwenhywfar development package
installed use the GWENHYWFAR_BASE cmake variable to point to the
location where Gwenhywfar is installed
-- AqBanking headers not found. If you do have
-- the AqBanking development package installed use
-- the AQBANKING_BASE cmake variable to point to
-- the location where AqBanking is installed.
-- Found Libical version 0.43
-- Found LIBICAL: /opt/local/lib/libical.dylib;/opt/local/lib/libicalss.dylib
-- Looking for RPMTools... - rpmbuild NOT FOUND
-------- KMyMoney 3.97.1 --------
Configure results (user options):
--------------------------------------------
OFX plugin: yes
KBanking plugin: no
iCalendar export plugin: yes
--------------------------------------------
Configure results (developer options):
--------------------------------------------
Qt-Designer library support: no
Developer documentation generation: no
CPPUNIT support: yes
build tests: no
Doxygen support: yes
Build type: Released
--------------------------------------------
Good - your configure finished.
Now type 'make' to build KMyMoney. For more help, consult README.cmake
-- Looking for dgettext
-- Looking for dgettext - not found
-- Looking for dgettext in /opt/local/lib/libintl.dylib
-- Looking for dgettext in /opt/local/lib/libintl.dylib - not found
CMake Error at /opt/local/share/apps/cmake/modules/FindGettext.cmake:61
(message):
Could NOT find Gettext
Call Stack (most recent call first):
CMakeLists.txt:481 (find_package)
-- Configuring incomplete, errors occurred!
===================================================================
I understand that gettext is not found but I have installed it with
MacPorts and here it is :
===================================================================
$ which gettext
/opt/local/bin/gettext
===================================================================
I tried to look into
/opt/local/share/apps/cmake/modules/FindGettext.cmake to find which
Variable is causing an issue but... it is beyond my skills !
===================================================================
$ cat /opt/local/share/apps/cmake/modules/FindGettext.cmake
# Try to find Gettext functionality
# Once done this will define
#
# GETTEXT_FOUND - system has Gettext
# GETTEXT_INCLUDE_DIR - Gettext include directory
# GETTEXT_LIBRARIES - Libraries needed to use Gettext
# TODO: This will enable translations only if Gettext functionality is
# present in libc. Must have more robust system for release, where Gettext
# functionality can also reside in standalone Gettext library, or the one
# embedded within kdelibs (cf. gettext.m4 from Gettext source).
#
# Copyright (c) 2006, Chusslove Illich, <caslav.ilic at gmx.net>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
if (LIBC_HAS_DGETTEXT OR LIBINTL_HAS_DGETTEXT)
# in cache already
set(GETTEXT_FOUND TRUE)
else (LIBC_HAS_DGETTEXT OR LIBINTL_HAS_DGETTEXT)
include(CheckLibraryExists)
include(CheckFunctionExists)
find_path(GETTEXT_INCLUDE_DIR libintl.h)
if(GETTEXT_INCLUDE_DIR)
set(HAVE_LIBINTL_H 1)
else(GETTEXT_INCLUDE_DIR)
set(HAVE_LIBINTL_H 0)
endif(GETTEXT_INCLUDE_DIR)
set(GETTEXT_LIBRARIES)
if (HAVE_LIBINTL_H)
check_function_exists(dgettext LIBC_HAS_DGETTEXT)
if (LIBC_HAS_DGETTEXT)
set(GETTEXT_SOURCE "built in libc")
set(GETTEXT_FOUND TRUE)
else (LIBC_HAS_DGETTEXT)
find_library(LIBINTL_LIBRARY NAMES intl libintl )
check_library_exists(${LIBINTL_LIBRARY} "dgettext" ""
LIBINTL_HAS_DGETTEXT)
if (LIBINTL_HAS_DGETTEXT)
set(GETTEXT_SOURCE "in ${LIBINTL_LIBRARY}")
set(GETTEXT_LIBRARIES ${LIBINTL_LIBRARY})
set(GETTEXT_FOUND TRUE)
endif (LIBINTL_HAS_DGETTEXT)
endif (LIBC_HAS_DGETTEXT)
endif (HAVE_LIBINTL_H)
if (GETTEXT_FOUND)
if (NOT Gettext_FIND_QUIETLY)
message(STATUS "Found Gettext: ${GETTEXT_SOURCE}")
endif (NOT Gettext_FIND_QUIETLY)
else (GETTEXT_FOUND)
if (Gettext_FIND_REQUIRED)
message(FATAL_ERROR "Could NOT find Gettext")
endif (Gettext_FIND_REQUIRED)
endif (GETTEXT_FOUND)
mark_as_advanced(GETTEXT_INCLUDE_DIR GETTEXT_LIBRARIES)
endif (LIBC_HAS_DGETTEXT OR LIBINTL_HAS_DGETTEXT)
# - Find GNU gettext tools
# This module looks for the GNU gettext tools. This module defines the
# following values:
# GETTEXT_MSGMERGE_EXECUTABLE: the full path to the msgmerge tool.
# GETTEXT_MSGFMT_EXECUTABLE: the full path to the msgfmt tool.
# GETTEXT_FOUND: True if gettext has been found.
#
# Additionally it provides the following macros:
# GETTEXT_CREATE_TRANSLATIONS ( outputFile [ALL] file1 ... fileN )
# This will create a target "translations" which will convert the
# given input po files into the binary output mo file. If the
# ALL option is used, the translations will also be created when
# building the default target.
# GETTEXT_PROCESS_POT( <potfile> [ALL] [INSTALL_DESTINATION <destdir>]
<lang1> <lang2> ... )
# Process the given pot file to mo files.
# If INSTALL_DESTINATION is given then automatically install rules
will be created,
# the language subdirectory will be taken into account (by default
use share/locale/).
# If ALL is specified, the pot file is processed when building the
all traget.
# It creates a custom target "potfile".
#
# GETTEXT_PROCESS_PO_FILES(<lang> [ALL] [INSTALL_DESTINATION <dir>]
<po1> <po2> ...)
# Process the given po files to mo files for the given language.
# If INSTALL_DESTINATION is given then automatically install rules
will be created,
# the language subdirectory will be taken into account (by default
use share/locale/).
# If ALL is specified, the po files are processed when building
the all traget.
# It creates a custom target "pofiles".
FIND_PROGRAM(GETTEXT_MSGMERGE_EXECUTABLE msgmerge)
FIND_PROGRAM(GETTEXT_MSGFMT_EXECUTABLE msgfmt)
MACRO(GETTEXT_CREATE_TRANSLATIONS _potFile _firstPoFile)
SET(_gmoFiles)
GET_FILENAME_COMPONENT(_potBasename ${_potFile} NAME_WE)
GET_FILENAME_COMPONENT(_absPotFile ${_potFile} ABSOLUTE)
SET(_addToAll)
IF(${_firstPoFile} STREQUAL "ALL")
SET(_addToAll "ALL")
SET(_firstPoFile)
ENDIF(${_firstPoFile} STREQUAL "ALL")
FOREACH (_currentPoFile ${ARGN})
GET_FILENAME_COMPONENT(_absFile ${_currentPoFile} ABSOLUTE)
GET_FILENAME_COMPONENT(_abs_PATH ${_absFile} PATH)
GET_FILENAME_COMPONENT(_lang ${_absFile} NAME_WE)
SET(_gmoFile ${CMAKE_CURRENT_BINARY_DIR}/${_lang}.gmo)
ADD_CUSTOM_COMMAND(
OUTPUT ${_gmoFile}
COMMAND ${GETTEXT_MSGMERGE_EXECUTABLE} --quiet --update
--backup=none -s ${_absFile} ${_absPotFile}
COMMAND ${GETTEXT_MSGFMT_EXECUTABLE} -o ${_gmoFile} ${_absFile}
DEPENDS ${_absPotFile} ${_absFile}
)
INSTALL(FILES ${_gmoFile} DESTINATION
share/locale/${_lang}/LC_MESSAGES RENAME ${_potBasename}.mo)
SET(_gmoFiles ${_gmoFiles} ${_gmoFile})
ENDFOREACH (_currentPoFile )
ADD_CUSTOM_TARGET(translations ${_addToAll} DEPENDS ${_gmoFiles})
ENDMACRO(GETTEXT_CREATE_TRANSLATIONS )
# GETTEXT_PROCESS_POT( <potfile> [ALL] [INSTALL_DESTINATION <destdir>]
<lang1> <lang2> ... )
MACRO(GETTEXT_PROCESS_POT_FILE _potFile)
SET(_gmoFiles)
SET(_args ${ARGN})
SET(_addToAll)
SET(_installDest)
IF(_args)
LIST(GET _args 0 _tmp)
IF("${_tmp}" STREQUAL "ALL")
SET(_addToAll ALL)
LIST(REMOVE_AT _args 0)
ENDIF("${_tmp}" STREQUAL "ALL")
ENDIF(_args)
IF(_args)
LIST(GET _args 0 _tmp)
IF("${_tmp}" STREQUAL "INSTALL_DESTINATION")
LIST(GET _args 1 _installDest )
LIST(REMOVE_AT _args 0 1)
ENDIF("${_tmp}" STREQUAL "INSTALL_DESTINATION")
ENDIF(_args)
GET_FILENAME_COMPONENT(_potBasename ${_potFile} NAME_WE)
GET_FILENAME_COMPONENT(_absPotFile ${_potFile} ABSOLUTE)
# message(STATUS "1 all ${_addToAll} dest ${_installDest} args: ${_args}")
FOREACH (_lang ${_args})
SET(_poFile "${CMAKE_CURRENT_BINARY_DIR}/${_lang}.po")
SET(_gmoFile "${CMAKE_CURRENT_BINARY_DIR}/${_lang}.gmo")
ADD_CUSTOM_COMMAND(
OUTPUT "${_poFile}"
COMMAND ${GETTEXT_MSGMERGE_EXECUTABLE} --quiet --update
--backup=none -s ${_poFile} ${_absPotFile}
DEPENDS ${_absPotFile}
)
ADD_CUSTOM_COMMAND(
OUTPUT "${_gmoFile}"
COMMAND ${GETTEXT_MSGFMT_EXECUTABLE} -o ${_gmoFile} ${_poFile}
DEPENDS ${_absPotFile} ${_poFile}
)
IF(_installDest)
INSTALL(FILES ${_gmoFile} DESTINATION
${_installDest}/${_lang}/LC_MESSAGES RENAME ${_potBasename}.mo)
ENDIF(_installDest)
LIST(APPEND _gmoFiles ${_gmoFile})
ENDFOREACH (_lang )
ADD_CUSTOM_TARGET(potfile ${_addToAll} DEPENDS ${_gmoFiles})
ENDMACRO(GETTEXT_PROCESS_POT_FILE)
# GETTEXT_PROCESS_PO_FILES(<lang> [ALL] [INSTALL_DESTINATION <dir>]
<po1> <po2> ...)
MACRO(GETTEXT_PROCESS_PO_FILES _lang)
SET(_gmoFiles)
SET(_args ${ARGN})
SET(_addToAll)
SET(_installDest)
LIST(GET _args 0 _tmp)
IF("${_tmp}" STREQUAL "ALL")
SET(_addToAll ALL)
LIST(REMOVE_AT _args 0)
ENDIF("${_tmp}" STREQUAL "ALL")
LIST(GET _args 0 _tmp)
IF("${_tmp}" STREQUAL "INSTALL_DESTINATION")
LIST(GET _args 1 _installDest )
LIST(REMOVE_AT _args 0 1)
ENDIF("${_tmp}" STREQUAL "INSTALL_DESTINATION")
# message(STATUS "2 all ${_addToAll} dest ${_installDest} args: ${_args}")
FOREACH(_current_PO_FILE ${_args})
GET_FILENAME_COMPONENT(_basename ${_current_PO_FILE} NAME_WE)
SET(_gmoFile ${CMAKE_CURRENT_BINARY_DIR}/${_basename}.gmo)
add_custom_command(OUTPUT ${_gmoFile}
COMMAND ${GETTEXT_MSGFMT_EXECUTABLE} -o ${_gmoFile}
${_current_PO_FILE}
WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
DEPENDS ${_current_PO_FILE}
)
IF(_installDest)
INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${_basename}.gmo
DESTINATION ${_installDest}/${_lang}/LC_MESSAGES/ RENAME
${_basename}.mo)
ENDIF(_installDest)
LIST(APPEND _gmoFiles ${_gmoFile})
ENDFOREACH(_current_PO_FILE)
ADD_CUSTOM_TARGET(pofiles ${_addToAll} DEPENDS ${_gmoFiles})
ENDMACRO(GETTEXT_PROCESS_PO_FILES)
#IF (GETTEXT_MSGMERGE_EXECUTABLE AND GETTEXT_MSGFMT_EXECUTABLE )
# SET(GETTEXT_FOUND TRUE)
#ELSE (GETTEXT_MSGMERGE_EXECUTABLE AND GETTEXT_MSGFMT_EXECUTABLE )
# SET(GETTEXT_FOUND FALSE)
# IF (GetText_REQUIRED)
# MESSAGE(FATAL_ERROR "GetText not found")
# ENDIF (GetText_REQUIRED)
#ENDIF (GETTEXT_MSGMERGE_EXECUTABLE AND GETTEXT_MSGFMT_EXECUTABLE )
===================================================================
Do somebody knows what happened there ?
If hope this message is not too long, I'm not used to use mailing
lists so I do not know the habits.
Thank you,
Pierre M.
More information about the CMake
mailing list