All of lore.kernel.org
 help / color / mirror / Atom feed
From: Yann E. MORIN <yann.morin.1998@free.fr>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 1/5] core/pkg-cmake: provide our own platform description
Date: Tue, 28 Feb 2017 21:03:13 +0100	[thread overview]
Message-ID: <20170228200313.GB3533@free.fr> (raw)
In-Reply-To: <20170228182631.yterrk7kcq2gjemt@tarshish>

Baruch, All,

On 2017-02-28 20:26 +0200, Baruch Siach spake thusly:
> On Tue, Feb 28, 2017 at 07:07:22PM +0100, Yann E. MORIN wrote:
> > diff --git a/package/pkg-cmake.mk b/package/pkg-cmake.mk
> > index a7c8dc3..77fa1dc 100644
> > --- a/package/pkg-cmake.mk
> > +++ b/package/pkg-cmake.mk
> > @@ -87,6 +87,7 @@ define $(2)_CONFIGURE_CMDS
> >  	PATH=$$(BR_PATH) \
> >  	$$($$(PKG)_CONF_ENV) $$(BR2_CMAKE) $$($$(PKG)_SRCDIR) \
> >  		-DCMAKE_TOOLCHAIN_FILE="$$(HOST_DIR)/usr/share/buildroot/toolchainfile.cmake" \
> > +		-DCMAKE_MODULE_PATH="$$(HOST_DIR)/usr/share/buildroot" \
> >  		-DCMAKE_INSTALL_PREFIX="/usr" \
> >  		-DCMAKE_COLOR_MAKEFILE=OFF \
> >  		-DBUILD_DOC=OFF \
> > @@ -249,3 +250,6 @@ $(HOST_DIR)/usr/share/buildroot/toolchainfile.cmake:
> >  		-e 's#@@CMAKE_BUILD_TYPE@@#$(if $(BR2_ENABLE_DEBUG),Debug,Release)#' \
> >  		$(TOPDIR)/support/misc/toolchainfile.cmake.in \
> >  		> $@
> > +
> > +$(HOST_DIR)/usr/share/buildroot/Platform/Buildroot.cmake:
> > +	$(Q)$(INSTALL) -D -m 0644 support/misc/Buildroot.cmake $(@)
> > diff --git a/support/misc/Buildroot.cmake b/support/misc/Buildroot.cmake
> > new file mode 100644
> > index 0000000..b0046b3
> > --- /dev/null
> > +++ b/support/misc/Buildroot.cmake
> > @@ -0,0 +1,3 @@
> > +include(Platform/Linux)
> 
> So this goes to the host directory in case of host installed cmake? What 
> happens when the host installed cmake is older than 3.1? Does the Buildroot 
> built module path override the host installed one?

When the host cmake is older than 3.1, we build and use our own cmake.

And the modules path we provide is looked for first, then cmake uses the
builtin one:
    https://cmake.org/cmake/help/v3.0/variable/CMAKE_MODULE_PATH.html

I should have written that in the commit log, indeed.

Regards,
Yann E. MORIN.

> baruch
> 
> > +set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB32_PATHS FALSE)
> > +set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS FALSE)
> > diff --git a/support/misc/toolchainfile.cmake.in b/support/misc/toolchainfile.cmake.in
> > index d4252dd..5a42644 100644
> > --- a/support/misc/toolchainfile.cmake.in
> > +++ b/support/misc/toolchainfile.cmake.in
> > @@ -10,7 +10,7 @@
> >  # RELOCATED_HOST_DIR variable.
> >  string(REPLACE "/usr/share/buildroot" "" RELOCATED_HOST_DIR ${CMAKE_CURRENT_LIST_DIR})
> >  
> > -set(CMAKE_SYSTEM_NAME Linux)
> > +set(CMAKE_SYSTEM_NAME Buildroot)
> >  set(CMAKE_SYSTEM_PROCESSOR @@CMAKE_SYSTEM_PROCESSOR@@)
> >  
> >  # Set the {C,CXX}FLAGS appended by CMake depending on the build type
> > diff --git a/toolchain/toolchain/toolchain.mk b/toolchain/toolchain/toolchain.mk
> > index b16db01..e298373 100644
> > --- a/toolchain/toolchain/toolchain.mk
> > +++ b/toolchain/toolchain/toolchain.mk
> > @@ -38,3 +38,4 @@ endif
> >  $(eval $(virtual-package))
> >  
> >  toolchain: $(HOST_DIR)/usr/share/buildroot/toolchainfile.cmake
> > +toolchain: $(HOST_DIR)/usr/share/buildroot/Platform/Buildroot.cmake
> 
> -- 
>      http://baruch.siach.name/blog/                  ~. .~   Tk Open Systems
> =}------------------------------------------------ooO--U--Ooo------------{=
>    - baruch at tkos.co.il - tel: +972.52.368.4656, http://www.tkos.co.il -

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'

  reply	other threads:[~2017-02-28 20:03 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-28 18:07 [Buildroot] [PATCH 0/5] package/cmake: re-introduce cmake-3.7 Yann E. MORIN
2017-02-28 18:07 ` [Buildroot] [PATCH 1/5] core/pkg-cmake: provide our own platform description Yann E. MORIN
2017-02-28 18:26   ` Baruch Siach
2017-02-28 20:03     ` Yann E. MORIN [this message]
2017-02-28 20:41   ` Jörg Krause
2017-02-28 20:58     ` Yann E. MORIN
2017-02-28 22:15       ` Jörg Krause
2017-03-01  8:01       ` Arnout Vandecappelle
2017-03-01  7:58   ` Arnout Vandecappelle
2017-03-01  8:17     ` Thomas Petazzoni
2017-03-01  8:35       ` Arnout Vandecappelle
2017-03-01 18:43         ` Yann E. MORIN
2017-03-05 23:27           ` Arnout Vandecappelle
2017-03-06 17:00             ` Yann E. MORIN
2017-03-06 22:02               ` Arnout Vandecappelle
2017-03-02 12:29   ` Baruch Siach
2017-03-02 12:41     ` Thomas Petazzoni
2017-02-28 18:07 ` [Buildroot] [PATCH 2/5] cmake: bump version to 3.7.0 Yann E. MORIN
2017-02-28 18:07 ` [Buildroot] [PATCH 3/5] cmake: bump version to 3.7.1 Yann E. MORIN
2017-02-28 18:07 ` [Buildroot] [PATCH 4/5] cmake: adjust dependencies added for libuv Yann E. MORIN
2017-02-28 18:07 ` [Buildroot] [PATCH 5/5] cmake: bump version to 3.7.2 Yann E. MORIN
2017-03-01  7:49 ` [Buildroot] [PATCH 0/5] package/cmake: re-introduce cmake-3.7 Arnout Vandecappelle
2017-03-01  7:59   ` Thomas Petazzoni
2017-03-01 21:14 ` Thomas Petazzoni
2017-03-02  8:41   ` Thomas Petazzoni
2017-03-02 17:39     ` Yann E. MORIN

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170228200313.GB3533@free.fr \
    --to=yann.morin.1998@free.fr \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.