pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/49077: Unbreak textproc/icu on OS X TIger



>Number:         49077
>Category:       pkg
>Synopsis:       Unbreak textproc/icu on OS X TIger
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Aug 06 00:10:00 +0000 2014
>Originator:     Sevan Janiyan
>Release:        -current
>Organization:
>Environment:
Darwin Kernel Version 8.11.0: Wed Oct 10 18:26:00 PDT 2007; 
root:xnu-792.24.17~1/RELEASE_PPC Power Macintosh powerpc
>Description:
ICU fails to build on Tiger with the error
putil.cpp: In function ?const char* uprv_tzname_49(int)?:
putil.cpp:1114: error: ?localtime_r? was not declared in this scope

followed by assembler errors as the version shipped with Xcode 2.5 & prior do 
not understand .balign

Patches lifted from the ICU trac via Tiger Brew 
http://bugs.icu-project.org/trac/ticket/9367

Modified the patch to putil.cpp so that it is specifically applies to Tiger on, 
in MacPorts this patch was handled by the port infrastructure rather than let 
cpp work it out.
>How-To-Repeat:

>Fix:
Index: distinfo
===================================================================
RCS file: /cvsroot/pkgsrc/textproc/icu/distinfo,v
retrieving revision 1.49
diff -u -r1.49 distinfo
--- distinfo    18 Jul 2014 10:28:11 -0000      1.49
+++ distinfo    5 Aug 2014 23:57:13 -0000
@@ -9,6 +9,7 @@
 SHA1 (patch-acinclude.m4) = a6993fefca751d7e63e60130cdcd69f3adbc0589
 SHA1 (patch-ad) = c2a9469bf896b5f0702d5795c3b1c2b394893663
 SHA1 (patch-af) = dcfbaf16844292a9ae57536ae2fb62fd1659d067
+SHA1 (patch-common_putil.cpp) = 20e6b239179a529217c2d8e700eb87ebe1a8791c
 SHA1 (patch-common_putilimp.h) = a68faa97c2bffeecaca1586e26f5bbe48e71b262
 SHA1 (patch-common_umutex.h) = 096d3e15ef7b84533456af4570ed70747a4ef70c
 SHA1 (patch-common_unicode_platform.h) = 
82786dff790782eb07cdc527061de33e771ec63c
@@ -18,3 +19,4 @@
 SHA1 (patch-config_mh-solaris-gcc) = f81fec8f0d232b9125c7ea7ec334b78872aa2025
 SHA1 (patch-configure) = aae0978c1eb1b2bafa229ba0f2e9d581554f80b2
 SHA1 (patch-configure.ac) = ea7586eb8131ff53a483b5bd7ca162886e9045f1
+SHA1 (patch-tools-toolutil-pkg_genc.c) = 
028e6318f4cc025cab9b118f66be10514ae10b35
Index: patches/patch-common_putil.cpp
===================================================================
RCS file: patches/patch-common_putil.cpp
diff -N patches/patch-common_putil.cpp
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ patches/patch-common_putil.cpp      5 Aug 2014 23:57:13 -0000
@@ -0,0 +1,20 @@
+$NetBSD$
+
+Index: common/putil.cpp
+===================================================================
+--- common/putil.cpp.orig 2012-06-01 10:52:46.000000000 -0400
++++ common/putil.cpp 2012-10-05 19:53:14.000000000 -0400
+@@ -123,6 +123,13 @@
+ #endif
+ 
+ /*
++ * Mac OS X 10.4 doesn't use its localtime_r() declaration in <time.h> if 
either _ANSI_SOURCE or _POSIX_C_SOURCE is #defined.
++ */
++#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ == 1040
++U_CFUNC struct tm *localtime_r(const time_t *, struct tm *);
++#endif
++
++/*
+  * Only include langinfo.h if we have a way to get the codeset. If we later
+  * depend on more feature, we can test on U_HAVE_NL_LANGINFO.
+  *
Index: patches/patch-tools-toolutil-pkg_genc.c
===================================================================
RCS file: patches/patch-tools-toolutil-pkg_genc.c
diff -N patches/patch-tools-toolutil-pkg_genc.c
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ patches/patch-tools-toolutil-pkg_genc.c     5 Aug 2014 23:57:13 -0000
@@ -0,0 +1,23 @@
+$NetBSD$
+
+Index: tools/toolutil/pkg_genc.c
+===================================================================
+--- tools/toolutil/pkg_genc.c.orig 2013-12-12 03:14:23.000000000 +0000
++++ tools/toolutil/pkg_genc.c
+@@ -125,13 +125,15 @@ static const struct AssemblyType {
+ 
+         ".long ","",HEX_0X
+     },
++    // Older assemblers for Darwin (like the one from Xcode 2.5) do not
++    // have .balign, but they take .align 4 to mean 2^4 = 16 bytes.
+     {"gcc-darwin",
+         /*"\t.section __TEXT,__text,regular,pure_instructions\n"
+         "\t.section 
__TEXT,__picsymbolstub1,symbol_stubs,pure_instructions,32\n"*/
+         ".globl _%s\n"
+         "\t.data\n"
+         "\t.const\n"
+-        "\t.balign 16\n"
++        "\t.align 4\n"
+         "_%s:\n\n",
+ 
+         ".long ","",HEX_0X



Home | Main Index | Thread Index | Old Index