Commit graph

19 commits

Author SHA1 Message Date
Giulio Benetti 467552234d package/flann: re-enable package on microblaze
With Microblaze gcc version <= 9.x, the build of flannel fails due to
gcc bug 68485: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68485.

To avoid this, the flann package has a !BR2_microblaze
dependency. However, gcc bug 68485 only triggers when optimization is
enabled, so we can work around the issue by passing -O0, which is what
we do in other Buildroot packages to work around this bug.

So, this commit passes -O0 when BR2_TOOLCHAIN_HAS_GCC_BUG_68485, and
re-enables flann on Microblaze.

Note that the comment was talking about gcc bug 69401, but this gcc
bug is a duplicate of 68485. Since all Buildroot packages now use the
reference to gcc bug 68485 and the option is named
BR2_TOOLCHAIN_HAS_GCC_BUG_68485, we use this naming as well for flann.

Signed-off-by: Giulio Benetti <giulio.benetti@micronovasrl.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-06-19 21:52:58 +02:00
Ed Blake aea1a0e5a3 package: use BR2_TOOLCHAIN_HAS_OPENMP
Switch from using BR2_GCC_ENABLE_OPENMP to BR2_TOOLCHAIN_HAS_OPENMP to
determine OpenMP support in the following packages:

fftw
flann
opencv3

Signed-off-by: Ed Blake <ed.blake@sondrel.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-26 20:18:33 +01:00
Romain Naour 0c469478f6 package/flann: fix build with cmake >= 3.11
CMake < 3.11 doesn't support add_library() without any source file
(i.e add_library(foo SHARED)). But flann CMake use a trick that use
an empty string "" as source list (i.e add_library(foo SHARED "")).
This look like a bug in CMake < 3.11.

With CMake >= 3.11, the new behaviour of add_library() break the
existing flann CMake code.

>From CMake Changelog [1]:
"add_library() and add_executable() commands can now be called without
 any sources and will not complain as long as sources are added later
 via the target_sources() command."

Note: flann CMake code doesn't use target_sources() since no source file
are provided intentionally since the flann shared library is created by
linking with the flann_cpp_s static library with this line:

target_link_libraries(flann_cpp -Wl,-whole-archive flann_cpp_s -Wl,-no-whole-archive)

If you try to use "add_library(flann_cpp SHARED ${CPP_SOURCES})" (as it should
be normally done), the link fail due to already defined symbol.

They are building the shared version using the static library "to speedup the
build time" [3]

This issue is already reported upstream [2] with a proposed solution.

Fixes:
http://autobuild.buildroot.net/results/b2f/b2febfaf8c44ce477b3e4a5b9b976fd25e8d7454

[1] https://cmake.org/cmake/help/v3.11/release/3.11.html
[2] https://github.com/mariusmuja/flann/issues/369
[3] 0fd62b43be

Signed-off-by: Romain Naour <romain.naour@gmail.com>
Cc: Davide Viti <zinosat@tiscali.it>
Cc: Bernd Kuhls <bernd.kuhls@t-online.de>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-04-27 22:46:23 +02:00
Johan Oudinet f6ee339e92 flann: Disable find package for HDF5
The HDF5 package is used by flann for testing purpose only and is
not part of buildroot packages. However, if present in the host, it will
be used and trigger the unsafe header/library path used in
cross-compilation error.

Signed-off-by: Johan Oudinet <johan.oudinet@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2017-12-06 23:46:44 +01:00
Bernd Kuhls f6da4ce5fa package/flann: bump version to 1.9.1
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2017-05-28 16:13:40 +02:00
Rahul Bedarkar 9f59b378a3 boot, package: use SPDX short identifier for BSD-3c
We want to use SPDX identifier for license string as much as possible.
SPDX short identifier for BSD-3c is BSD-3-Clause.

This change is done using following command.
find . -name "*.mk" | xargs sed -ri '/LICENSE( )?[\+:]?=/s/BSD-3c/BSD-3-Clause/g'

Signed-off-by: Rahul Bedarkar <rahulbedarkar89@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2017-04-01 15:26:57 +02:00
Thomas Petazzoni 956924faa4 flann: disable on microblaze
All gcc versions fail to build flann on the Microblaze architecture, due
to gcc bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69401, so let's
disable this package on this architecture.

Fixes:

  http://autobuild.buildroot.net/results/3f44a1f30a88dbe4a3a83055267b472b58769e15/

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2016-05-24 17:39:43 +02:00
Thomas Petazzoni ce5f50fdd8 flann: add hash file
flann is fetched from Github, so we can add a hash file for this
package.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2016-05-24 17:39:38 +02:00
Thomas Petazzoni cfed4be8ae flann: bump version to fix build with gcc 6
The current version of flann in Buildroot fails to build with gcc 6.x,
with the following failure:

  error: call of overloaded 'abs(flann::KDTreeIndex<flann::L2<float> >::ElementType)' is ambiguous

By bumping the upstream version one commit further, we get an upstream
fix that fixes the build problem.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2016-05-24 17:39:34 +02:00
Romain Naour c785b1b2c4 toolchain-external: CodeSourcery NIOSII: support only one version
See the conclusion about external toolchains during the Buildroot
meeting [1]:
"In the future, we stick to a single external toolchain version. The
Kconfig symbol should not encode the version (avoid legacy handling)"

[1] http://elinux.org/index.php?title=Buildroot:DeveloperDaysELCE2015#Report

Signed-off-by: Romain Naour <romain.naour@openwide.fr>
Reviewed-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Tested-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2015-12-18 22:57:16 +01:00
Thomas Petazzoni 665e13c85e Rename BR2_PREFER_STATIC_LIB to BR2_STATIC_LIBS
Since a while, the semantic of BR2_PREFER_STATIC_LIB has been changed
from "prefer static libraries when possible" to "use only static
libraries". The former semantic didn't make much sense, since the user
had absolutely no control/idea of which package would use static
libraries, and which packages would not. Therefore, for quite some
time, we have been starting to enforce that BR2_PREFER_STATIC_LIB
should really build everything with static libraries.

As a consequence, this patch renames BR2_PREFER_STATIC_LIB to
BR2_STATIC_LIBS, and adjust the Config.in option accordingly.

This also helps preparing the addition of other options to select
shared, shared+static or just static.

Note that we have verified that this commit can be reproduced by
simply doing a global rename of BR2_PREFER_STATIC_LIB to
BR2_STATIC_LIBS plus adding BR2_PREFER_STATIC_LIB to Config.in.legacy.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
2014-12-11 22:48:13 +01:00
Maxime Hadjinlian 6eda7df7a1 flann: bump version
Signed-off-by: Maxime Hadjinlian <maxime.hadjinlian@gmail.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2014-10-27 01:13:19 +01:00
Samuel Martin 0dc4f5e769 package/flann: cleanup configure options
Disabling doc and test build is already done by the cmake-package
infrastructure.

Signed-off-by: Samuel Martin <s.martin49@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2014-10-26 17:03:13 +01:00
Thomas De Schampheleire aaffd209fa packages: rename FOO_CONF_OPT into FOO_CONF_OPTS
To be consistent with the recent change of FOO_MAKE_OPT into FOO_MAKE_OPTS,
make the same change for FOO_CONF_OPT.

Sed command used:
   find * -type f | xargs sed -i 's#_CONF_OPT\>#&S#g'

Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2014-10-04 18:54:16 +02:00
Thomas Petazzoni b9cc00e8bf flann: disable with the problematic NIOS II toolchain
Fixes:

  http://autobuild.buildroot.org/results/062/0620bf8d60aa57949cede0c5b3920ef5446fe98b/

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2014-06-11 12:53:41 +02:00
Samuel Martin 844209c8d6 flann: do not override CMAKE_BUILD_TYPE
This flag is already correctly set by the cmake-package infrastructure.

Signed-off-by: Samuel Martin <s.martin49@gmail.com>
Reviewed-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2014-06-01 22:20:29 +02:00
Thomas Petazzoni 190b4e12b7 flann: disallow static library build
Even though flann build system uses CMake, it always tries to build a
shared library, even if BUILD_SHARED_LIBS=OFF is passed. It could
probably be fixed in flann's CMakeLists.txt, but that's not really
worth the effort if upstream doesn't support it.

Therefore, we simply disallow the flann package in purely static
builds.

Fixes:

  http://autobuild.buildroot.org/results/a4e/a4ec0e9f28cd12ce770718fb407bbb4dc93b528b/

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2014-05-13 23:44:36 +02:00
Thomas De Schampheleire 9f8399c32a package .mk files: use 80 # signs in header
Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2014-05-01 22:32:37 +02:00
Davide Viti 5fefbceeb6 flann: new package
[Thomas: changed license from BSD to BSD-3c, to be more specific.]

Signed-off-by: Davide Viti <zinosat@tiscali.it>
CC: minimod@morethan.org
CC: patrickdepinguin@gmail.com
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2014-04-15 23:14:00 +02:00