Using -O2 or -O3 CFLAGS and compiling with x86_64-pc-linux-gnu-gcc-4.9.2 or cross-compiling with armv7a-hardfloat-linux-gnueabi-gcc-4.9.2 causes failure in the compile phase with error "./.libs/libgcrypt.so: undefined reference to `__warn_memset_zero_len'". This is a known problem with gcc-4*. It builds fine with -O1 or when using gcc-5*.
Created attachment 432352 [details] emerge --info
Created attachment 432354 [details, diff] libgcrypt-1.7.0.ebuild.patch Patch for libgcrypt-1.7.0.ebuild to change -O? to -O1 when using gcc-4*
(In reply to Peter Levine from comment #2) > Created attachment 432354 [details, diff] [details, diff] > libgcrypt-1.7.0.ebuild.patch > > Patch for libgcrypt-1.7.0.ebuild to change -O? to -O1 when using gcc-4* (In reply to Peter Levine from comment #0) > Using -O2 or -O3 CFLAGS and compiling with x86_64-pc-linux-gnu-gcc-4.9.2 or > cross-compiling with armv7a-hardfloat-linux-gnueabi-gcc-4.9.2 causes failure > in the compile phase with error "./.libs/libgcrypt.so: undefined reference > to `__warn_memset_zero_len'". This is a known problem with gcc-4*. It builds > fine with -O1 or when using gcc-5*. its not a generic issue, I'm building it successfully with -O2 and gcc 4.9.3. Do you have any references for the known issues? Also, please add configure and build logs
(In reply to Peter Levine from comment #0) > Using -O2 or -O3 CFLAGS and compiling with x86_64-pc-linux-gnu-gcc-4.9.2 or > cross-compiling with armv7a-hardfloat-linux-gnueabi-gcc-4.9.2 causes failure > in the compile phase with error "./.libs/libgcrypt.so: undefined reference > to `__warn_memset_zero_len'". This is a known problem with gcc-4*. It builds > fine with -O1 or when using gcc-5*. Like Peter, I can't compile libgcrypt with gcc v4.9.3 and -O2. However -O1 works.
(In reply to Mark Tomich from comment #4) > (In reply to Peter Levine from comment #0) > > Using -O2 or -O3 CFLAGS and compiling with x86_64-pc-linux-gnu-gcc-4.9.2 or > > cross-compiling with armv7a-hardfloat-linux-gnueabi-gcc-4.9.2 causes failure > > in the compile phase with error "./.libs/libgcrypt.so: undefined reference > > to `__warn_memset_zero_len'". This is a known problem with gcc-4*. It builds > > fine with -O1 or when using gcc-5*. > > Like Peter, I can't compile libgcrypt with gcc v4.9.3 and -O2. However -O1 > works. Can you provide details as requested in comment 3?
(In reply to Kristian Fiskerstrand from comment #5) > (In reply to Mark Tomich from comment #4) > > (In reply to Peter Levine from comment #0) > > > Using -O2 or -O3 CFLAGS and compiling with x86_64-pc-linux-gnu-gcc-4.9.2 or > > > cross-compiling with armv7a-hardfloat-linux-gnueabi-gcc-4.9.2 causes failure > > > in the compile phase with error "./.libs/libgcrypt.so: undefined reference > > > to `__warn_memset_zero_len'". This is a known problem with gcc-4*. It builds > > > fine with -O1 or when using gcc-5*. > > > > Like Peter, I can't compile libgcrypt with gcc v4.9.3 and -O2. However -O1 > > works. > > Can you provide details as requested in comment 3? Closing needinfo, reopen if able to reproduce and provide needed debug details as requested