[CMake] Errors in OSX platform and ubuntu of a Qt app

Leopold Palomo-Avellaneda lepalom at wol.es
Wed Dec 12 10:27:56 EST 2007


A Dimecres 12 Desembre 2007 16:00, Mike Jackson va escriure:
> Well, I _still_ don't have postgres SQL, but the following link error:
>
> Ui_CobroPagoBase::setupUi(QWidget*)
>
> leads me to believe that there is a missing include directory or link
> directory in the cmake file that somehow you are getting away with on
> Debian and not on OS X.

it's curious, why in debian works and not in OSX.

>
> ###########################################
> # Plugin for bulmacont					  #
> ###########################################
> #pluginregistrodeiva
>
> set (plugin pluginregistrodeiva)
>
> file(GLOB_RECURSE plugin_SRC *.c *.cpp *.cxx)
> file(GLOB_RECURSE plugin_MOCS *.hpp *.h)
> file(GLOB_RECURSE plugin_UIS *.ui)
>
> ####----> Note Changed order of following lines
> set(QT_USE_QTASSISTANT true)
> set(QT_USE_QTXML true)
> ###---> QT_USE_FILE needs the above variables set BEFORE calling the
> INCLUDE (...)
> INCLUDE(   ${QT_USE_FILE}   )
>

I understand that I _must_ change this lines, using the set BEFORE the  
INCLUDE(   ${QT_USE_FILE}   ) no?

[....]
>
> ### Not NEEDED.. QT_USE_FILE will add these for you
> #ADD_DEFINITIONS(${QT_DEFINITIONS})

OK

> ADD_DEFINITIONS(-DQT_SHARED)
> # build sources, moc'd sources, and rcc'd sources
>
> add_library(${plugin} SHARED ${plugin_SRC} ${plugin_MOC_SRCS}
> 	${plugin_UIS_H} ${plugin_SRCS} ${plugin_MOCS})
>
>
> set_target_properties( ${plugin} PROPERTIES
>    SOVERSION "${BULMAGES_VERSION_MAJOR}.${BULMAGES_VERSION_MINOR}"
>    VERSION "${BULMAGES_VERSION}")
>
> ## QT_LIBRARIES will include the following libraries so you do not
> have to specifically
> ##  list them in the target_link_libraries function
> # ${QT_QTGUI_LIBRARY}
> # ${QT_QTASSISTANT_LIBRARY}
>
> target_link_libraries(${plugin} bulmalib ${QT_LIBRARIES}   $
> {PGSQL_LIBRARIES})
> install_targets(/lib/bulmacont/plugins ${plugin})

ok.

three things: 
1) set before the QT_USE_FILE
2) not need to put QT_DEFINITIONS
3) only need to put QT_LIBRARIES


>
> I do not see anything else that jumps out at me. If you can tell me
> where to download the PostgreSQL for os x 10.4.11 Tiger (intel) I
> might have some time to try the build.

ok, question sent to the boy that is working with OSX.

Thanks, thanks, thanks,


Best regards,

Leo

PS I have a lot of files to change ..... :-(


More information about the CMake mailing list