ports/misc/copperspice-examples/files/patch-src_CMakeLists.txt
Adriaan de Groot 8de46b4745 x11-toolkits/copperspice: resurrect CopperSpice
CopperSpice is a toolkit, forked from Qt and updated to use
modern C++ and CMake in the Qt 5.something LGPL days. It was
removed from the tree for being unfetchable in 2017, now
restored. I didn't bother to look at the old ports files, so
this is entirely new work.

CS builds cleanly, except I patched in -pthread as a linker
option; I think this ought to be part of the Threads package
found by CMake, but it isn't (on FreeBSD at least). Some linkage
options need to be PUBLIC to be carried through to consuming
applications (this is a FreeBSD thing).

While here, introduce the misc/copperspice-examples which
is a demo application *kitchensink* that exercises the libraries.

CopperSpice shares notional-filenames with Qt (e.g. binaries
called "lupdate" for UI design) but the Qt ports are versioned
("lupdate-qt5"). CopperSpice gets "-cs" as a suffix.

There's a bunch of patching to make things "behave" like a
regularly packaged set of libraries and applications that
consume those libraries. In particular using $(LOCALBASE)/share/
rather than putting everything in the same target directory.
2022-02-20 16:45:27 +01:00

62 lines
2.2 KiB
Text

--- src/CMakeLists.txt.orig 2022-02-15 21:15:36 UTC
+++ src/CMakeLists.txt
@@ -182,25 +182,26 @@ endif()
if (CMAKE_SYSTEM_NAME MATCHES "Darwin")
install(TARGETS KitchenSink DESTINATION ../MacOS)
else()
- install(TARGETS KitchenSink DESTINATION .)
+ install(TARGETS KitchenSink)
endif()
-install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/../resources/script.js DESTINATION ./resources)
-install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/../resources/sampleMenu.xml DESTINATION ./resources)
+set(install_resource_dir ${CMAKE_INSTALL_DATADIR}/copperspice/kitchensink/resources)
+# install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/../resources/script.js DESTINATION ${install_resource_dir})
+# install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/../resources/sampleMenu.xml DESTINATION ${install_resource_dir})
# installs the CopperSpice libraries
-cs_copy_library(CsCore)
-cs_copy_library(CsGui)
-cs_copy_library(CsNetwork)
-cs_copy_library(CsOpenGL)
-cs_copy_library(CsScript)
-cs_copy_library(CsSql)
-cs_copy_library(CsSvg)
-cs_copy_library(CsXml)
-cs_copy_library(CsXmlPatterns)
+# cs_copy_library(CsCore)
+# cs_copy_library(CsGui)
+# cs_copy_library(CsNetwork)
+# cs_copy_library(CsOpenGL)
+# cs_copy_library(CsScript)
+# cs_copy_library(CsSql)
+# cs_copy_library(CsSvg)
+# cs_copy_library(CsXml)
+# cs_copy_library(CsXmlPatterns)
if("Multimedia" IN_LIST COPPERSPICE_COMPONENTS)
- cs_copy_library(CsMultimedia)
+ # cs_copy_library(CsMultimedia)
endif()
if("WebKit" IN_LIST COPPERSPICE_COMPONENTS)
@@ -226,15 +227,15 @@ if (CMAKE_SYSTEM_NAME MATCHES "Darwin")
elseif(CMAKE_SYSTEM_NAME MATCHES "(Linux|OpenBSD|FreeBSD|NetBSD|DragonFly)")
# installs the platform Gui plugin
- cs_copy_plugins(CsGui)
- cs_copy_plugins(CsOpenGL)
+ # cs_copy_plugins(CsGui)
+ # cs_copy_plugins(CsOpenGL)
# three files
if("Multimedia" IN_LIST COPPERSPICE_COMPONENTS)
- cs_copy_plugins(CsMultimedia)
+ # cs_copy_plugins(CsMultimedia)
endif()
- install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/../resources/ks.png DESTINATION ./resources)
+ # install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/../resources/ks.png DESTINATION ${install_resource_dir})
elseif(CMAKE_SYSTEM_NAME MATCHES "Windows")