summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Pashev <pashev.igor@gmail.com>2017-05-13 14:26:13 +0300
committerIgor Pashev <pashev.igor@gmail.com>2017-05-13 14:26:13 +0300
commit5864e2e380fec584938f62b675d42fdec1a91e7d (patch)
tree7982a27459c0d3d822987fdc81bb6f7a0bdf9049
parent42156b5190f4fa150e1fab6777eb81e69d4db8c9 (diff)
downloadgcc-9-5864e2e380fec584938f62b675d42fdec1a91e7d.tar.gz
Add changes from Dyson gcc-5 (not tested at all)
-rw-r--r--debian/control.m44
-rw-r--r--debian/lib32gomp1.symbols.illumos-amd64275
-rw-r--r--debian/libgomp1.symbols.illumos-amd64275
-rw-r--r--debian/patches/illumos-boehm-gc.diff40
-rw-r--r--debian/patches/illumos-fclone-functions.diff80
-rw-r--r--debian/patches/illumos-libgcc-regs.diff25
-rw-r--r--debian/patches/illumos-libgo-lfstack.diff20
-rw-r--r--debian/patches/illumos-multiarch.diff15
-rw-r--r--debian/patches/illumos-pragma-align.diff46
-rw-r--r--debian/patches/illumos-spec.diff42
-rw-r--r--debian/patches/illumos-strict-calling-conventions.diff106
-rw-r--r--debian/patches/illumos-sysdep-unix.c.diff16
-rw-r--r--debian/patches/illumos-use_libgcj_bc.diff13
-rw-r--r--debian/rules.conf16
-rw-r--r--debian/rules.d/binary-libgcc.mk9
-rw-r--r--debian/rules.defs12
-rw-r--r--debian/rules.patch13
-rw-r--r--debian/rules224
-rw-r--r--debian/source/local-options1
19 files changed, 1013 insertions, 19 deletions
diff --git a/debian/control.m4 b/debian/control.m4
index a549ad3..27307e8 100644
--- a/debian/control.m4
+++ b/debian/control.m4
@@ -67,7 +67,7 @@ Build-Depends: DEBHELPER_BUILD_DEP DPKG_BUILD_DEP
autogen, zlib1g-dev, gawk, lzma, xz-utils, patchutils,
pkg-config, libgc-dev,
zlib1g-dev, SDT_BUILD_DEP
- bison (>= 1:2.3), flex, realpath (>= 1.9.12), lsb-release, quilt
+ bison (>= 1:2.3), flex, realpath, lsb-release, quilt
',`dnl native
Build-Depends: DEBHELPER_BUILD_DEP DPKG_BUILD_DEP
GCC_MULTILIB_BUILD_DEP
@@ -83,7 +83,7 @@ Build-Depends: DEBHELPER_BUILD_DEP DPKG_BUILD_DEP
texinfo (>= 4.3), locales, sharutils,
procps, FORTRAN_BUILD_DEP JAVA_BUILD_DEP GNAT_BUILD_DEP GO_BUILD_DEP GDC_BUILD_DEP
ISL_BUILD_DEP MPC_BUILD_DEP MPFR_BUILD_DEP GMP_BUILD_DEP PHOBOS_BUILD_DEP
- CHECK_BUILD_DEP realpath (>= 1.9.12), chrpath, lsb-release, quilt,
+ CHECK_BUILD_DEP realpath, chrpath, lsb-release, quilt,
pkg-config, libgc-dev,
TARGET_TOOL_BUILD_DEP
Build-Depends-Indep: LIBSTDCXX_BUILD_INDEP JAVA_BUILD_INDEP
diff --git a/debian/lib32gomp1.symbols.illumos-amd64 b/debian/lib32gomp1.symbols.illumos-amd64
new file mode 100644
index 0000000..7fb699b
--- /dev/null
+++ b/debian/lib32gomp1.symbols.illumos-amd64
@@ -0,0 +1,275 @@
+libgomp.so.1 lib32gomp1 #MINVER#
+ GOACC_2.0@GOACC_2.0 5
+ GOACC_data_end@GOACC_2.0 5
+ GOACC_data_start@GOACC_2.0 5
+ GOACC_enter_exit_data@GOACC_2.0 5
+ GOACC_get_num_threads@GOACC_2.0 5
+ GOACC_get_thread_num@GOACC_2.0 5
+ GOACC_parallel@GOACC_2.0 5
+ GOACC_update@GOACC_2.0 5
+ GOACC_wait@GOACC_2.0 5
+ GOMP_1.0@GOMP_1.0 4.2.1
+ GOMP_2.0@GOMP_2.0 4.4
+ GOMP_3.0@GOMP_3.0 4.7
+ GOMP_4.0.1@GOMP_4.0.1 5
+ GOMP_4.0@GOMP_4.0 4.9
+ GOMP_PLUGIN_1.0@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_acc_thread@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_async_unmap_vars@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_debug@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_error@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_fatal@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_malloc@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_malloc_cleared@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_realloc@GOMP_PLUGIN_1.0 5
+ GOMP_atomic_end@GOMP_1.0 4.2.1
+ GOMP_atomic_start@GOMP_1.0 4.2.1
+ GOMP_barrier@GOMP_1.0 4.2.1
+ GOMP_barrier_cancel@GOMP_4.0 4.9
+ GOMP_cancel@GOMP_4.0 4.9
+ GOMP_cancellation_point@GOMP_4.0 4.9
+ GOMP_critical_end@GOMP_1.0 4.2.1
+ GOMP_critical_name_end@GOMP_1.0 4.2.1
+ GOMP_critical_name_start@GOMP_1.0 4.2.1
+ GOMP_critical_start@GOMP_1.0 4.2.1
+ GOMP_loop_dynamic_next@GOMP_1.0 4.2.1
+ GOMP_loop_dynamic_start@GOMP_1.0 4.2.1
+ GOMP_loop_end@GOMP_1.0 4.2.1
+ GOMP_loop_end_cancel@GOMP_4.0 4.9
+ GOMP_loop_end_nowait@GOMP_1.0 4.2.1
+ GOMP_loop_guided_next@GOMP_1.0 4.2.1
+ GOMP_loop_guided_start@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_dynamic_next@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_dynamic_start@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_guided_next@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_guided_start@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_runtime_next@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_runtime_start@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_static_next@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_static_start@GOMP_1.0 4.2.1
+ GOMP_loop_runtime_next@GOMP_1.0 4.2.1
+ GOMP_loop_runtime_start@GOMP_1.0 4.2.1
+ GOMP_loop_static_next@GOMP_1.0 4.2.1
+ GOMP_loop_static_start@GOMP_1.0 4.2.1
+ GOMP_loop_ull_dynamic_next@GOMP_2.0 4.4
+ GOMP_loop_ull_dynamic_start@GOMP_2.0 4.4
+ GOMP_loop_ull_guided_next@GOMP_2.0 4.4
+ GOMP_loop_ull_guided_start@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_dynamic_next@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_dynamic_start@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_guided_next@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_guided_start@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_runtime_next@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_runtime_start@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_static_next@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_static_start@GOMP_2.0 4.4
+ GOMP_loop_ull_runtime_next@GOMP_2.0 4.4
+ GOMP_loop_ull_runtime_start@GOMP_2.0 4.4
+ GOMP_loop_ull_static_next@GOMP_2.0 4.4
+ GOMP_loop_ull_static_start@GOMP_2.0 4.4
+ GOMP_offload_register@GOMP_4.0.1 5
+ GOMP_offload_unregister@GOMP_4.0.1 5
+ GOMP_ordered_end@GOMP_1.0 4.2.1
+ GOMP_ordered_start@GOMP_1.0 4.2.1
+ GOMP_parallel@GOMP_4.0 4.9
+ GOMP_parallel_end@GOMP_1.0 4.2.1
+ GOMP_parallel_loop_dynamic@GOMP_4.0 4.9
+ GOMP_parallel_loop_dynamic_start@GOMP_1.0 4.2.1
+ GOMP_parallel_loop_guided@GOMP_4.0 4.9
+ GOMP_parallel_loop_guided_start@GOMP_1.0 4.2.1
+ GOMP_parallel_loop_runtime@GOMP_4.0 4.9
+ GOMP_parallel_loop_runtime_start@GOMP_1.0 4.2.1
+ GOMP_parallel_loop_static@GOMP_4.0 4.9
+ GOMP_parallel_loop_static_start@GOMP_1.0 4.2.1
+ GOMP_parallel_sections@GOMP_4.0 4.9
+ GOMP_parallel_sections_start@GOMP_1.0 4.2.1
+ GOMP_parallel_start@GOMP_1.0 4.2.1
+ GOMP_sections_end@GOMP_1.0 4.2.1
+ GOMP_sections_end_cancel@GOMP_4.0 4.9
+ GOMP_sections_end_nowait@GOMP_1.0 4.2.1
+ GOMP_sections_next@GOMP_1.0 4.2.1
+ GOMP_sections_start@GOMP_1.0 4.2.1
+ GOMP_single_copy_end@GOMP_1.0 4.2.1
+ GOMP_single_copy_start@GOMP_1.0 4.2.1
+ GOMP_single_start@GOMP_1.0 4.2.1
+ GOMP_target@GOMP_4.0 4.9
+ GOMP_target_data@GOMP_4.0 4.9
+ GOMP_target_end_data@GOMP_4.0 4.9
+ GOMP_target_update@GOMP_4.0 4.9
+ GOMP_task@GOMP_2.0 4.4
+ GOMP_taskgroup_end@GOMP_4.0 4.9
+ GOMP_taskgroup_start@GOMP_4.0 4.9
+ GOMP_taskwait@GOMP_2.0 4.4
+ GOMP_taskyield@GOMP_3.0 4.7
+ GOMP_teams@GOMP_4.0 4.9
+ OACC_2.0@OACC_2.0 5
+ OMP_1.0@OMP_1.0 4.2.1
+ OMP_2.0@OMP_2.0 4.2.1
+ OMP_3.0@OMP_3.0 4.4
+ OMP_3.1@OMP_3.1 4.7
+ OMP_4.0@OMP_4.0 4.9
+ acc_async_test@OACC_2.0 5
+ acc_async_test_all@OACC_2.0 5
+ acc_async_test_all_h_@OACC_2.0 5
+ acc_async_test_h_@OACC_2.0 5
+ acc_copyin@OACC_2.0 5
+ acc_copyin_32_h_@OACC_2.0 5
+ acc_copyin_64_h_@OACC_2.0 5
+ acc_copyin_array_h_@OACC_2.0 5
+ acc_copyout@OACC_2.0 5
+ acc_copyout_32_h_@OACC_2.0 5
+ acc_copyout_64_h_@OACC_2.0 5
+ acc_copyout_array_h_@OACC_2.0 5
+ acc_create@OACC_2.0 5
+ acc_create_32_h_@OACC_2.0 5
+ acc_create_64_h_@OACC_2.0 5
+ acc_create_array_h_@OACC_2.0 5
+ acc_delete@OACC_2.0 5
+ acc_delete_32_h_@OACC_2.0 5
+ acc_delete_64_h_@OACC_2.0 5
+ acc_delete_array_h_@OACC_2.0 5
+ acc_deviceptr@OACC_2.0 5
+ acc_free@OACC_2.0 5
+ acc_get_cuda_stream@OACC_2.0 5
+ acc_get_current_cuda_context@OACC_2.0 5
+ acc_get_current_cuda_device@OACC_2.0 5
+ acc_get_device_num@OACC_2.0 5
+ acc_get_device_num_h_@OACC_2.0 5
+ acc_get_device_type@OACC_2.0 5
+ acc_get_device_type_h_@OACC_2.0 5
+ acc_get_num_devices@OACC_2.0 5
+ acc_get_num_devices_h_@OACC_2.0 5
+ acc_hostptr@OACC_2.0 5
+ acc_init@OACC_2.0 5
+ acc_init_h_@OACC_2.0 5
+ acc_is_present@OACC_2.0 5
+ acc_is_present_32_h_@OACC_2.0 5
+ acc_is_present_64_h_@OACC_2.0 5
+ acc_is_present_array_h_@OACC_2.0 5
+ acc_malloc@OACC_2.0 5
+ acc_map_data@OACC_2.0 5
+ acc_memcpy_from_device@OACC_2.0 5
+ acc_memcpy_to_device@OACC_2.0 5
+ acc_on_device@OACC_2.0 5
+ acc_on_device_h_@OACC_2.0 5
+ acc_present_or_copyin@OACC_2.0 5
+ acc_present_or_copyin_32_h_@OACC_2.0 5
+ acc_present_or_copyin_64_h_@OACC_2.0 5
+ acc_present_or_copyin_array_h_@OACC_2.0 5
+ acc_present_or_create@OACC_2.0 5
+ acc_present_or_create_32_h_@OACC_2.0 5
+ acc_present_or_create_64_h_@OACC_2.0 5
+ acc_present_or_create_array_h_@OACC_2.0 5
+ acc_set_cuda_stream@OACC_2.0 5
+ acc_set_device_num@OACC_2.0 5
+ acc_set_device_num_h_@OACC_2.0 5
+ acc_set_device_type@OACC_2.0 5
+ acc_set_device_type_h_@OACC_2.0 5
+ acc_shutdown@OACC_2.0 5
+ acc_shutdown_h_@OACC_2.0 5
+ acc_unmap_data@OACC_2.0 5
+ acc_update_device@OACC_2.0 5
+ acc_update_device_32_h_@OACC_2.0 5
+ acc_update_device_64_h_@OACC_2.0 5
+ acc_update_device_array_h_@OACC_2.0 5
+ acc_update_self@OACC_2.0 5
+ acc_update_self_32_h_@OACC_2.0 5
+ acc_update_self_64_h_@OACC_2.0 5
+ acc_update_self_array_h_@OACC_2.0 5
+ acc_wait@OACC_2.0 5
+ acc_wait_all@OACC_2.0 5
+ acc_wait_all_async@OACC_2.0 5
+ acc_wait_all_async_h_@OACC_2.0 5
+ acc_wait_all_h_@OACC_2.0 5
+ acc_wait_async@OACC_2.0 5
+ acc_wait_async_h_@OACC_2.0 5
+ acc_wait_h_@OACC_2.0 5
+ omp_destroy_lock@OMP_3.0 4.4
+ omp_destroy_lock_@OMP_3.0 4.4
+ omp_destroy_nest_lock@OMP_3.0 4.4
+ omp_destroy_nest_lock_@OMP_3.0 4.4
+ omp_get_active_level@OMP_3.0 4.4
+ omp_get_active_level_@OMP_3.0 4.4
+ omp_get_ancestor_thread_num@OMP_3.0 4.4
+ omp_get_ancestor_thread_num_8_@OMP_3.0 4.4
+ omp_get_ancestor_thread_num_@OMP_3.0 4.4
+ omp_get_cancellation@OMP_4.0 4.9
+ omp_get_cancellation_@OMP_4.0 4.9
+ omp_get_default_device@OMP_4.0 4.9
+ omp_get_default_device_@OMP_4.0 4.9
+ omp_get_dynamic@OMP_1.0 4.2.1
+ omp_get_dynamic_@OMP_1.0 4.2.1
+ omp_get_level@OMP_3.0 4.4
+ omp_get_level_@OMP_3.0 4.4
+ omp_get_max_active_levels@OMP_3.0 4.4
+ omp_get_max_active_levels_@OMP_3.0 4.4
+ omp_get_max_threads@OMP_1.0 4.2.1
+ omp_get_max_threads_@OMP_1.0 4.2.1
+ omp_get_nested@OMP_1.0 4.2.1
+ omp_get_nested_@OMP_1.0 4.2.1
+ omp_get_num_devices@OMP_4.0 4.9
+ omp_get_num_devices_@OMP_4.0 4.9
+ omp_get_num_procs@OMP_1.0 4.2.1
+ omp_get_num_procs_@OMP_1.0 4.2.1
+ omp_get_num_teams@OMP_4.0 4.9
+ omp_get_num_teams_@OMP_4.0 4.9
+ omp_get_num_threads@OMP_1.0 4.2.1
+ omp_get_num_threads_@OMP_1.0 4.2.1
+ omp_get_proc_bind@OMP_4.0 4.9
+ omp_get_proc_bind_@OMP_4.0 4.9
+ omp_get_schedule@OMP_3.0 4.4
+ omp_get_schedule_8_@OMP_3.0 4.4
+ omp_get_schedule_@OMP_3.0 4.4
+ omp_get_team_num@OMP_4.0 4.9
+ omp_get_team_num_@OMP_4.0 4.9
+ omp_get_team_size@OMP_3.0 4.4
+ omp_get_team_size_8_@OMP_3.0 4.4
+ omp_get_team_size_@OMP_3.0 4.4
+ omp_get_thread_limit@OMP_3.0 4.4
+ omp_get_thread_limit_@OMP_3.0 4.4
+ omp_get_thread_num@OMP_1.0 4.2.1
+ omp_get_thread_num_@OMP_1.0 4.2.1
+ omp_get_wtick@OMP_2.0 4.2.1
+ omp_get_wtick_@OMP_2.0 4.2.1
+ omp_get_wtime@OMP_2.0 4.2.1
+ omp_get_wtime_@OMP_2.0 4.2.1
+ omp_in_final@OMP_3.1 4.7
+ omp_in_final_@OMP_3.1 4.7
+ omp_in_parallel@OMP_1.0 4.2.1
+ omp_in_parallel_@OMP_1.0 4.2.1
+ omp_init_lock@OMP_3.0 4.4
+ omp_init_lock_@OMP_3.0 4.4
+ omp_init_nest_lock@OMP_3.0 4.4
+ omp_init_nest_lock_@OMP_3.0 4.4
+ omp_is_initial_device@OMP_4.0 4.9
+ omp_is_initial_device_@OMP_4.0 4.9
+ omp_set_default_device@OMP_4.0 4.9
+ omp_set_default_device_8_@OMP_4.0 4.9
+ omp_set_default_device_@OMP_4.0 4.9
+ omp_set_dynamic@OMP_1.0 4.2.1
+ omp_set_dynamic_8_@OMP_1.0 4.2.1
+ omp_set_dynamic_@OMP_1.0 4.2.1
+ omp_set_lock@OMP_3.0 4.4
+ omp_set_lock_@OMP_3.0 4.4
+ omp_set_max_active_levels@OMP_3.0 4.4
+ omp_set_max_active_levels_8_@OMP_3.0 4.4
+ omp_set_max_active_levels_@OMP_3.0 4.4
+ omp_set_nest_lock@OMP_3.0 4.4
+ omp_set_nest_lock_@OMP_3.0 4.4
+ omp_set_nested@OMP_1.0 4.2.1
+ omp_set_nested_8_@OMP_1.0 4.2.1
+ omp_set_nested_@OMP_1.0 4.2.1
+ omp_set_num_threads@OMP_1.0 4.2.1
+ omp_set_num_threads_8_@OMP_1.0 4.2.1
+ omp_set_num_threads_@OMP_1.0 4.2.1
+ omp_set_schedule@OMP_3.0 4.4
+ omp_set_schedule_8_@OMP_3.0 4.4
+ omp_set_schedule_@OMP_3.0 4.4
+ omp_test_lock@OMP_3.0 4.4
+ omp_test_lock_@OMP_3.0 4.4
+ omp_test_nest_lock@OMP_3.0 4.4
+ omp_test_nest_lock_@OMP_3.0 4.4
+ omp_unset_lock@OMP_3.0 4.4
+ omp_unset_lock_@OMP_3.0 4.4
+ omp_unset_nest_lock@OMP_3.0 4.4
+ omp_unset_nest_lock_@OMP_3.0 4.4
diff --git a/debian/libgomp1.symbols.illumos-amd64 b/debian/libgomp1.symbols.illumos-amd64
new file mode 100644
index 0000000..2d7946d
--- /dev/null
+++ b/debian/libgomp1.symbols.illumos-amd64
@@ -0,0 +1,275 @@
+libgomp.so.1 libgomp1 #MINVER#
+ GOACC_2.0@GOACC_2.0 5
+ GOACC_data_end@GOACC_2.0 5
+ GOACC_data_start@GOACC_2.0 5
+ GOACC_enter_exit_data@GOACC_2.0 5
+ GOACC_get_num_threads@GOACC_2.0 5
+ GOACC_get_thread_num@GOACC_2.0 5
+ GOACC_parallel@GOACC_2.0 5
+ GOACC_update@GOACC_2.0 5
+ GOACC_wait@GOACC_2.0 5
+ GOMP_1.0@GOMP_1.0 4.2.1
+ GOMP_2.0@GOMP_2.0 4.4
+ GOMP_3.0@GOMP_3.0 4.7
+ GOMP_4.0.1@GOMP_4.0.1 5
+ GOMP_4.0@GOMP_4.0 4.9
+ GOMP_PLUGIN_1.0@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_acc_thread@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_async_unmap_vars@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_debug@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_error@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_fatal@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_malloc@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_malloc_cleared@GOMP_PLUGIN_1.0 5
+ GOMP_PLUGIN_realloc@GOMP_PLUGIN_1.0 5
+ GOMP_atomic_end@GOMP_1.0 4.2.1
+ GOMP_atomic_start@GOMP_1.0 4.2.1
+ GOMP_barrier@GOMP_1.0 4.2.1
+ GOMP_barrier_cancel@GOMP_4.0 4.9
+ GOMP_cancel@GOMP_4.0 4.9
+ GOMP_cancellation_point@GOMP_4.0 4.9
+ GOMP_critical_end@GOMP_1.0 4.2.1
+ GOMP_critical_name_end@GOMP_1.0 4.2.1
+ GOMP_critical_name_start@GOMP_1.0 4.2.1
+ GOMP_critical_start@GOMP_1.0 4.2.1
+ GOMP_loop_dynamic_next@GOMP_1.0 4.2.1
+ GOMP_loop_dynamic_start@GOMP_1.0 4.2.1
+ GOMP_loop_end@GOMP_1.0 4.2.1
+ GOMP_loop_end_cancel@GOMP_4.0 4.9
+ GOMP_loop_end_nowait@GOMP_1.0 4.2.1
+ GOMP_loop_guided_next@GOMP_1.0 4.2.1
+ GOMP_loop_guided_start@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_dynamic_next@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_dynamic_start@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_guided_next@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_guided_start@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_runtime_next@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_runtime_start@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_static_next@GOMP_1.0 4.2.1
+ GOMP_loop_ordered_static_start@GOMP_1.0 4.2.1
+ GOMP_loop_runtime_next@GOMP_1.0 4.2.1
+ GOMP_loop_runtime_start@GOMP_1.0 4.2.1
+ GOMP_loop_static_next@GOMP_1.0 4.2.1
+ GOMP_loop_static_start@GOMP_1.0 4.2.1
+ GOMP_loop_ull_dynamic_next@GOMP_2.0 4.4
+ GOMP_loop_ull_dynamic_start@GOMP_2.0 4.4
+ GOMP_loop_ull_guided_next@GOMP_2.0 4.4
+ GOMP_loop_ull_guided_start@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_dynamic_next@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_dynamic_start@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_guided_next@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_guided_start@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_runtime_next@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_runtime_start@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_static_next@GOMP_2.0 4.4
+ GOMP_loop_ull_ordered_static_start@GOMP_2.0 4.4
+ GOMP_loop_ull_runtime_next@GOMP_2.0 4.4
+ GOMP_loop_ull_runtime_start@GOMP_2.0 4.4
+ GOMP_loop_ull_static_next@GOMP_2.0 4.4
+ GOMP_loop_ull_static_start@GOMP_2.0 4.4
+ GOMP_offload_register@GOMP_4.0.1 5
+ GOMP_offload_unregister@GOMP_4.0.1 5
+ GOMP_ordered_end@GOMP_1.0 4.2.1
+ GOMP_ordered_start@GOMP_1.0 4.2.1
+ GOMP_parallel@GOMP_4.0 4.9
+ GOMP_parallel_end@GOMP_1.0 4.2.1
+ GOMP_parallel_loop_dynamic@GOMP_4.0 4.9
+ GOMP_parallel_loop_dynamic_start@GOMP_1.0 4.2.1
+ GOMP_parallel_loop_guided@GOMP_4.0 4.9
+ GOMP_parallel_loop_guided_start@GOMP_1.0 4.2.1
+ GOMP_parallel_loop_runtime@GOMP_4.0 4.9
+ GOMP_parallel_loop_runtime_start@GOMP_1.0 4.2.1
+ GOMP_parallel_loop_static@GOMP_4.0 4.9
+ GOMP_parallel_loop_static_start@GOMP_1.0 4.2.1
+ GOMP_parallel_sections@GOMP_4.0 4.9
+ GOMP_parallel_sections_start@GOMP_1.0 4.2.1
+ GOMP_parallel_start@GOMP_1.0 4.2.1
+ GOMP_sections_end@GOMP_1.0 4.2.1
+ GOMP_sections_end_cancel@GOMP_4.0 4.9
+ GOMP_sections_end_nowait@GOMP_1.0 4.2.1
+ GOMP_sections_next@GOMP_1.0 4.2.1
+ GOMP_sections_start@GOMP_1.0 4.2.1
+ GOMP_single_copy_end@GOMP_1.0 4.2.1
+ GOMP_single_copy_start@GOMP_1.0 4.2.1
+ GOMP_single_start@GOMP_1.0 4.2.1
+ GOMP_target@GOMP_4.0 4.9
+ GOMP_target_data@GOMP_4.0 4.9
+ GOMP_target_end_data@GOMP_4.0 4.9
+ GOMP_target_update@GOMP_4.0 4.9
+ GOMP_task@GOMP_2.0 4.4
+ GOMP_taskgroup_end@GOMP_4.0 4.9
+ GOMP_taskgroup_start@GOMP_4.0 4.9
+ GOMP_taskwait@GOMP_2.0 4.4
+ GOMP_taskyield@GOMP_3.0 4.7
+ GOMP_teams@GOMP_4.0 4.9
+ OACC_2.0@OACC_2.0 5
+ OMP_1.0@OMP_1.0 4.2.1
+ OMP_2.0@OMP_2.0 4.2.1
+ OMP_3.0@OMP_3.0 4.4
+ OMP_3.1@OMP_3.1 4.7
+ OMP_4.0@OMP_4.0 4.9
+ acc_async_test@OACC_2.0 5
+ acc_async_test_all@OACC_2.0 5
+ acc_async_test_all_h_@OACC_2.0 5
+ acc_async_test_h_@OACC_2.0 5
+ acc_copyin@OACC_2.0 5
+ acc_copyin_32_h_@OACC_2.0 5
+ acc_copyin_64_h_@OACC_2.0 5
+ acc_copyin_array_h_@OACC_2.0 5
+ acc_copyout@OACC_2.0 5
+ acc_copyout_32_h_@OACC_2.0 5
+ acc_copyout_64_h_@OACC_2.0 5
+ acc_copyout_array_h_@OACC_2.0 5
+ acc_create@OACC_2.0 5
+ acc_create_32_h_@OACC_2.0 5
+ acc_create_64_h_@OACC_2.0 5
+ acc_create_array_h_@OACC_2.0 5
+ acc_delete@OACC_2.0 5
+ acc_delete_32_h_@OACC_2.0 5
+ acc_delete_64_h_@OACC_2.0 5
+ acc_delete_array_h_@OACC_2.0 5
+ acc_deviceptr@OACC_2.0 5
+ acc_free@OACC_2.0 5
+ acc_get_cuda_stream@OACC_2.0 5
+ acc_get_current_cuda_context@OACC_2.0 5
+ acc_get_current_cuda_device@OACC_2.0 5
+ acc_get_device_num@OACC_2.0 5
+ acc_get_device_num_h_@OACC_2.0 5
+ acc_get_device_type@OACC_2.0 5
+ acc_get_device_type_h_@OACC_2.0 5
+ acc_get_num_devices@OACC_2.0 5
+ acc_get_num_devices_h_@OACC_2.0 5
+ acc_hostptr@OACC_2.0 5
+ acc_init@OACC_2.0 5
+ acc_init_h_@OACC_2.0 5
+ acc_is_present@OACC_2.0 5
+ acc_is_present_32_h_@OACC_2.0 5
+ acc_is_present_64_h_@OACC_2.0 5
+ acc_is_present_array_h_@OACC_2.0 5
+ acc_malloc@OACC_2.0 5
+ acc_map_data@OACC_2.0 5
+ acc_memcpy_from_device@OACC_2.0 5
+ acc_memcpy_to_device@OACC_2.0 5
+ acc_on_device@OACC_2.0 5
+ acc_on_device_h_@OACC_2.0 5
+ acc_present_or_copyin@OACC_2.0 5
+ acc_present_or_copyin_32_h_@OACC_2.0 5
+ acc_present_or_copyin_64_h_@OACC_2.0 5
+ acc_present_or_copyin_array_h_@OACC_2.0 5
+ acc_present_or_create@OACC_2.0 5
+ acc_present_or_create_32_h_@OACC_2.0 5
+ acc_present_or_create_64_h_@OACC_2.0 5
+ acc_present_or_create_array_h_@OACC_2.0 5
+ acc_set_cuda_stream@OACC_2.0 5
+ acc_set_device_num@OACC_2.0 5
+ acc_set_device_num_h_@OACC_2.0 5
+ acc_set_device_type@OACC_2.0 5
+ acc_set_device_type_h_@OACC_2.0 5
+ acc_shutdown@OACC_2.0 5
+ acc_shutdown_h_@OACC_2.0 5
+ acc_unmap_data@OACC_2.0 5
+ acc_update_device@OACC_2.0 5
+ acc_update_device_32_h_@OACC_2.0 5
+ acc_update_device_64_h_@OACC_2.0 5
+ acc_update_device_array_h_@OACC_2.0 5
+ acc_update_self@OACC_2.0 5
+ acc_update_self_32_h_@OACC_2.0 5
+ acc_update_self_64_h_@OACC_2.0 5
+ acc_update_self_array_h_@OACC_2.0 5
+ acc_wait@OACC_2.0 5
+ acc_wait_all@OACC_2.0 5
+ acc_wait_all_async@OACC_2.0 5
+ acc_wait_all_async_h_@OACC_2.0 5
+ acc_wait_all_h_@OACC_2.0 5
+ acc_wait_async@OACC_2.0 5
+ acc_wait_async_h_@OACC_2.0 5
+ acc_wait_h_@OACC_2.0 5
+ omp_destroy_lock@OMP_3.0 4.4
+ omp_destroy_lock_@OMP_3.0 4.4
+ omp_destroy_nest_lock@OMP_3.0 4.4
+ omp_destroy_nest_lock_@OMP_3.0 4.4
+ omp_get_active_level@OMP_3.0 4.4
+ omp_get_active_level_@OMP_3.0 4.4
+ omp_get_ancestor_thread_num@OMP_3.0 4.4
+ omp_get_ancestor_thread_num_8_@OMP_3.0 4.4
+ omp_get_ancestor_thread_num_@OMP_3.0 4.4
+ omp_get_cancellation@OMP_4.0 4.9
+ omp_get_cancellation_@OMP_4.0 4.9
+ omp_get_default_device@OMP_4.0 4.9
+ omp_get_default_device_@OMP_4.0 4.9
+ omp_get_dynamic@OMP_1.0 4.2.1
+ omp_get_dynamic_@OMP_1.0 4.2.1
+ omp_get_level@OMP_3.0 4.4
+ omp_get_level_@OMP_3.0 4.4
+ omp_get_max_active_levels@OMP_3.0 4.4
+ omp_get_max_active_levels_@OMP_3.0 4.4
+ omp_get_max_threads@OMP_1.0 4.2.1
+ omp_get_max_threads_@OMP_1.0 4.2.1
+ omp_get_nested@OMP_1.0 4.2.1
+ omp_get_nested_@OMP_1.0 4.2.1
+ omp_get_num_devices@OMP_4.0 4.9
+ omp_get_num_devices_@OMP_4.0 4.9
+ omp_get_num_procs@OMP_1.0 4.2.1
+ omp_get_num_procs_@OMP_1.0 4.2.1
+ omp_get_num_teams@OMP_4.0 4.9
+ omp_get_num_teams_@OMP_4.0 4.9
+ omp_get_num_threads@OMP_1.0 4.2.1
+ omp_get_num_threads_@OMP_1.0 4.2.1
+ omp_get_proc_bind@OMP_4.0 4.9
+ omp_get_proc_bind_@OMP_4.0 4.9
+ omp_get_schedule@OMP_3.0 4.4
+ omp_get_schedule_8_@OMP_3.0 4.4
+ omp_get_schedule_@OMP_3.0 4.4
+ omp_get_team_num@OMP_4.0 4.9
+ omp_get_team_num_@OMP_4.0 4.9
+ omp_get_team_size@OMP_3.0 4.4
+ omp_get_team_size_8_@OMP_3.0 4.4
+ omp_get_team_size_@OMP_3.0 4.4
+ omp_get_thread_limit@OMP_3.0 4.4
+ omp_get_thread_limit_@OMP_3.0 4.4
+ omp_get_thread_num@OMP_1.0 4.2.1
+ omp_get_thread_num_@OMP_1.0 4.2.1
+ omp_get_wtick@OMP_2.0 4.2.1
+ omp_get_wtick_@OMP_2.0 4.2.1
+ omp_get_wtime@OMP_2.0 4.2.1
+ omp_get_wtime_@OMP_2.0 4.2.1
+ omp_in_final@OMP_3.1 4.7
+ omp_in_final_@OMP_3.1 4.7
+ omp_in_parallel@OMP_1.0 4.2.1
+ omp_in_parallel_@OMP_1.0 4.2.1
+ omp_init_lock@OMP_3.0 4.4
+ omp_init_lock_@OMP_3.0 4.4
+ omp_init_nest_lock@OMP_3.0 4.4
+ omp_init_nest_lock_@OMP_3.0 4.4
+ omp_is_initial_device@OMP_4.0 4.9
+ omp_is_initial_device_@OMP_4.0 4.9
+ omp_set_default_device@OMP_4.0 4.9
+ omp_set_default_device_8_@OMP_4.0 4.9
+ omp_set_default_device_@OMP_4.0 4.9
+ omp_set_dynamic@OMP_1.0 4.2.1
+ omp_set_dynamic_8_@OMP_1.0 4.2.1
+ omp_set_dynamic_@OMP_1.0 4.2.1
+ omp_set_lock@OMP_3.0 4.4
+ omp_set_lock_@OMP_3.0 4.4
+ omp_set_max_active_levels@OMP_3.0 4.4
+ omp_set_max_active_levels_8_@OMP_3.0 4.4
+ omp_set_max_active_levels_@OMP_3.0 4.4
+ omp_set_nest_lock@OMP_3.0 4.4
+ omp_set_nest_lock_@OMP_3.0 4.4
+ omp_set_nested@OMP_1.0 4.2.1
+ omp_set_nested_8_@OMP_1.0 4.2.1
+ omp_set_nested_@OMP_1.0 4.2.1
+ omp_set_num_threads@OMP_1.0 4.2.1
+ omp_set_num_threads_8_@OMP_1.0 4.2.1
+ omp_set_num_threads_@OMP_1.0 4.2.1
+ omp_set_schedule@OMP_3.0 4.4
+ omp_set_schedule_8_@OMP_3.0 4.4
+ omp_set_schedule_@OMP_3.0 4.4
+ omp_test_lock@OMP_3.0 4.4
+ omp_test_lock_@OMP_3.0 4.4
+ omp_test_nest_lock@OMP_3.0 4.4
+ omp_test_nest_lock_@OMP_3.0 4.4
+ omp_unset_lock@OMP_3.0 4.4
+ omp_unset_lock_@OMP_3.0 4.4
+ omp_unset_nest_lock@OMP_3.0 4.4
+ omp_unset_nest_lock_@OMP_3.0 4.4
diff --git a/debian/patches/illumos-boehm-gc.diff b/debian/patches/illumos-boehm-gc.diff
new file mode 100644
index 0000000..e8ec1f5
--- /dev/null
+++ b/debian/patches/illumos-boehm-gc.diff
@@ -0,0 +1,40 @@
+Description: changes to libgcj.ver fix crashes of programs using boehm-gc.
+ Defining SOLARIS_STACKBOTTOM makes use of a native way to get stack bottom
+ (with thr_stksegment())
+Index: gcc-49/src/boehm-gc/include/private/gcconfig.h
+===================================================================
+--- gcc-49.orig/src/boehm-gc/include/private/gcconfig.h
++++ gcc-49/src/boehm-gc/include/private/gcconfig.h
+@@ -2114,7 +2114,7 @@
+ /* HEURISTIC2 probably works, but this appears to be preferable. */
+ /* # include <sys/vm.h> */
+ /* # define STACKBOTTOM USRSTACK */
+-# define HEURISTIC2
++# define SOLARIS_STACKBOTTOM
+ # define PROC_VDB
+ # define DYNAMIC_LOADING
+ # if !defined(USE_MMAP) && defined(REDIRECT_MALLOC)
+Index: gcc-49/src/libjava/libgcj.ver
+===================================================================
+--- gcc-49.orig/src/libjava/libgcj.ver
++++ gcc-49/src/libjava/libgcj.ver
+@@ -9,6 +9,19 @@
+ __gcj_personality_sj0;
+ __gcj_personality_seh0;
+ _Z*;
++
++# https://sourceware.org/ml/binutils/2010-02/msg00457.html
++# Otherwise boehm-gc cannot determine memory borders
++# and Java executables randomly crash
++# GNU ld add these symbols by default, but not in case
++# when version script is specified.
++ _GLOBAL_OFFSET_TABLE_;
++ _etext;
++ _DYNAMIC;
++ _edata;
++ _end;
++ _PROCEDURE_LINKAGE_TABLE_;
++
+ local:
+ *;
+ };
diff --git a/debian/patches/illumos-fclone-functions.diff b/debian/patches/illumos-fclone-functions.diff
new file mode 100644
index 0000000..9a60ff1
--- /dev/null
+++ b/debian/patches/illumos-fclone-functions.diff
@@ -0,0 +1,80 @@
+From 30f4861499309bd81f1d59b41b1091fef0152680 Mon Sep 17 00:00:00 2001
+From: Richard Lowe <richlowe@richlowe.net>
+Date: Sun, 30 Sep 2012 16:44:14 -0400
+Subject: [PATCH] allow the global disabling of function cloning
+
+Optimizations which clone functions to create call-specific implementations
+which may be better optimized also dissociate these functions from their
+symbol names in ways harmful to tracing and debugging (since there are now
+several implementations of a single source symbol, quite possibly none of them
+having the actual source symbol name).
+
+This allows any function cloning to be disabled, and makes any such
+optimization ineffective, and our source safe for debuggers everywhere.
+
+See http://wiki.illumos.org/display/illumos/GCC+Modifications
+---
+ gcc/common.opt | 5 +++++
+ gcc/doc/invoke.texi | 11 ++++++++++-
+ gcc/tree-inline.c | 3 ++-
+ 3 files changed, 17 insertions(+), 2 deletions(-)
+
+Index: gcc-5/src/gcc/common.opt
+===================================================================
+--- gcc-5.orig/src/gcc/common.opt
++++ gcc-5/src/gcc/common.opt
+@@ -981,6 +981,11 @@ fcheck-new
+ Common Var(flag_check_new)
+ Check the return value of new in C++
+
++fclone-functions
++Common Report Var(flag_clone_functions) Init(1)
++Allow the compiler to clone functions to facilitate certain optimizations.
++Enabled by default.
++
+ fcombine-stack-adjustments
+ Common Report Var(flag_combine_stack_adjustments) Optimization
+ Looks for opportunities to reduce stack adjustments and stack references.
+Index: gcc-5/src/gcc/doc/invoke.texi
+===================================================================
+--- gcc-5.orig/src/gcc/doc/invoke.texi
++++ gcc-5/src/gcc/doc/invoke.texi
+@@ -383,7 +383,7 @@ Objective-C and Objective-C++ Dialects}.
+ -fbranch-target-load-optimize -fbranch-target-load-optimize2 @gol
+ -fbtr-bb-exclusive -fcaller-saves @gol
+ -fcheck-data-deps -fcombine-stack-adjustments -fconserve-stack @gol
+--fcompare-elim -fcprop-registers -fcrossjumping @gol
++-fcompare-elim -fclone-functions -fcprop-registers -fcrossjumping @gol
+ -fcse-follow-jumps -fcse-skip-blocks -fcx-fortran-rules @gol
+ -fcx-limited-range @gol
+ -fdata-sections -fdce -fdelayed-branch @gol
+@@ -9516,6 +9516,15 @@ to these tools. With non fat LTO makefil
+ The default is @option{-fno-fat-lto-objects} on targets with linker plugin
+ support.
+
++@item -fno-clone-functions
++@opindex fno-clone-functions
++Forbid the implicit cloning of functions implicit in certain
++optimizations. This also effectively will disable any optimization
++which wishes to clone functions, equivalent to each function having
++the ``noclone'' attribute. This allows the prevention of the
++dissociation of a piece of text from an intelligible and expected
++symbol name, which may hamper debugging and tracing.
++
+ @item -fcompare-elim
+ @opindex fcompare-elim
+ After register allocation and post-register allocation instruction splitting,
+Index: gcc-5/src/gcc/tree-inline.c
+===================================================================
+--- gcc-5.orig/src/gcc/tree-inline.c
++++ gcc-5/src/gcc/tree-inline.c
+@@ -5457,7 +5457,8 @@ bool
+ tree_versionable_function_p (tree fndecl)
+ {
+ return (!lookup_attribute ("noclone", DECL_ATTRIBUTES (fndecl))
+- && copy_forbidden (DECL_STRUCT_FUNCTION (fndecl), fndecl) == NULL);
++ && (copy_forbidden (DECL_STRUCT_FUNCTION (fndecl), fndecl) == NULL)
++ && flag_clone_functions);
+ }
+
+ /* Delete all unreachable basic blocks and update callgraph.
diff --git a/debian/patches/illumos-libgcc-regs.diff b/debian/patches/illumos-libgcc-regs.diff
new file mode 100644
index 0000000..eddda0f
--- /dev/null
+++ b/debian/patches/illumos-libgcc-regs.diff
@@ -0,0 +1,25 @@
+Index: gcc-5/src/libgcc/config/i386/sol2-unwind.h
+===================================================================
+--- gcc-5.orig/src/libgcc/config/i386/sol2-unwind.h
++++ gcc-5/src/libgcc/config/i386/sol2-unwind.h
+@@ -28,6 +28,20 @@ see the files COPYING3 and COPYING.RUNTI
+ #include <ucontext.h>
+ #include <sys/frame.h>
+
++/* /usr/include/sys/regset.h */
++#ifndef EAX
++# define UESP 17
++# define EIP 14
++# define EAX 11
++# define ECX 10
++# define EDX 9
++# define EBX 8
++# define ESP 7
++# define EBP 6
++# define ESI 5
++# define EDI 4
++#endif
++
+ #ifdef __x86_64__
+
+ #define MD_FALLBACK_FRAME_STATE_FOR x86_64_fallback_frame_state
diff --git a/debian/patches/illumos-libgo-lfstack.diff b/debian/patches/illumos-libgo-lfstack.diff
new file mode 100644
index 0000000..e0fc2d4
--- /dev/null
+++ b/debian/patches/illumos-libgo-lfstack.diff
@@ -0,0 +1,20 @@
+Index: gcc-5/src/libgo/runtime/lfstack.goc
+===================================================================
+--- gcc-5.orig/src/libgo/runtime/lfstack.goc
++++ gcc-5/src/libgo/runtime/lfstack.goc
+@@ -29,7 +29,6 @@ static inline LFNode* lfUnpack(uint64 va
+ // So we use 17msb of pointers as ABA counter.
+ # define PTR_BITS 47
+ # endif
+-# endif
+ # define CNT_BITS (64 - PTR_BITS + 3)
+ static inline uint64 lfPack(LFNode *node, uintptr cnt) {
+ return ((uint64)(node)<<(64-PTR_BITS)) | (cnt&(((1<<CNT_BITS)-1)));
+@@ -37,6 +36,7 @@ static inline uint64 lfPack(LFNode *node
+ static inline LFNode* lfUnpack(uint64 val) {
+ return (LFNode*)((val >> CNT_BITS) << 3);
+ }
++# endif /* __sparc__ ... */
+ #else
+ static inline uint64 lfPack(LFNode *node, uintptr cnt) {
+ return ((uint64)(uintptr)(node)<<32) | cnt;
diff --git a/debian/patches/illumos-multiarch.diff b/debian/patches/illumos-multiarch.diff
new file mode 100644
index 0000000..0456c25
--- /dev/null
+++ b/debian/patches/illumos-multiarch.diff
@@ -0,0 +1,15 @@
+Index: gcc-5/src/gcc/config/i386/t-sol2
+===================================================================
+--- gcc-5.orig/src/gcc/config/i386/t-sol2
++++ gcc-5/src/gcc/config/i386/t-sol2
+@@ -16,6 +16,7 @@
+ # along with GCC; see the file COPYING3. If not see
+ # <http://www.gnu.org/licenses/>.
+
+-MULTILIB_OPTIONS = m32/m64
+-MULTILIB_DIRNAMES = 32 amd64
+-MULTILIB_OSDIRNAMES = . amd64
++MULTILIB_OPTIONS = m64/m32
++MULTILIB_DIRNAMES = 64 32
++MULTILIB_OSDIRNAMES = m64=../lib$(call if_multiarch,:x86_64-illumos)
++MULTILIB_OSDIRNAMES+= m32=$(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)$(call if_multiarch,:i386-illumos)
diff --git a/debian/patches/illumos-pragma-align.diff b/debian/patches/illumos-pragma-align.diff
new file mode 100644
index 0000000..b8ca929
--- /dev/null
+++ b/debian/patches/illumos-pragma-align.diff
@@ -0,0 +1,46 @@
+Description: Allow #pragma align to be used after a variable is declared
+ GCC mandates that #pragma align precede any declaration, Sun C does not.
+ See http://wiki.illumos.org/display/illumos/GCC+Modifications
+
+Index: gcc-5/src/gcc/config/sol2-c.c
+===================================================================
+--- gcc-5.orig/src/gcc/config/sol2-c.c
++++ gcc-5/src/gcc/config/sol2-c.c
+@@ -125,8 +125,9 @@ solaris_pragma_align (cpp_reader *pfile
+ {
+ tree decl = identifier_global_value (t);
+ if (decl && DECL_P (decl))
+- warning (0, "%<#pragma align%> must appear before the declaration of "
+- "%D, ignoring", decl);
++ decl_attributes (&decl, build_tree_list (get_identifier ("aligned"),
++ build_tree_list (NULL, x)),
++ 0);
+ else
+ solaris_pending_aligns = tree_cons (t, build_tree_list (NULL, x),
+ solaris_pending_aligns);
+Index: gcc-5/src/gcc/testsuite/gcc.dg/pragma-align-2.c
+===================================================================
+--- gcc-5.orig/src/gcc/testsuite/gcc.dg/pragma-align-2.c
++++ gcc-5/src/gcc/testsuite/gcc.dg/pragma-align-2.c
+@@ -26,9 +26,9 @@ void abort (void);
+ #pragma align bad_align /* { dg-warning "malformed" } */
+ #pragma align 1(bad_align /* { dg-warning "malformed" } */
+
+-int x, x1, x2, x4, x8, y8, z8, x16, x32, x64, x128, y128, z128;
++int x1, x2, x4, x8, y8, z8, x16, y16, x32, x64, x128, y128, z128
+
+-#pragma align 16(x) /* { dg-warning "must appear before" } */
++#pragma align 16(y16)
+
+ int
+ main ()
+@@ -48,6 +48,9 @@ main ()
+ if (__alignof__ (x16) < 16)
+ abort ();
+
++ if (__alignof__ (y16) < 16)
++ abort ();
++
+ if (__alignof__ (x32) < 32)
+ abort ();
+
diff --git a/debian/patches/illumos-spec.diff b/debian/patches/illumos-spec.diff
new file mode 100644
index 0000000..7986940
--- /dev/null
+++ b/debian/patches/illumos-spec.diff
@@ -0,0 +1,42 @@
+Index: gcc-5/src/gcc/config/sol2.h
+===================================================================
+--- gcc-5.orig/src/gcc/config/sol2.h
++++ gcc-5/src/gcc/config/sol2.h
+@@ -142,12 +142,12 @@ along with GCC; see the file COPYING3.
+ #undef LIB_SPEC
+ #define LIB_SPEC \
+ "%{!symbolic:\
+- %{pthreads|pthread:-lpthread} \
+- %{p|pg:-ldl} -lc}"
++ %{pthreads|pthread:} \
++ %{p|pg:} -lc}"
+
+ #ifndef CROSS_DIRECTORY_STRUCTURE
+ #undef MD_EXEC_PREFIX
+-#define MD_EXEC_PREFIX "/usr/ccs/bin/"
++#define MD_EXEC_PREFIX "/usr/bin/"
+ #endif
+
+ #undef STARTFILE_ARCH_SPEC
+@@ -174,9 +174,7 @@ along with GCC; see the file COPYING3.
+ #define LINK_ARCH32_SPEC_BASE \
+ "%{G:-G} \
+ %{YP,*} \
+- %{R*} \
+- %{!YP,*:%{p|pg:-Y P,%R/usr/lib/libp%R/lib:%R/usr/lib} \
+- %{!p:%{!pg:-Y P,%R/lib:%R/usr/lib}}}"
++ %{R*}"
+
+ #undef LINK_ARCH32_SPEC
+ #define LINK_ARCH32_SPEC LINK_ARCH32_SPEC_BASE
+@@ -187,9 +185,7 @@ along with GCC; see the file COPYING3.
+ #define LINK_ARCH64_SPEC_BASE \
+ "%{G:-G} \
+ %{YP,*} \
+- %{R*} \
+- %{!YP,*:%{p|pg:-Y P,%R/usr/lib/libp/" ARCH64_SUBDIR ":%R/lib/" ARCH64_SUBDIR ":%R/usr/lib/" ARCH64_SUBDIR "} \
+- %{!p:%{!pg:-Y P,%R/lib/" ARCH64_SUBDIR ":%R/usr/lib/" ARCH64_SUBDIR "}}}"
++ %{R*}"
+
+ #undef LINK_ARCH64_SPEC
+ #ifndef USE_GLD
diff --git a/debian/patches/illumos-strict-calling-conventions.diff b/debian/patches/illumos-strict-calling-conventions.diff
new file mode 100644
index 0000000..8ddaa94
--- /dev/null
+++ b/debian/patches/illumos-strict-calling-conventions.diff
@@ -0,0 +1,106 @@
+From: Richard Lowe <richlowe@richlowe.net>
+Date: Sat, 27 Oct 2012 02:44:09 +0100
+Subject: [PATCH] Implement -fstrict-calling-conventions
+
+Stock GCC is overly willing to violate the ABI when calling local functions,
+such that it passes arguments in registers on i386. This hampers debugging
+with anything other than a fully-aware DWARF debugger, and is generally not
+something we desire.
+
+Implement a flag which disables this behaviour, enabled by default. The flag is
+global, though only effective on i386, to more easily allow its globalization
+later which, given the odds, is likely to be necessary.
+
+See http://wiki.illumos.org/display/illumos/GCC+Modifications
+
+Index: gcc-5/src/gcc/common.opt
+===================================================================
+--- gcc-5.orig/src/gcc/common.opt
++++ gcc-5/src/gcc/common.opt
+@@ -2136,6 +2136,10 @@ fstrict-aliasing
+ Common Report Var(flag_strict_aliasing) Optimization
+ Assume strict aliasing rules apply
+
++fstrict-calling-conventions
++Common Report Var(flag_strict_calling_conventions) Init(1)
++Use strict ABI calling conventions even for static functions
++
+ fstrict-overflow
+ Common Report Var(flag_strict_overflow) Optimization
+ Treat signed overflow as undefined
+Index: gcc-5/src/gcc/config/i386/i386.c
+===================================================================
+--- gcc-5.orig/src/gcc/config/i386/i386.c
++++ gcc-5/src/gcc/config/i386/i386.c
+@@ -5829,6 +5829,7 @@ ix86_function_regparm (const_tree type,
+
+ /* Use register calling convention for local functions when possible. */
+ if (decl
++ && (TARGET_64BIT || !flag_strict_calling_conventions)
+ && TREE_CODE (decl) == FUNCTION_DECL)
+ {
+ cgraph_node *target = cgraph_node::get (decl);
+@@ -5932,6 +5933,7 @@ ix86_function_sseregparm (const_tree typ
+ /* TARGET_SSE_MATH */
+ && (target_opts_for_fn (target->decl)->x_ix86_fpmath & FPMATH_SSE)
+ && opt_for_fn (target->decl, optimize)
++ && (TARGET_64BIT || !flag_strict_calling_conventions)
+ && !(profile_flag && !flag_fentry))
+ {
+ cgraph_local_info *i = &target->local;
+Index: gcc-5/src/gcc/doc/invoke.texi
+===================================================================
+--- gcc-5.orig/src/gcc/doc/invoke.texi
++++ gcc-5/src/gcc/doc/invoke.texi
+@@ -9082,6 +9082,12 @@ int f() @{
+ The @option{-fstrict-aliasing} option is enabled at levels
+ @option{-O2}, @option{-O3}, @option{-Os}.
+
++@item -fstrict-calling-conventions
++@opindex fstrict-calling-conventions
++Use strict ABI calling conventions even with local functions.
++This disable certain optimizations that may cause GCC to call local
++functions in a manner other than that described by the ABI.
++
+ @item -fstrict-overflow
+ @opindex fstrict-overflow
+ Allow the compiler to assume strict signed overflow rules, depending
+Index: gcc-5/src/gcc/testsuite/gcc.target/i386/local.c
+===================================================================
+--- gcc-5.orig/src/gcc/testsuite/gcc.target/i386/local.c
++++ gcc-5/src/gcc/testsuite/gcc.target/i386/local.c
+@@ -1,5 +1,6 @@
+ /* { dg-do compile } */
+-/* { dg-options "-O2 -funit-at-a-time" } */
++/* { dg-options "-O2 -funit-at-a-time -fno-strict-calling-conventions" { target ilp32 } } */
++/* { dg-options "-O2 -funit-at-a-time" { target lp64 } } */
+ /* { dg-final { scan-assembler "magic\[^\\n\]*eax" { target ia32 } } } */
+ /* { dg-final { scan-assembler "magic\[^\\n\]*(edi|ecx)" { target { ! { ia32 } } } } } */
+
+Index: gcc-5/src/gcc/testsuite/gcc.target/i386/strict-cc.c
+===================================================================
+--- /dev/null
++++ gcc-5/src/gcc/testsuite/gcc.target/i386/strict-cc.c
+@@ -0,0 +1,22 @@
++/* { dg-do compile { target { ilp32 } } } */
++/* { dg-options "-O2 -funit-at-a-time -fstrict-calling-conventions" } */
++/* { dg-final { scan-assembler "pushl.*\\\$1" } } */
++/* { dg-final { scan-assembler "pushl.*\\\$2" } } */
++/* { dg-final { scan-assembler "pushl.*\\\$3" } } */
++/* { dg-final { scan-assembler "pushl.*\\\$4" } } */
++/* { dg-final { scan-assembler "pushl.*\\\$5" } } */
++
++#include <stdio.h>
++
++/* Verify that local calling convention is not used if strict conventions. */
++static t(int, int, int, int, int) __attribute__ ((noinline));
++
++m()
++{
++ t(1, 2, 3, 4, 5);
++}
++
++static t(int a, int b, int c, int d, int e)
++{
++ printf("%d\n", a, b, c, d, e);
++}
diff --git a/debian/patches/illumos-sysdep-unix.c.diff b/debian/patches/illumos-sysdep-unix.c.diff
new file mode 100644
index 0000000..53506c9
--- /dev/null
+++ b/debian/patches/illumos-sysdep-unix.c.diff
@@ -0,0 +1,16 @@
+Index: gcc-5/src/libcilkrts/runtime/sysdep-unix.c
+===================================================================
+--- gcc-5.orig/src/libcilkrts/runtime/sysdep-unix.c
++++ gcc-5/src/libcilkrts/runtime/sysdep-unix.c
+@@ -46,6 +46,11 @@
+ # define _GNU_SOURCE
+ #endif
+
++#ifdef __sun__
++# define _GNU_SOURCE
++# define __EXTENSIONS__
++#endif
++
+ #include "sysdep.h"
+ #include "os.h"
+ #include "bug.h"
diff --git a/debian/patches/illumos-use_libgcj_bc.diff b/debian/patches/illumos-use_libgcj_bc.diff
new file mode 100644
index 0000000..a1878bd
--- /dev/null
+++ b/debian/patches/illumos-use_libgcj_bc.diff
@@ -0,0 +1,13 @@
+Index: gcc-5/src/libjava/configure.host
+===================================================================
+--- gcc-5.orig/src/libjava/configure.host
++++ gcc-5/src/libjava/configure.host
+@@ -413,7 +413,7 @@ case "${host}" in
+ esac
+
+ case "${host}" in
+- *linux*|*-kfreebsd*-gnu|*-gnu*)
++ *linux*|*-kfreebsd*-gnu|*-gnu*|*solaris*)
+ use_libgcj_bc=yes
+ ;;
+ *)
diff --git a/debian/rules.conf b/debian/rules.conf
index 923fe01..e4aff86 100644
--- a/debian/rules.conf
+++ b/debian/rules.conf
@@ -140,7 +140,7 @@ endef
base_deb_cpus := amd64 i386 alpha
base_deb_systems :=
$(foreach x,ada java java_plugin fortran libgphobos libgc check locale,$(eval $(call gen_no_archs,$(x),$(base_deb_cpus),$(base_deb_systems))))
-linux_no_archs := !hurd-any !kfreebsd-any
+linux_no_archs := !hurd-any !kfreebsd-any !illumos-any
GCC_VERSION := $(strip $(shell cat $(firstword $(wildcard $(srcdir)/gcc/FULL-VER $(srcdir)/gcc/BASE-VER))))
NEXT_GCC_VERSION := $(shell echo $(GCC_VERSION) | \
@@ -253,6 +253,12 @@ ifeq ($(with_multiarch_lib),yes)
else
libc_dev_ver := 2.13-0ubuntu6
endif
+ ifeq ($(DEB_TARGET_ARCH_OS),illumos)
+ LIBC_DEP = libc1
+ libc_ver := 4.3+17
+ libc_dev_ver := 4.3+17
+ libc_dev := 4.3+17
+ endif
endif
# first set LIBC_DEP/LIBC_DEV_DEP for native builds only
ifeq ($(DEB_TARGET_ARCH_OS),linux)
@@ -287,6 +293,7 @@ biarch_deb_map := \
sparc=sparc64 sparc64=sparc\
s390=s390x s390x=s390 \
kfreebsd-amd64=i386 \
+ illumos-amd64=illumos-i386 \
armel=armhf \
armhf=armel
biarch_deb_arch := $(patsubst $(DEB_TARGET_ARCH)=%,%, \
@@ -341,16 +348,18 @@ LIBC_DEP := $(LIBC_DEP)$(LS)$(AQ)
LIBC_DEV_DEP := $(LIBC_DEV_DEP)$(LS)$(AQ) (>= $(libc_dev_ver))
ifneq (,$(filter $(build_type), build-native cross-build-native))
- LIBC_DBG_DEP = libc6.1-dbg [alpha ia64] | libc0.3-dbg [hurd-i386] | libc0.1-dbg [kfreebsd-i386 kfreebsd-amd64] | libc6-dbg,
+ LIBC_DBG_DEP = libc6.1-dbg [alpha ia64] | libc0.3-dbg [hurd-i386] | libc0.1-dbg [kfreebsd-i386 kfreebsd-amd64] | libc6-dbg [!illumos-any],
endif
# TODO: make this automatic, there must be a better way to define LIBC_DEP.
ifneq ($(DEB_CROSS),yes)
LIBC_BUILD_DEP = libc6.1-dev (>= $(libc_dev_ver)) [alpha ia64] | libc0.3-dev (>= $(libc_dev_ver)) [hurd-i386] | libc0.1-dev (>= $(libc_dev_ver)) [kfreebsd-i386 kfreebsd-amd64] | libc6-dev (>= $(libc_dev_ver))
+ LIBC_BUILD_DEP += | libc1-dev (>= $(libc_dev_ver)) [illumos-amd64]
ifeq (,$(filter $(distrelease),lenny etch squeeze dapper hardy jaunty karmic lucid maverick natty oneiric))
LIBC_BUILD_DEP += , libc6-dev (>= 2.13-31) [armel armhf]
endif
LIBC_BIARCH_BUILD_DEP = libc6-dev-amd64 [i386 x32], libc6-dev-sparc64 [sparc], libc6-dev-sparc [sparc64], libc6-dev-s390 [s390x], libc6-dev-s390x [s390], libc6-dev-i386 [amd64 x32], libc6-dev-powerpc [ppc64], libc6-dev-ppc64 [powerpc], libc0.1-dev-i386 [kfreebsd-amd64], lib32gcc1 [amd64 ppc64 kfreebsd-amd64 mipsn32 mipsn32el mips64 mips64el s390x sparc64 x32], libn32gcc1 [mips mipsel mips64 mips64el], lib64gcc1 [i386 mips mipsel mipsn32 mipsn32el powerpc sparc s390 x32], libc6-dev-mips64 [mips mipsel mipsn32 mipsn32el], libc6-dev-mipsn32 [mips mipsel mips64 mips64el], libc6-dev-mips32 [mipsn32 mipsn32el mips64 mips64el],
+ LIBC_BIARCH_BUILD_DEP += libc1-dev-illumos-i386 (>= $(libc_dev_ver)) [illumos-amd64],
ifneq (,$(findstring amd64,$(biarchx32archs)))
LIBC_BIARCH_BUILD_DEP += libc6-dev-x32 [amd64 i386], libx32gcc1 [amd64 i386],
endif
@@ -839,6 +848,9 @@ ifeq ($(with_libgomp),yes)
addons += $(if $(findstring armel,$(biarchhfarchs)),libhfgomp)
addons += $(if $(findstring armhf,$(biarchsfarchs)),libsfgomp)
endif
+ifeq ($(with_ssp),yes)
+ addons += libssp lib32ssp lib64ssp
+endif
ifeq ($(with_libitm),yes)
addons += libitm lib32itm lib64itm libn32itm
addons += $(if $(findstring amd64,$(biarchx32archs)),libx32itm)
diff --git a/debian/rules.d/binary-libgcc.mk b/debian/rules.d/binary-libgcc.mk
index 4b2ef1f..69d9860 100644
--- a/debian/rules.d/binary-libgcc.mk
+++ b/debian/rules.d/binary-libgcc.mk
@@ -48,6 +48,8 @@ header_files = \
$(gcc_lib_dir)/include/std*.h \
$(shell for h in \
README features.h arm_fp16.h arm_neon.h loongson.h \
+ string.h spawn.h wchar.h math.h complex.h \
+ sys/nsctl/nsctl.h sys/feature_tests.h sys/int_const.h sys/int_limits.h \
{cpuid,decfloat,float,iso646,limits,mm3dnow,mm_malloc}.h \
{ppu_intrinsics,paired,spu2vmx,vec_types,si2vmx}.h \
{,a,b,e,i,n,p,s,t,w,x}mmintrin.h mmintrin-common.h \
@@ -66,6 +68,7 @@ header_files = \
done) \
$(shell for d in \
asm bits cilk gnu linux sanitizer $(TARGET_ALIAS) \
+ iso netinet \
$(subst $(DEB_TARGET_GNU_CPU),$(biarch_cpu),$(TARGET_ALIAS)); \
do \
test -e $(d)/$(gcc_lib_dir)/include/$$d \
@@ -222,12 +225,12 @@ define __do_gcc_devels2
$(if $(filter yes, $(with_lib$(1)gmath)),
$(call install_gcc_lib,libgcc-math,$(GCC_SONAME),$(1),$(2))
)
- $(if $(filter yes, $(with_libssp)),
- $(call install_gcc_lib,libssp,$(SSP_SONAME),$(1),$(2))
- )
$(if $(filter yes, $(with_ssp)),
mv $(4)/libssp_nonshared.a debian/$(2)/$(3)/;
)
+ $(if $(filter yes, $(with_libssp)),
+ $(call install_gcc_lib,libssp,$(SSP_SONAME),$(1),$(2))
+ )
$(if $(filter yes, $(with_gomp)),
$(call install_gcc_lib,libgomp,$(GOMP_SONAME),$(1),$(2))
)
diff --git a/debian/rules.defs b/debian/rules.defs
index fb2f456..a80ba88 100644
--- a/debian/rules.defs
+++ b/debian/rules.defs
@@ -1011,6 +1011,10 @@ ifeq ($(with_base_only),yes)
with_d := no
endif
+ifeq ($(DEB_HOST_ARCH),illumos-amd64)
+ with_d := no
+endif
+
ifeq ($(with_d)-$(with_separate_gdc),yes-yes)
ifneq (,$(findstring gdc,$(PKGSOURCE)))
languages := c c++
@@ -1332,6 +1336,9 @@ GFDL_INVARIANT_FREE := yes
ifeq ($(derivative),Ubuntu)
GFDL_INVARIANT_FREE := no
endif
+ifeq ($(DEB_TARGET_ARCH_OS),illumos)
+ GFDL_INVARIANT_FREE := no
+endif
# -------------------------------------------------------------------
# non-extra config
@@ -1360,9 +1367,8 @@ else
# libssp ------------------
ifeq ($(with_ssp)-$(with_common_libs),yes-yes)
#ifneq ($(DEB_CROSS),yes)
- with_libssp := $(if $(wildcard $(builddir)/gcc/auto-host.h),$(shell if grep -qs '^\#define TARGET_LIBC_PROVIDES_SSP 1' $(builddir)/gcc/auto-host.h; then echo 'libc provides ssp'; else echo 'yes'; fi))
+ with_libssp := $(if $(wildcard $(builddir)/gcc/auto-host.h),$(shell if grep -qs '^\#define TARGET_LIBC_PROVIDES_SSP 1' $(builddir)/gcc/auto-host.h; then printf 'libc provides ssp'; else printf 'yes'; fi))
#endif
- with_libssp := libc provides ssp
endif
# libgomp -----------------
@@ -1712,7 +1718,7 @@ define gen_biarch
export TARGET64_MACHINE
endif
endef
-biarch32archs := /amd64/ppc64/kfreebsd-amd64/s390x/sparc64/x32/mipsn32/mipsn32el/mips64/mips64el/
+biarch32archs := /amd64/ppc64/kfreebsd-amd64/s390x/sparc64/x32/mipsn32/mipsn32el/mips64/mips64el/illumos-amd64/
biarch64archs := /i386/powerpc/sparc/s390/mips/mipsel/mipsn32/mipsn32el/x32/
biarchn32archs := /mips/mipsel/mips64/mips64el/
ifeq ($(derivative),Ubuntu)
diff --git a/debian/rules.patch b/debian/rules.patch
index 5e9356e..652a94e 100644
--- a/debian/rules.patch
+++ b/debian/rules.patch
@@ -395,6 +395,19 @@ ifeq ($(DEB_TARGET_ARCH),m68k)
endif
endif
+ifeq ($(DEB_TARGET_ARCH_OS), illumos)
+ debian_patches += illumos-multiarch
+ debian_patches += illumos-spec
+ debian_patches += illumos-use_libgcj_bc
+ debian_patches += illumos-pragma-align
+ debian_patches += illumos-fclone-functions
+ debian_patches += illumos-strict-calling-conventions
+ debian_patches += illumos-boehm-gc
+ debian_patches += illumos-libgcc-regs
+ debian_patches += illumos-sysdep-unix.c
+ debian_patches += illumos-libgo-lfstack
+endif
+
# don't remove, this is regularly overwritten, see PR sanitizer/63958.
#debian_patches += libasan-sparc
diff --git a/debian/rules2 b/debian/rules2
index b029865..b38cbf5 100644
--- a/debian/rules2
+++ b/debian/rules2
@@ -252,6 +252,20 @@ else
--enable-shared \
--enable-linker-build-id \
+# we need libgcc shared since we use unwind functions from it,
+# not from libc, default is -static-libstdc++ and -static-libgcc.
+# We are lucky that we can use host libgcc, better way
+# could be hackery with LD_LIBRARY_PATH.
+ ifeq (illumos,$(DEB_TARGET_ARCH_OS))
+ CONFARGS += \
+ --enable-tls \
+ --enable-threads=posix \
+ --enable-libmudflap \
+ --with-boot-ldflags=-static-libstdc++ \
+ --with-gnu-as \
+ --with-gnu-ld
+ endif
+
ifneq ($(single_package),yes)
CONFARGS += \
--libexecdir=/$(libexecdir) \
@@ -587,7 +601,7 @@ ifeq ($(DEB_TARGET_ARCH_OS),linux)
endif
endif
-ifneq (,$(filter $(DEB_TARGET_ARCH), amd64 i386 kfreebsd-i386 kfreebsd-amd64))
+ifneq (,$(filter $(DEB_TARGET_ARCH), amd64 i386 kfreebsd-i386 kfreebsd-amd64 illumos-amd64))
ifneq (,$(filter $(derivative),Ubuntu))
ifneq (,$(filter $(distrelease),dapper hardy))
CONFARGS += --with-arch-32=i486
@@ -1311,14 +1325,6 @@ else ifneq (,$(filter $(build_type),build-cross cross-build-native cross-build-c
endif
@echo TTTTT $$(date -R)
s=`cat status`; rm -f status; \
- if [ $$s -ne 0 ] && [ -z "$$NO_CONFIG_LOG_DUMP$$NO_CONFIG_LOG_DUMPS" ]; then \
- for log in $$(find $(builddir) -name config.log); do \
- case "$$log" in */build/build-*|*/stage1-*|*/prev-*) continue; esac; \
- echo LOGFILE START $$log; \
- cat $$log; \
- echo LOGFILE END $$log; \
- done; \
- fi; \
test $$s -eq 0
if [ -f $(srcdir)/contrib/warn_summary ]; then \
diff --git a/debian/source/local-options b/debian/source/local-options
new file mode 100644
index 0000000..8217775
--- /dev/null
+++ b/debian/source/local-options
@@ -0,0 +1 @@
+tar-ignore = ".git"