feat(package/poco): build package with cmake instead of make
PATCH 1/1 feat(package/poco): build package with cmake instead of make
Currently when building with make, the cmake config files are not generated. This leads to problems when integrating the package in an application built with cmake.
--- package/poco/poco.mk | 88 ++++++++++++++------------------------------ 1 file changed, 27 insertions(+), 61 deletions(-)
package/poco/poco.mk +27 -61
@@ -9,7 +9,6 @@ POCO_SITE = $(call github,pocoproject,poco,poco-$(POCO_VERSION)-release) POCO_LICENSE = BSL-1.0 POCO_LICENSE_FILES = LICENSE POCO_CPE_ID_VENDOR = pocoproject -POCO_INSTALL_STAGING = YES POCO_DEPENDENCIES = \ pcre2 \
@@ -22,78 +21,45 @@ POCO_DEPENDENCIES = \ $(if $(BR2_PACKAGE_POCO_NETSSL_OPENSSL),openssl) \ $(if $(BR2_PACKAGE_POCO_XML),expat) -POCO_OMIT = \ - Data/ODBC \ - PageCompiler \ - $(if $(BR2_PACKAGE_POCO_ACTIVERECORD),,ActiveRecord) \ - $(if $(BR2_PACKAGE_POCO_CPP_PARSER),,CppParser) \ - $(if $(BR2_PACKAGE_POCO_CRYPTO),,Crypto) \ - $(if $(BR2_PACKAGE_POCO_DATA),,Data) \ - $(if $(BR2_PACKAGE_POCO_DATA_MYSQL),,Data/MySQL) \ - $(if $(BR2_PACKAGE_POCO_DATA_SQLITE),,Data/SQLite) \ - $(if $(BR2_PACKAGE_POCO_DATA_PGSQL),,Data/PostgreSQL) \ - $(if $(BR2_PACKAGE_POCO_JSON),,JSON) \ - $(if $(BR2_PACKAGE_POCO_JWT),,JWT) \ - $(if $(BR2_PACKAGE_POCO_MONGODB),,MongoDB) \ - $(if $(BR2_PACKAGE_POCO_NET),,Net) \ - $(if $(BR2_PACKAGE_POCO_NETSSL_OPENSSL),,NetSSL_OpenSSL) \ - $(if $(BR2_PACKAGE_POCO_PDF),,PDF) \ - $(if $(BR2_PACKAGE_POCO_PROMETHEUS),,Prometheus) \ - $(if $(BR2_PACKAGE_POCO_REDIS),,Redis) \ - $(if $(BR2_PACKAGE_POCO_UTIL),,Util) \ - $(if $(BR2_PACKAGE_POCO_XML),,XML) \ - $(if $(BR2_PACKAGE_POCO_ZIP),,Zip) +POCO_CONF_OPTS = \ + -DENABLE_DATA_OBDC=OFF \ + -DENABLE_PAGECOMPILER=OFF \ + -DENABLE_ACTIVERECORD=$(if $(BR2_PACKAGE_POCO_ACTIVERECORD),ON,OFF) \ + -DENABLE_CPPPARSER=$(if $(BR2_PACKAGE_POCO_CPP_PARSER),ON,OFF) \ + -DENABLE_CRYPTO=$(if $(BR2_PACKAGE_POCO_CRYPTO),ON,OFF) \ + -DENABLE_DATA=$(if $(BR2_PACKAGE_POCO_DATA),ON,OFF) \ + -DENABLE_DATA_MYSQL=$(if $(BR2_PACKAGE_POCO_DATA_MYSQL),ON,OFF) \ + -DENABLE_DATA_SQLITE=$(if $(BR2_PACKAGE_POCO_DATA_SQLITE),ON,OFF) \ + -DENABLE_DATA_POSTGRESQL=$(if $(BR2_PACKAGE_POCO_DATA_PGSQL),ON,OFF) \ + -DENABLE_JSON=$(if $(BR2_PACKAGE_POCO_JSON),ON,OFF) \ + -DENABLE_JWT=$(if $(BR2_PACKAGE_POCO_JWT),ON,OFF) \ + -DENABLE_MONGODB=$(if $(BR2_PACKAGE_POCO_MONGODB),ON,OFF) \ + -DENABLE_NET=$(if $(BR2_PACKAGE_POCO_NET),ON,OFF) \ + -DENABLE_NETSSL=$(if $(BR2_PACKAGE_POCO_NETSSL_OPENSSL),ON,OFF) \ + -DENABLE_PDF=$(if $(BR2_PACKAGE_POCO_PDF),ON,OFF) \ + -DENABLE_PROMETHEUS=$(if $(BR2_PACKAGE_POCO_PROMETHEUS),ON,OFF) \ + -DENABLE_REDIS=$(if $(BR2_PACKAGE_POCO_REDIS),ON,OFF) \ + -DENABLE_UTIL=$(if $(BR2_PACKAGE_POCO_UTIL),ON,OFF) \ + -DENABLE_XML=$(if $(BR2_PACKAGE_POCO_XML),ON,OFF) \ + -DENABLE_ZIP=$(if $(BR2_PACKAGE_POCO_ZIP),ON,OFF) \ + -DPOCO_UNBUNDLED=ON ifeq ($(BR2_TOOLCHAIN_USES_UCLIBC),y) -POCO_CONF_OPTS += --no-fpenvironment --no-wstring +POCO_CONF_OPTS += -DPOCO_NO_FPENVIRONMENT -DPOCO_NO_WSTRING endif # architectures missing some FE_* in their fenv.h ifeq ($(BR2_sh4a),y) -POCO_CONF_OPTS += --no-fpenvironment +POCO_CONF_OPTS += -DPOCO_NO_FPENVIRONMENT endif # disable fpenvironment for soft floating point configuration ifeq ($(BR2_SOFT_FLOAT),y) -POCO_CONF_OPTS += --no-fpenvironment +POCO_CONF_OPTS += -DPOCO_NO_FPENVIRONMENT endif -POCO_MAKE_TARGET = shared_release - -POCO_LDFLAGS=$(TARGET_LDFLAGS) ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y) -POCO_LDFLAGS += -latomic +POCO_CONF_OPTS += -DCMAKE_EXE_LINKER_FLAGS=-latomic endif -define POCO_CONFIGURE_CMDS - (cd $(@D); $(TARGET_MAKE_ENV) ./configure \ - --config=Linux \ - --prefix=/usr \ - --ldflags="$(POCO_LDFLAGS)" \ - --omit="$(POCO_OMIT)" \ - $(POCO_CONF_OPTS) \ - --unbundled \ - --no-tests \ - --no-samples) -endef - -define POCO_BUILD_CMDS - $(TARGET_MAKE_ENV) $(MAKE) POCO_TARGET_OSARCH=$(ARCH) CROSS_COMPILE=$(TARGET_CROSS) \ - POCO_MYSQL_INCLUDE=$(STAGING_DIR)/usr/include/mysql \ - POCO_MYSQL_LIB=$(STAGING_DIR)/usr/lib/mysql \ - POCO_PGSQL_INCLUDE=$(STAGING_DIR)/usr/include/postgresql \ - POCO_PGSQL_LIB=$(STAGING_DIR)/usr/lib/postgresql \ - DEFAULT_TARGET=$(POCO_MAKE_TARGET) -C $(@D) -endef - -define POCO_INSTALL_STAGING_CMDS - $(TARGET_MAKE_ENV) $(MAKE) DESTDIR=$(STAGING_DIR) POCO_TARGET_OSARCH=$(ARCH) \ - DEFAULT_TARGET=$(POCO_MAKE_TARGET) install -C $(@D) -endef - -define POCO_INSTALL_TARGET_CMDS - $(TARGET_MAKE_ENV) $(MAKE) DESTDIR=$(TARGET_DIR) POCO_TARGET_OSARCH=$(ARCH) \ - DEFAULT_TARGET=$(POCO_MAKE_TARGET) install -C $(@D) -endef - -$(eval $(generic-package)) +$(eval $(cmake-package))
Signature · 6 lines
2.53.0 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Hi Stefan,
I was about to apply, but there's a problem.
Quoted 3 lines · Stefan via buildroot
Currently when building with make, the cmake config files are not generated. This leads to problems when integrating the package in an application built with cmake.
We need your Signed-off-by here, with the same name and e-mail address as the
Author of the commit. This shows that you claim that you either hold the copyright to this changeset or have the right to license it, and that you license it under Buildroot's GPLv2. [1]
Also, the title line of the commit should start with package/poco: without feat().
package/poco/poco.mk POCO_SITE = $(call github,pocoproject,poco,poco-$(POCO_VERSION)-release) · line 12
Quoted 13 lines
--- package/poco/poco.mk | 88 ++++++++++++++------------------------------ 1 file changed, 27 insertions(+), 61 deletions(-)package/poco/poco.mk +0
-1@@ -9,7 +9,6 @@ POCO_SITE = $(call github,pocoproject,poco,poco-$(POCO_VERSION)-release) POCO_LICENSE = BSL-1.0 POCO_LICENSE_FILES = LICENSE POCO_CPE_ID_VENDOR = pocoproject -POCO_INSTALL_STAGING = YES
I don't think this is supposed to have been removed?
Otherwise the changeset looks OK.
Unfortunately I cannot apply without your Signed-off-by, so I've marked the
patch as Changes Requested in patchwork.
Regards,
Arnout
[1] https://developercertificate.org/
[snip]
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot