Skip to content

Commit

Permalink
Fixed CMake files for 0.8 built on win32. Does not build wms, and pos…
Browse files Browse the repository at this point in the history
…tgres is not tested/does not work.

All qgis files are compiled into qgis_core.dll (raster, legend, composer, gui, core).
Resulting binary crashes, but runs in gdb. Beware!
Please see build instructions for trunk on win32, the same environment is used here.

git-svn-id: http://svn.osgeo.org/qgis/branches/Release-0_8_0@6506 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
homann committed Feb 3, 2007
1 parent b617659 commit 0fb3f48
Show file tree
Hide file tree
Showing 18 changed files with 450 additions and 456 deletions.
6 changes: 4 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -120,9 +120,11 @@ ENDIF (CMAKE_BUILD_TYPE MATCHES Debug)
IF (WIN32)

SET (QGIS_BIN_DIR ${CMAKE_INSTALL_PREFIX})
SET (QGIS_DATA_DIR ${CMAKE_INSTALL_PREFIX})
SET (QGIS_PLUGIN_DIR ${CMAKE_INSTALL_PREFIX}/plugins)
SET (QGIS_DATA_DIR ${CMAKE_INSTALL_PREFIX}/share/qgis)
SET (QGIS_PLUGIN_DIR ${CMAKE_INSTALL_PREFIX}/lib/qgis)

SET (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--enable-runtime-pseudo-reloc")
SET (CMAKE_MODULE_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--enable-runtime-pseudo-reloc")
ELSE (WIN32)

IF (APPLE)
Expand Down
199 changes: 194 additions & 5 deletions src/core/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,169 @@
SET(QGIS_GUI_SRCS
../gui/qgisapp.cpp
../gui/qgisiface.cpp
../gui/qgisinterface.cpp
../gui/qgsabout.cpp
../gui/qgsaddattrdialog.cpp
../gui/qgsattributeaction.cpp
../gui/qgsattributeactiondialog.cpp
../gui/qgsattributedialog.cpp
../gui/qgsattributetable.cpp
../gui/qgsattributetabledisplay.cpp
../gui/qgsbookmarks.cpp
../gui/qgsclipboard.cpp
../gui/qgscolorbutton.cpp
../gui/qgscontinuouscolordialog.cpp
../gui/qgscontinuouscolorrenderer.cpp
../gui/qgscoordinatetransform.cpp
../gui/qgscursors.cpp
../gui/qgscustomprojectiondialog.cpp
../gui/qgsdelattrdialog.cpp
../gui/qgsencodingfiledialog.cpp
../gui/qgsfillstylewidget.cpp
../gui/qgsgeomtypedialog.cpp
../gui/qgsgraduatedsymboldialog.cpp
../gui/qgsgraduatedsymbolrenderer.cpp
../gui/qgshelpviewer.cpp
../gui/qgsidentifyresults.cpp
../gui/qgslabel.cpp
../gui/qgslabeldialog.cpp
../gui/qgslayerprojectionselector.cpp
../gui/qgslinestyledialog.cpp
../gui/qgslinestylewidget.cpp
../gui/qgsludialog.cpp
../gui/qgsmapcanvas.cpp
../gui/qgsmapcanvasitem.cpp
../gui/qgsmapcanvasmap.cpp
../gui/qgsmaplayer.cpp
../gui/qgsmaplayerregistry.cpp
../gui/qgsmaplayerset.cpp
../gui/qgsmapoverviewcanvas.cpp
../gui/qgsmaprender.cpp
../gui/qgsmaptoolcapture.cpp
../gui/qgsmaptool.cpp
../gui/qgsmaptoolidentify.cpp
../gui/qgsmaptoolpan.cpp
../gui/qgsmaptoolselect.cpp
../gui/qgsmaptoolvertexedit.cpp
../gui/qgsmaptoolzoom.cpp
../gui/qgsmarkerdialog.cpp
../gui/qgsmeasure.cpp
../gui/qgsmessageviewer.cpp
../gui/qgsnewhttpconnection.cpp
../gui/qgsoptions.cpp
../gui/qgspastetransformations.cpp
../gui/qgspatterndialog.cpp
../gui/qgspgutil.cpp
../gui/qgspluginmanager.cpp
../gui/qgspointstylewidget.cpp
../gui/qgsproject.cpp
../gui/qgsprojectproperties.cpp
../gui/qgsrasterlayerproperties.cpp
../gui/qgsrubberband.cpp
../gui/qgsrunprocess.cpp
../gui/qgssearchquerybuilder.cpp
../gui/qgsserversourceselect.cpp
../gui/qgssinglesymboldialog.cpp
../gui/qgssinglesymbolrenderer.cpp
../gui/qgsspatialrefsys.cpp
../gui/qgsuniquevaluedialog.cpp
../gui/qgsuniquevaluerenderer.cpp
../gui/qgsvectorfilewriter.cpp
../gui/qgsvectorlayer.cpp
../gui/qgsvectorlayerproperties.cpp
../gui/qgsvertexmarker.cpp
../widgets/projectionselector/qgsprojectionselector.cpp

../composer/qgscomposer.cpp
../composer/qgscomposeritem.cpp
../composer/qgscomposerlabel.cpp
../composer/qgscomposermap.cpp
../composer/qgscomposerpicture.cpp
../composer/qgscomposerscalebar.cpp
../composer/qgscomposervectorlegend.cpp
../composer/qgscomposerview.cpp
../composer/qgscomposition.cpp

../legend/qgslegend.cpp
../legend/qgslegendgroup.cpp
../legend/qgslegenditem.cpp
../legend/qgslegendlayer.cpp
../legend/qgslegendlayerfile.cpp
../legend/qgslegendlayerfilegroup.cpp
../legend/qgslegendpropertygroup.cpp
../legend/qgslegendpropertyitem.cpp
../legend/qgslegendsymbologygroup.cpp
../legend/qgslegendsymbologyitem.cpp
../legend/qgslegendvectorsymbologyitem.cpp

../raster/qgsrasterlayer.cpp

)

SET(QGIS_GUI_MOC_HDRS
../gui/qgsnewhttpconnection.h
../gui/qgshelpviewer.h
../gui/qgsattributetable.h
../gui/qgssearchquerybuilder.h
../gui/qgsattributeactiondialog.h
../gui/qgslinestyledialog.h
../gui/qgsabout.h
../gui/qgsmaprender.h
../gui/qgsdelattrdialog.h
../gui/qgsmeasure.h
../gui/qgsgeomtypedialog.h
../gui/qgsgraduatedsymboldialog.h
../gui/qgscustomprojectiondialog.h
../gui/qgspastetransformations.h
../gui/qgscontinuouscolordialog.h
../gui/qgssinglesymboldialog.h
../gui/qgsbookmarks.h
../gui/qgsfillstylewidget.h
../gui/qgsmarkerdialog.h
../gui/qgsidentifyresults.h
../gui/qgsvectorlayerproperties.h
../gui/qgsserversourceselect.h
../gui/qgspluginmanager.h
../gui/qgspatterndialog.h
../gui/qgsaddattrdialog.h
../gui/qgsattributetabledisplay.h
../gui/qgsattributedialog.h
../gui/qgsoptions.h
../gui/qgsludialog.h
../gui/qgslinestylewidget.h
../gui/qgisapp.h
../gui/qgisiface.h
../gui/qgisinterface.h
../gui/qgscoordinatetransform.h
../gui/qgsencodingfiledialog.h
../gui/qgslabeldialog.h
../gui/qgslayerprojectionselector.h
../gui/qgsmapcanvas.h
../gui/qgsmapcanvasitem.h
../gui/qgsmapoverviewcanvas.h
../gui/qgsmaplayer.h
../gui/qgsmaplayerregistry.h
../gui/qgsmaptoolidentify.h
../gui/qgspointstylewidget.h
../widgets/projectionselector/qgsprojectionselector.h
../gui/qgsproject.h
../gui/qgsprojectproperties.h
../gui/qgsrasterlayerproperties.h
../gui/qgsrunprocess.h
../gui/qgsuniquevaluedialog.h
../gui/qgsvectorlayer.h
../legend/qgslegend.h
../composer/qgscomposermap.h
../composer/qgscomposerlabel.h
../composer/qgscomposer.h
../composer/qgscomposerpicture.h
../composer/qgscomposerscalebar.h
../composer/qgscomposervectorlegend.h
../composer/qgscomposerview.h
../composer/qgscomposition.h

../raster/qgsrasterlayer.h
)


#############################################################
Expand Down Expand Up @@ -31,6 +197,7 @@ qgsmarkersymbol.cpp
qgsnumericsortlistviewitem.cpp
qgspluginitem.cpp
qgspluginregistry.cpp
../gui/qgspluginmetadata.cpp
qgspoint.cpp
qgspolygonsymbol.cpp
qgsprojectproperty.cpp
Expand All @@ -50,7 +217,6 @@ qgssymbol.cpp
qgssymbologyutils.cpp
qgsvectordataprovider.cpp

../raster/qgsrasterlayer.cpp

)

Expand All @@ -64,12 +230,31 @@ qgsdataprovider.h
qgshttptransaction.h
qgsrasterdataprovider.h

../raster/qgsrasterlayer.h
)

IF (POSTGRES_FOUND)
SET (QGIS_GUI_SRCS ${QGIS_GUI_SRCS}
../gui/qgsdbsourceselect.cpp
../gui/qgsnewconnection.cpp
../gui/qgspgquerybuilder.cpp
)
SET (QGIS_GUI_MOC_HDRS ${QGIS_GUI_MOC_HDRS}
../gui/qgsdbsourceselect.h
../gui/qgsnewconnection.h
../gui/qgspgquerybuilder.h
)
ENDIF (POSTGRES_FOUND)

QT4_WRAP_CPP(QGIS_GUI_MOC_SRCS ${QGIS_GUI_MOC_HDRS})
QT4_WRAP_CPP(QGIS_CORE_MOC_SRCS ${QGIS_CORE_MOC_HDRS})

INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR} ../raster ../legend ../gui
INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}
../raster
../legend
../gui
../composer
../plugins
../widgets/projectionselector
${CMAKE_CURRENT_BINARY_DIR}
${CMAKE_CURRENT_BINARY_DIR}/../ui
${QT_QTSVG_INCLUDE_DIR}
Expand All @@ -90,10 +275,10 @@ ENDIF (WIN32)
#############################################################
# qgis_core library

ADD_LIBRARY(qgis_core SHARED ${QGIS_CORE_SRCS} ${QGIS_CORE_MOC_SRCS} ${INDEX_SRC})
ADD_LIBRARY(qgis_core SHARED ${QGIS_CORE_SRCS} ${QGIS_CORE_MOC_SRCS} ${QGIS_GUI_SRCS} ${QGIS_GUI_MOC_SRCS} ${INDEX_SRC})

# make sure to create qgssvnversion.h before compiling
ADD_DEPENDENCIES(qgis_core svnversionsounds ui)
ADD_DEPENDENCIES(qgis_core svnversion ui)

# because of htonl
IF (WIN32)
Expand All @@ -109,6 +294,10 @@ TARGET_LINK_LIBRARIES(qgis_core
${PLATFORM_LIBRARIES}
)

IF (POSTGRES_FOUND)
TARGET_LINK_LIBRARIES (qgis_core ${POSTGRES_LIBRARY})
ENDIF (POSTGRES_FOUND)

INSTALL(TARGETS qgis_core
RUNTIME DESTINATION ${QGIS_BIN_DIR}
LIBRARY DESTINATION lib)
1 change: 1 addition & 0 deletions src/core/qgspluginregistry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include <qlibrary.h>
#include <qapplication.h>
#include "qgsprovidermetadata.h"
#include "qgspluginmetadata.h"
#include "qgspluginregistry.h"

QgsPluginRegistry *QgsPluginRegistry::_instance = 0;
Expand Down
Loading

0 comments on commit 0fb3f48

Please sign in to comment.