diff options
author | Tobias Burnus <tobias@codesourcery.com> | 2021-04-28 18:46:47 +0200 |
---|---|---|
committer | Tobias Burnus <tobias@codesourcery.com> | 2021-04-28 18:46:47 +0200 |
commit | fe5bfa6704179f8db7d1ae0b485439e9896df8eb (patch) | |
tree | 7687db287a1ef04b1399cf8db2a06eb9398cc995 /configure | |
parent | 3da80ed7efd582575e7850a403ce693ec882d087 (diff) | |
download | gcc-fe5bfa6704179f8db7d1ae0b485439e9896df8eb.zip gcc-fe5bfa6704179f8db7d1ae0b485439e9896df8eb.tar.gz gcc-fe5bfa6704179f8db7d1ae0b485439e9896df8eb.tar.bz2 |
offload-defaulted: Config option to silently ignore uninstalled offload compilers
If configured with --enable-offload-defaulted, configured but not installed
offload compilers and libgomp plugins are silently ignored. Useful for
distribution compilers where those are in separate optional packages.
2021-04-28 Jakub Jelinek <jakub@redhat.com>
Tobias Burnus <tobias@codesourcery.com>
ChangeLog:
* configure.ac (--enable-offload-defaulted): New.
* configure: Regenerate.
gcc/ChangeLog:
* configure.ac (OFFLOAD_DEFAULTED): AC_DEFINE if offload-defaulted.
* gcc.c (process_command): New variable.
(driver::maybe_putenv_OFFLOAD_TARGETS): If OFFLOAD_DEFAULTED,
set it if -foffload is defaulted.
* lto-wrapper.c (OFFLOAD_TARGET_DEFAULT_ENV): Define.
(compile_offload_image): If OFFLOAD_DEFAULTED and
OFFLOAD_TARGET_DEFAULT is in the environment, don't fail
if corresponding mkoffload can't be found.
(compile_images_for_offload_targets): Likewise. Free and clear
offload_names if no valid offload is found.
* config.in: Regenerate.
* configure: Regenerate.
libgomp/ChangeLog:
* configure.ac (OFFLOAD_DEFAULTED): AC_DEFINE if offload-defaulted.
* target.c (gomp_load_plugin_for_device): If set and if a plugin
can't be dlopened, silently assume it has no devices.
* Makefile.in: Regenerate.
* config.h.in: Regenerate.
* configure: Regenerate.
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -786,6 +786,7 @@ with_build_libsubdir with_system_zlib enable_as_accelerator_for enable_offload_targets +enable_offload_defaulted enable_gold enable_ld enable_compressed_debug_sections @@ -1515,6 +1516,11 @@ Optional Features: enable offloading to devices from comma-separated LIST of TARGET[=DIR]. Use optional path to find offload target compiler during the build + --enable-offload-defaulted + If enabled, configured but not installed offload compilers and + libgomp plugins are silently ignored. Useful for distribution + compilers where those are in separate optional packages. + --enable-gold[=ARG] build gold [ARG={default,yes,no}] --enable-ld[=ARG] build ld [ARG={default,yes,no}] --enable-compressed-debug-sections={all,gas,gold,ld,none} @@ -2981,6 +2987,14 @@ else fi +# Check whether --enable-offload-defaulted was given. +if test "${enable_offload_defaulted+set}" = set; then : + enableval=$enable_offload_defaulted; enable_offload_defaulted=$enableval +else + enable_offload_defaulted= +fi + + # Handle --enable-gold, --enable-ld. # --disable-gold [--enable-ld] # Build only ld. Default option. |