Sat Aug 27 08:38:31 2016 UTC ()
Disable a specific optimization (-fno-optimize-strlen) instead of using -O0.
Apply this on all netbsd architectures, not just amd64.

PR pkg/51439, from stackfield.


(maya)
diff -r1.47 -r1.48 pkgsrc/editors/emacs24/Makefile
diff -r1.5 -r1.6 pkgsrc/editors/emacs24/hacks.mk

cvs diff -r1.47 -r1.48 pkgsrc/editors/emacs24/Attic/Makefile (expand / switch to unified diff)

--- pkgsrc/editors/emacs24/Attic/Makefile 2016/08/03 10:22:40 1.47
+++ pkgsrc/editors/emacs24/Attic/Makefile 2016/08/27 08:38:31 1.48
@@ -1,12 +1,12 @@ @@ -1,12 +1,12 @@
1# $NetBSD: Makefile,v 1.47 2016/08/03 10:22:40 adam Exp $ 1# $NetBSD: Makefile,v 1.48 2016/08/27 08:38:31 maya Exp $
2 2
3CONFLICTS+= emacs24-nox11-[0-9]* 3CONFLICTS+= emacs24-nox11-[0-9]*
4 4
5PKGREVISION= 12 5PKGREVISION= 13
6.include "../../editors/emacs24/Makefile.common" 6.include "../../editors/emacs24/Makefile.common"
7 7
8.include "options.mk" 8.include "options.mk"
9 9
10.include "../../graphics/hicolor-icon-theme/buildlink3.mk" 10.include "../../graphics/hicolor-icon-theme/buildlink3.mk"
11.include "../../sysutils/desktop-file-utils/desktopdb.mk" 11.include "../../sysutils/desktop-file-utils/desktopdb.mk"
12.include "../../mk/bsd.pkg.mk" 12.include "../../mk/bsd.pkg.mk"

cvs diff -r1.5 -r1.6 pkgsrc/editors/emacs24/Attic/hacks.mk (expand / switch to unified diff)

--- pkgsrc/editors/emacs24/Attic/hacks.mk 2016/08/23 20:27:40 1.5
+++ pkgsrc/editors/emacs24/Attic/hacks.mk 2016/08/27 08:38:31 1.6
@@ -1,27 +1,27 @@ @@ -1,27 +1,27 @@
1# $NetBSD: hacks.mk,v 1.5 2016/08/23 20:27:40 maya Exp $ 1# $NetBSD: hacks.mk,v 1.6 2016/08/27 08:38:31 maya Exp $
2 2
3.if !defined(EMACS_HACKS_MK) 3.if !defined(EMACS_HACKS_MK)
4EMACS_HACKS_MK= defined 4EMACS_HACKS_MK= defined
5 5
6.include "../../mk/compiler.mk" 6.include "../../mk/compiler.mk"
7 7
8### On NetBSD/amd64 7.99.26, gcc optimisation, at least for version 5.x, 8### On NetBSD/amd64 7.99.26, gcc optimisation, at least for version 5.x,
9### produces, a "temacs" binary which segfaults. 9### produces, a "temacs" binary which segfaults.
10### 10###
11. if !empty(MACHINE_PLATFORM:MNetBSD-*-x86_64) 11. if !empty(MACHINE_PLATFORM:MNetBSD-*)
12. if !empty(CC_VERSION:Mgcc-5.*) 12. if !empty(CC_VERSION:Mgcc-5.*)
13PKG_HACKS+= optimisation 13PKG_HACKS+= optimisation
14BUILDLINK_TRANSFORM+= opt:-O2:-O0 14CFLAGS+= -fno-optimize-strlen
15. endif 15. endif
16. endif 16. endif
17 17
18### PaX is enabled, bootstrap-emacs command dumps core with segfault. 18### PaX is enabled, bootstrap-emacs command dumps core with segfault.
19### emacs-24.5/src/Makefile.in does not support NetBSD paxctl(8) syntax. 19### emacs-24.5/src/Makefile.in does not support NetBSD paxctl(8) syntax.
20### http://debbugs.gnu.org/cgi/bugreport.cgi?bug=23371 20### http://debbugs.gnu.org/cgi/bugreport.cgi?bug=23371
21### 21###
22. if !empty(MACHINE_PLATFORM:MNetBSD-*) 22. if !empty(MACHINE_PLATFORM:MNetBSD-*)
23. if exists(/usr/sbin/paxctl) 23. if exists(/usr/sbin/paxctl)
24SUBST_CLASSES+= paxctl 24SUBST_CLASSES+= paxctl
25SUBST_STAGE.paxctl= pre-configure 25SUBST_STAGE.paxctl= pre-configure
26SUBST_MESSAGE.paxctl= Setting paxctl command 26SUBST_MESSAGE.paxctl= Setting paxctl command
27SUBST_FILES.paxctl+= src/Makefile.in 27SUBST_FILES.paxctl+= src/Makefile.in