All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/pkg-cmake.mk: allow cmake packages to have a configurable install prefix
@ 2021-08-30 19:47 Woody Douglass
  2021-08-30 21:16 ` Thomas Petazzoni
  0 siblings, 1 reply; 3+ messages in thread
From: Woody Douglass @ 2021-08-30 19:47 UTC (permalink / raw)
  To: buildroot; +Cc: s.martin49


I like to organize binaries on my system so that proprietary stuff
is put under the /opt tree. this patch allows for that.

Signed-off-by: Woodrow Douglass <wdouglass@carnegierobotics.com>
---
 package/pkg-cmake.mk | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/package/pkg-cmake.mk b/package/pkg-cmake.mk
index 4ee100a0c6..da57a4fe8d 100644
--- a/package/pkg-cmake.mk
+++ b/package/pkg-cmake.mk
@@ -56,6 +56,7 @@ $(2)_CONF_OPTS			?=
 $(2)_MAKE			?= $$(MAKE)
 $(2)_MAKE_ENV			?=
 $(2)_MAKE_OPTS			?=
+$(2)_CMAKE_INSTALL_PREFIX	?= "/usr"
 $(2)_INSTALL_OPTS		?= install
 $(2)_INSTALL_STAGING_OPTS	?= DESTDIR=$$(STAGING_DIR) install/fast
 $(2)_INSTALL_TARGET_OPTS	?= DESTDIR=$$(TARGET_DIR) install/fast
@@ -93,7 +94,7 @@ define $(2)_CONFIGURE_CMDS
 	PATH=$$(BR_PATH) \
 	$$($$(PKG)_CONF_ENV) $$(BR2_CMAKE) $$($$(PKG)_SRCDIR) \
 		-DCMAKE_TOOLCHAIN_FILE="$$(HOST_DIR)/share/buildroot/to
olchainfile.cmake" \
-		-DCMAKE_INSTALL_PREFIX="/usr" \
+		-DCMAKE_INSTALL_PREFIX=$$($$(PKG)_CMAKE_INSTALL_PREFIX)
\
 		-DCMAKE_COLOR_MAKEFILE=OFF \
 		-DBUILD_DOC=OFF \
 		-DBUILD_DOCS=OFF \
-- 
2.20.1
_______________________________________________
buildroot mailing list
buildroot@busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-08-31 12:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-30 19:47 [Buildroot] [PATCH 1/1] package/pkg-cmake.mk: allow cmake packages to have a configurable install prefix Woody Douglass
2021-08-30 21:16 ` Thomas Petazzoni
2021-08-31 12:10   ` Woody Douglass

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.