package/rapidjson: switch to CMake
authorBernd Kuhls <bernd.kuhls@t-online.de>
Thu, 20 Apr 2017 23:05:32 +0000 (01:05 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Tue, 2 May 2017 20:51:59 +0000 (22:51 +0200)
Upcoming Kodi v18 depends on RapidJSON and detects it by using pkg-conf:
https://github.com/xbmc/xbmc/blob/master/cmake/modules/FindRapidJSON.cmake#L13

Currently our package installs only the header files, but RapidJSON.pc
is also needed. Luckily this can be fixed by switching to CMake which
does the job, also add configure options to disable the CMake build of
executables.

Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/rapidjson/rapidjson.mk

index d06f52962e60b0688afd9bc20e496f177cf75e33..4d69bc3450eec7b53136e90c25cfa9f6d3110c56 100644 (file)
@@ -13,8 +13,9 @@ RAPIDJSON_LICENSE_FILES = license.txt
 RAPIDJSON_INSTALL_TARGET = NO
 RAPIDJSON_INSTALL_STAGING = YES
 
-define RAPIDJSON_INSTALL_STAGING_CMDS
-       cp -dpfr $(@D)/include/* $(STAGING_DIR)/usr/include
-endef
+RAPIDJSON_CONF_OPTS = \
+       -DRAPIDJSON_BUILD_DOC=OFF \
+       -DRAPIDJSON_BUILD_EXAMPLES=OFF \
+       -DRAPIDJSON_BUILD_TESTS=OFF
 
-$(eval $(generic-package))
+$(eval $(cmake-package))