Source: libgc
Version: 7.2d-5
Severity: normal
Tags: patch
User: debian-...@lists.debian.org
Usertag: arm64

This package does not build for arm64.

It needs updated config.sub/guess autoconf files, updated symbols file
and updated private config file 

This patch is a minimal one, which just uses dh-autotools to updated
config.{sub,guess}. It would probably be better to use dh-autoreconf to
do a full autotools update. See the Ubuntu patch for an example of this.
I didn't do this as there is already a dh_autoreconf override in the
rules file, commented out. Maybe there is a good reason for that?

The ubuntu patch also removes the need for kde-pkg-tools. That is no
longer necesssary, but would be a good idea as a BUILD_PROFILE to
facilitate bootstrapping. Someone will file a separate bug about that.

-- System Information:
Debian Release: 7.3
  APT prefers stable
  APT policy: (990, 'stable')
Architecture: i386 (i686)

Kernel: Linux 3.2.0-kvm-i386-20110111 (SMP w/1 CPU core)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
diff -Nru libgc-7.2d/debian/changelog libgc-7.2d/debian/changelog
--- libgc-7.2d/debian/changelog	2013-07-03 21:14:45.000000000 +0100
+++ libgc-7.2d/debian/changelog	2013-12-17 04:26:02.000000000 +0000
@@ -1,3 +1,13 @@
+libgc (1:7.2d-5arm64) unstable; urgency=low
+
+  * Ensure config.{sub,guess} are up to date, for new architectures
+
+  [Matthias Klose]
+  * Update symbols file for arm64.
+  * Backport Aarch64 changes.
+
+ -- Wookey <woo...@debian.org>  Tue, 17 Dec 2013 03:36:04 +0000
+
 libgc (1:7.2d-5) unstable; urgency=low
 
   * Add Replaces: libgc1c3 for Ubuntu
diff -Nru libgc-7.2d/debian/control libgc-7.2d/debian/control
--- libgc-7.2d/debian/control	2013-07-03 21:04:58.000000000 +0100
+++ libgc-7.2d/debian/control	2013-12-17 03:35:54.000000000 +0000
@@ -3,7 +3,7 @@
 Section: libs
 Priority: standard
 Build-Depends: debhelper (>= 9),
- autoconf,
+ autoconf, autotools-dev,
  libatomic-ops-dev (>= 7.3~),
  pkg-config,
  pkg-kde-tools
diff -Nru libgc-7.2d/debian/libgc1c2.symbols libgc-7.2d/debian/libgc1c2.symbols
--- libgc-7.2d/debian/libgc1c2.symbols	2013-07-03 21:10:27.000000000 +0100
+++ libgc-7.2d/debian/libgc1c2.symbols	2013-12-17 04:19:09.000000000 +0000
@@ -84,7 +84,7 @@
  GC_core_malloc@Base 1:7.2d
  GC_core_malloc_atomic@Base 1:7.2d
  GC_current_warn_proc@Base 1:7.2d
- (arch=!kfreebsd-amd64 !kfreebsd-i386 !mips !mipsel !s390 !s390x !sparc !sparc64)GC_data_start@Base 1:7.2d
+ (arch=!arm64 !kfreebsd-amd64 !kfreebsd-i386 !mips !mipsel !s390 !s390x !sparc !sparc64)GC_data_start@Base 1:7.2d
  GC_debug_change_stubborn@Base 1:7.2d
  GC_debug_end_stubborn_change@Base 1:7.2d
  GC_debug_free@Base 1:7.2d
@@ -159,7 +159,7 @@
  GC_ext_descriptors@Base 1:7.2d
  GC_extend_size_map@Base 1:7.2d
  GC_fail_count@Base 1:7.2d
- (arch=!mips !mipsel !s390 !s390x)GC_fault_handler@Base 1:7.2d
+ (arch=!arm64 !mips !mipsel !s390 !s390x)GC_fault_handler@Base 1:7.2d
  (arch=alpha amd64 i386 ia64 m68k x32)GC_fault_handler_lock@Base 1:7.2d
  GC_finalize@Base 1:7.2d
  GC_finalize_all@Base 1:7.2d
@@ -168,8 +168,8 @@
  GC_finalizer_notifier@Base 1:7.2d
  GC_find_header@Base 1:7.2d
  GC_find_leak@Base 1:7.2d
- (arch=!mips !mipsel !s390 !s390x)GC_find_limit@Base 1:7.2d
- (arch=!mips !mipsel !s390 !s390x)GC_find_limit_with_bound@Base 1:7.2d
+ (arch=!arm64 !mips !mipsel !s390 !s390x)GC_find_limit@Base 1:7.2d
+ (arch=!arm64 !mips !mipsel !s390 !s390x)GC_find_limit_with_bound@Base 1:7.2d
  GC_findleak_delay_free@Base 1:7.2d
  GC_finish_collection@Base 1:7.2d
  GC_fo_entries@Base 1:7.2d
@@ -265,7 +265,7 @@
  GC_init_explicit_typing@Base 1:7.2d
  GC_init_gcj_malloc@Base 1:7.2d
  GC_init_headers@Base 1:7.2d
- (arch=!kfreebsd-amd64 !kfreebsd-i386 !mips !mipsel !s390 !s390x !sparc !sparc64)GC_init_linux_data_start@Base 1:7.2d
+ (arch=!arm64 !kfreebsd-amd64 !kfreebsd-i386 !mips !mipsel !s390 !s390x !sparc !sparc64)GC_init_linux_data_start@Base 1:7.2d
  GC_init_parallel@Base 1:7.2d
  GC_init_size_map@Base 1:7.2d
  GC_init_thread_local@Base 1:7.2d
@@ -286,7 +286,7 @@
  GC_is_visible@Base 1:7.2d
  GC_is_visible_print_proc@Base 1:7.2d
  GC_java_finalization@Base 1:7.2d
- (arch=!mips !mipsel !s390 !s390x)GC_jmp_buf@Base 1:7.2d
+ (arch=!arm64 !mips !mipsel !s390 !s390x)GC_jmp_buf@Base 1:7.2d
  (arch=armel armhf hurd-i386)GC_key_create@Base 1:7.2d
  GC_large_alloc_warn_interval@Base 1:7.2d
  GC_large_alloc_warn_suppressed@Base 1:7.2d
@@ -477,7 +477,7 @@
  (arch=armel armhf hurd-i386)GC_remove_specific@Base 1:7.2d
  GC_remove_tmp_roots@Base 1:7.2d
  (arch=!hurd-i386 !kfreebsd-amd64 !kfreebsd-i386)GC_repeat_read@Base 1:7.2d
- (arch=!mips !mipsel !s390 !s390x)GC_reset_fault_handler@Base 1:7.2d
+ (arch=!arm64 !mips !mipsel !s390 !s390x)GC_reset_fault_handler@Base 1:7.2d
  GC_reset_finalizer_nested@Base 1:7.2d
  GC_restart_handler@Base 1:7.2d
  GC_retry_signals@Base 1:7.2d
@@ -515,7 +515,7 @@
  GC_set_warn_proc@Base 1:7.2d
  GC_setpagesize@Base 1:7.2d
  (arch=armel armhf hurd-i386)GC_setspecific@Base 1:7.2d
- (arch=!mips !mipsel !s390 !s390x)GC_setup_temporary_fault_handler@Base 1:7.2d
+ (arch=!arm64 !mips !mipsel !s390 !s390x)GC_setup_temporary_fault_handler@Base 1:7.2d
  GC_should_collect@Base 1:7.2d
  GC_should_invoke_finalizers@Base 1:7.2d
  GC_signal_mark_stack_overflow@Base 1:7.2d
@@ -582,7 +582,7 @@
 libgccpp.so.1 libgc1c2 #MINVER#
  _ZdaPv@Base 1:7.2d
  _ZdlPv@Base 1:7.2d
- (subst)_Zna{size_t}@Base 1:7.2d
- (subst)_Znw{size_t}@Base 1:7.2d
+ (arch=!arm64|subst)_Zna{size_t}@Base 1:7.2d
+ (arch=!arm64|subst)_Znw{size_t}@Base 1:7.2d
  (arch=sparc sparc64)_etext@Base 1:7.2d
  (arch=kfreebsd-amd64 kfreebsd-i386)etext@Base 1:7.2d
diff -Nru libgc-7.2d/debian/patches/arm64-support.patch libgc-7.2d/debian/patches/arm64-support.patch
--- libgc-7.2d/debian/patches/arm64-support.patch	1970-01-01 01:00:00.000000000 +0100
+++ libgc-7.2d/debian/patches/arm64-support.patch	2013-12-17 04:41:54.000000000 +0000
@@ -0,0 +1,74 @@
+Description: Add config for arm64/aarch64
+Author: Mattias Klose <d...@debian.org>
+
+---
+Last-Update: 2013-12-17
+
+--- libgc-7.2d.orig/include/private/gcconfig.h
++++ libgc-7.2d/include/private/gcconfig.h
+@@ -70,6 +70,13 @@
+ #    define I386
+ #    define mach_type_known
+ # endif
++#if defined(__aarch64__)
++#    define AARCH64
++#    if !defined(LINUX)
++#      define NOSYS
++#      define mach_type_known
++#    endif
++# endif
+ # if defined(__arm) || defined(__arm__) || defined(__thumb__)
+ #    define ARM32
+ #    if !defined(LINUX) && !defined(NETBSD) && !defined(OPENBSD) \
+@@ -250,6 +257,10 @@
+ #    define IA64
+ #    define mach_type_known
+ # endif
++# if defined(LINUX) && defined(__aarch64__)
++#    define AARCH64
++#    define mach_type_known
++# endif
+ # if defined(LINUX) && (defined(__arm) || defined(__arm__))
+ #    define ARM32
+ #    define mach_type_known
+@@ -541,6 +552,7 @@
+                     /*                  running Amdahl UTS4             */
+                     /*             S390       ==> 390-like machine      */
+                     /*                  running LINUX                   */
++                    /*             AARCH64    ==> ARM AArch64           */
+                     /*             ARM32      ==> Intel StrongARM       */
+                     /*             IA64       ==> Intel IPF             */
+                     /*                            (e.g. Itanium)        */
+@@ -1903,6 +1915,32 @@
+ #   endif
+ # endif
+ 
++# ifdef AARCH64
++#   define CPP_WORDSZ 64
++#   define MACH_TYPE "AARCH64"
++#   define ALIGNMENT 8
++#   ifndef HBLKSIZE
++#     define HBLKSIZE 4096
++#   endif
++#   ifdef LINUX
++#     define OS_TYPE "LINUX"
++#     define LINUX_STACKBOTTOM
++#     define USE_GENERIC_PUSH_REGS
++#     define DYNAMIC_LOADING
++      extern int __data_start[];
++#     define DATASTART ((ptr_t)__data_start)
++      extern char _end[];
++#     define DATAEND ((ptr_t)(&_end))
++#   endif
++#   ifdef NOSYS
++      /* __data_start is usually defined in the target linker script.   */
++      extern int __data_start[];
++#     define DATASTART ((ptr_t)__data_start)
++      extern void *__stack_base__;
++#     define STACKBOTTOM ((ptr_t)__stack_base__)
++#   endif
++# endif
++
+ # ifdef ARM32
+ #   define CPP_WORDSZ 32
+ #   define MACH_TYPE "ARM32"
diff -Nru libgc-7.2d/debian/patches/series libgc-7.2d/debian/patches/series
--- libgc-7.2d/debian/patches/series	2013-06-09 12:59:49.000000000 +0100
+++ libgc-7.2d/debian/patches/series	2013-12-17 04:40:17.000000000 +0000
@@ -5,3 +5,4 @@
 #05-s390-includes.diff
 enable-threads.diff
 allow-automake-1.13
+arm64-support.patch
diff -Nru libgc-7.2d/debian/rules libgc-7.2d/debian/rules
--- libgc-7.2d/debian/rules	2013-06-09 16:07:21.000000000 +0100
+++ libgc-7.2d/debian/rules	2013-12-17 04:05:26.000000000 +0000
@@ -8,11 +8,12 @@
 LDFLAGS += -pthread
 
 %:
-	dh $@ --with pkgkde_symbolshelper
+	dh $@ --with pkgkde_symbolshelper autotools_dev
 
 override_dh_auto_configure:
 	[ ! -d libatomic_ops-1.2 ] || mv libatomic_ops-1.2 libatomic_ops-1.2.bak
 	autoconf
+	dh_autotools-dev_updateconfig
 	./configure \
 		$(CONFIG_OPTS) \
 		--enable-cplusplus \

Reply via email to