pkgsrc-Users archive

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

[PATCH] fix 2015Q4 textproc/icu build (on CentOS 7)



Hi,

I encountered that funny out of memory / segfault crash during
textproc/icu build with 2015Q4 on CentOS 7 using gcc-4.9.3. This is a
known issue, see 

	http://bugs.icu-project.org/trac/ticket/11959

. Attached is a patch on the pkgsrc tree that applies the fix and
enables the build to succeed for me.

Fun fact aside: A manual build using that compiler outside pkgsrc works
fine, only the build within the pkgsrc/buildlink environment triggers
that crash. I was not able to discern any obvious difference like
differing CFLAGS or such. Perhaps the combination with some pkgsrc tool
being picked up instead of a system on.


Alrighty then,

Thomas

-- 
Dr. Thomas Orgis
Universität Hamburg
RRZ / Zentrale Dienste / HPC
Schlüterstr. 70
20146 Hamburg
Tel.: 040/42838 8826
Fax: 040/428 38 6270
Patch from http://bugs.icu-project.org/trac/ticket/11959

Failure mode:

make[2]: Leaving directory `/scratch/sw/work/gcc-4.9.3_openmpi-1.8.8/pkgsrc-2015Q4/textproc/icu/work/icu/source/tools/gencfu'
/usr/bin/make[1]: Making `all' in `gendict'
make[2]: Entering directory `/scratch/sw/work/gcc-4.9.3_openmpi-1.8.8/pkgsrc-2015Q4/textproc/icu/work/icu/source/tools/gendict'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/scratch/sw/work/gcc-4.9.3_openmpi-1.8.8/pkgsrc-2015Q4/textproc/icu/work/icu/source/tools/gendict'
make[2]: Entering directory `/scratch/sw/work/gcc-4.9.3_openmpi-1.8.8/pkgsrc-2015Q4/textproc/icu/work/icu/source/tools'
make[2]: Nothing to be done for `all-local'.
make[2]: Leaving directory `/scratch/sw/work/gcc-4.9.3_openmpi-1.8.8/pkgsrc-2015Q4/textproc/icu/work/icu/source/tools'
make[1]: Leaving directory `/scratch/sw/work/gcc-4.9.3_openmpi-1.8.8/pkgsrc-2015Q4/textproc/icu/work/icu/source/tools'
/usr/bin/make[0]: Making `all' in `data'
make[1]: Entering directory `/scratch/sw/work/gcc-4.9.3_openmpi-1.8.8/pkgsrc-2015Q4/textproc/icu/work/icu/source/data'
LD_LIBRARY_PATH=../stubdata:../tools/ctestfw:../lib:$LD_LIBRARY_PATH  ../bin/pkgdata -O ../data/icupkg.inc -q -c -s /scratch/sw/work/gcc-4.9.3_openmpi-1.8.8/pkgsrc-2015Q4/textproc/icu/work/icu/source/data/out/build/icudt56l -d ../lib -e icudt56  -T ./out/tmp -p icudt56l -L icudata -m static -r 56.1 ./out/tmp/icudata.lst
Error allocating memory for pkgDataFlags.
make[1]: *** [packagedata] Segmentation fault
make[1]: Leaving directory `/scratch/sw/work/gcc-4.9.3_openmpi-1.8.8/pkgsrc-2015Q4/textproc/icu/work/icu/source/data'
make: *** [all-recursive] Error 2
*** Error code 2

Stop.
bmake[4]: stopped in /scratch/sw/work/gcc-4.9.3_openmpi-1.8.8/pkgsrc-tree-2015Q4/pkgsrc/textproc/icu
*** Error code 1

diff -ruN -x CVS pkgsrc-2015Q4/textproc/icu/distinfo pkgsrc/textproc/icu/distinfo
--- pkgsrc-2015Q4/textproc/icu/distinfo	2015-11-04 02:59:35.000000000 +0100
+++ pkgsrc/textproc/icu/distinfo	2016-01-20 18:15:36.084755742 +0100
@@ -22,3 +22,4 @@
 SHA1 (patch-configure.ac) = b0291cf02351cbad9b0c7340baea9eb81cabb158
 SHA1 (patch-tools-toolutil-pkg_genc.c) = b5a9eb679908d9f579ff095c5389ec1aa8df8e1e
 SHA1 (patch-tools_pkgdata_pkgdata.cpp) = 1c87fcc511f0e6cedbaf01c5164e522c33f19458
+SHA1 (patch-x-flagparser-fix.patch) = aa2c61416cc92b36c670c7a240d0c31db5848547
diff -ruN -x CVS pkgsrc-2015Q4/textproc/icu/patches/patch-x-flagparser-fix.patch pkgsrc/textproc/icu/patches/patch-x-flagparser-fix.patch
--- pkgsrc-2015Q4/textproc/icu/patches/patch-x-flagparser-fix.patch	1970-01-01 01:00:00.000000000 +0100
+++ pkgsrc/textproc/icu/patches/patch-x-flagparser-fix.patch	2016-01-20 18:14:23.556683743 +0100
@@ -0,0 +1,15 @@
+Index: tools/toolutil/flagparser.c
+===================================================================
+--- tools/toolutil/flagparser.c	(revision 38046)
++++ tools/toolutil/flagparser.c	(working copy)
+@@ -96,8 +96,8 @@
+     uprv_free(buffer);
+ 
+     T_FileStream_close(f);
+-    
+-    if (U_FAILURE(*status)) {
++
++    if (U_FAILURE(*status) && *status != U_BUFFER_OVERFLOW_ERROR) {
+         return -1;
+     }
+ 

Attachment: smime.p7s
Description: S/MIME cryptographic signature



Home | Main Index | Thread Index | Old Index