package/fftw: break fftw-quad into a dedicated package
fftw's library name depends on the precision option. Consequently, it's possible to install multiple flavor on the same target. This patch breaks fftw quad precision into a new package and: - makes BR2_PACKAGE_FFTW_PRECISION_QUAD select BR2_PACKAGE_FFTW_QUAD to keep compatibility with packages that use BR2_PACKAGE_FFTW_PRECISION_QUAD. This option will be removed in a follow-up commit; - makes fftw depend on fftw-quad when this package is enabled. Signed-off-by: Gwenhael Goavec-Merou <gwenhael.goavec-merou@trabucayre.com> [Yann/Thomas: - Force --disable-quad in FFTW_CONF_OPTS, just for the sake of clarity (fftw is no longer going to build the quad variant) - Use FFTW_QUAD_DL_SUBDIR to avoid downloading fftw multiple times - Minor reformatting tweaks in fftw-quad.mk - Do not deprecate BR2_PACKAGE_FFTW_PRECISION_QUAD and instead make it select BR2_PACKAGE_FFTW_QUAD, so that packages using BR2_PACKAGE_FFTW_PRECISION_QUAD continue to work.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> [Gwenhael/Yann]: - (BR2_i386 || BR2_x86_64) -> BR2_TOOLCHAIN_HAS_LIBQUADMATH Tested-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
This commit is contained in:
parent
cab310b8fd
commit
3b261182e9
@ -49,6 +49,7 @@ config BR2_PACKAGE_FFTW_PRECISION_QUAD
|
||||
bool "quad"
|
||||
# quad-precision needs to have a gcc with libquadmath
|
||||
depends on (BR2_i386 || BR2_x86_64) && BR2_USE_WCHAR
|
||||
select BR2_PACKAGE_FFTW_QUAD
|
||||
help
|
||||
Compile fftw in quadruple precision, i.e. use '__float128' for
|
||||
floating point type.
|
||||
@ -57,6 +58,7 @@ endchoice
|
||||
|
||||
source "package/fftw/fftw-single/Config.in"
|
||||
source "package/fftw/fftw-long-double/Config.in"
|
||||
source "package/fftw/fftw-quad/Config.in"
|
||||
|
||||
config BR2_PACKAGE_FFTW_FAST
|
||||
bool "optimise for speed over accuracy"
|
||||
|
7
package/fftw/fftw-quad/Config.in
Normal file
7
package/fftw/fftw-quad/Config.in
Normal file
@ -0,0 +1,7 @@
|
||||
config BR2_PACKAGE_FFTW_QUAD
|
||||
bool "fftw-quad"
|
||||
# quad-precision needs to have a gcc with libquadmath
|
||||
depends on BR2_TOOLCHAIN_HAS_LIBQUADMATH && BR2_USE_WCHAR
|
||||
help
|
||||
Compile fftw in quadruple precision, i.e. use '__float128' for
|
||||
floating point type.
|
1
package/fftw/fftw-quad/fftw-quad.hash
Symbolic link
1
package/fftw/fftw-quad/fftw-quad.hash
Symbolic link
@ -0,0 +1 @@
|
||||
../fftw.hash
|
22
package/fftw/fftw-quad/fftw-quad.mk
Normal file
22
package/fftw/fftw-quad/fftw-quad.mk
Normal file
@ -0,0 +1,22 @@
|
||||
################################################################################
|
||||
#
|
||||
# fftw-quad
|
||||
#
|
||||
################################################################################
|
||||
|
||||
FFTW_QUAD_VERSION = $(FFTW_VERSION)
|
||||
FFTW_QUAD_SOURCE = fftw-$(FFTW_VERSION).tar.gz
|
||||
FFTW_QUAD_SITE = $(FFTW_SITE)
|
||||
FFTW_QUAD_DL_SUBDIR = fftw
|
||||
FFTW_QUAD_INSTALL_STAGING = $(FFTW_INSTALL_STAGING)
|
||||
FFTW_QUAD_LICENSE = $(FFTW_LICENSE)
|
||||
FFTW_QUAD_LICENSE_FILES = $(FFTW_LICENSE_FILES)
|
||||
|
||||
FFTW_QUAD_CONF_ENV = $(FFTW_COMMON_CONF_ENV)
|
||||
|
||||
FFTW_QUAD_CONF_OPTS = \
|
||||
$(FFTW_COMMON_CONF_OPTS) \
|
||||
CFLAGS="$(FFTW_COMMON_CFLAGS)" \
|
||||
--enable-quad-precision
|
||||
|
||||
$(eval $(autotools-package))
|
@ -14,6 +14,10 @@ ifeq ($(BR2_PACKAGE_FFTW_LONG_DOUBLE),y)
|
||||
FFTW_DEPENDENCIES += fftw-long-double
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_FFTW_QUAD),y)
|
||||
FFTW_DEPENDENCIES += fftw-quad
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_FFTW_SINGLE),y)
|
||||
FFTW_DEPENDENCIES += fftw-single
|
||||
endif
|
||||
@ -49,7 +53,7 @@ FFTW_CONF_OPTS += \
|
||||
$(FFTW_COMMON_CONF_OPTS) \
|
||||
--disable-single \
|
||||
--disable-long-double \
|
||||
$(if $(BR2_PACKAGE_FFTW_PRECISION_QUAD),--enable,--disable)-quad-precision \
|
||||
--disable-quad-precision \
|
||||
CFLAGS="$(FFTW_COMMON_CFLAGS)"
|
||||
|
||||
$(eval $(autotools-package))
|
||||
|
Loading…
Reference in New Issue
Block a user