[Buildroot] [PATCH 1/1] package/pkg-cmake.mk: allow cmake packages to have a configurable install prefix
Woody Douglass
wdouglass at carnegierobotics.com
Tue Aug 31 12:10:31 UTC 2021
That may be true, i'll experiment
Thanks,
Woody
On Mon, 2021-08-30 at 23:16 +0200, Thomas Petazzoni wrote:
> Hello Woody,
>
> On Mon, 30 Aug 2021 19:47:56 +0000
> Woody Douglass <wdouglass at carnegierobotics.com> wrote:
>
> > 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 at carnegierobotics.com>
>
> Can't you just pass:
>
> <pkg>_CONF_OPTS = -DCMAKE_INSTALL_PREFIX=/opt
>
> in your own package ?
>
> <pkg>_CONF_OPTS is used as follows:
>
> $$($$(PKG)_CONF_ENV) $$(BR2_CMAKE) $$($$(PKG)_SRCDIR) \
> -
> DCMAKE_TOOLCHAIN_FILE="$$(HOST_DIR)/share/buildroot/toolchainfile.cma
> ke" \
> -DCMAKE_INSTALL_PREFIX="/usr" \
> -DCMAKE_COLOR_MAKEFILE=OFF \
> -DBUILD_DOC=OFF \
> -DBUILD_DOCS=OFF \
> -DBUILD_EXAMPLE=OFF \
> -DBUILD_EXAMPLES=OFF \
> -DBUILD_TEST=OFF \
> -DBUILD_TESTS=OFF \
> -DBUILD_TESTING=OFF \
> -DBUILD_SHARED_LIBS=$$(if $$(BR2_STATIC_LIBS),OFF,ON)
> \
> $$(CMAKE_QUIET) \
> $$($$(PKG)_CONF_OPTS) \
>
> Since it appears *after* -DCMAKE_INSTALL_PREFIX="/usr" I assume your
> own -DCMAKE_INSTALL_PREFIX=/opt would take precedence.
>
> Best regards,
>
> Thomas
More information about the buildroot
mailing list