aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Eggert2014-01-04 16:55:29 -0800
committerPaul Eggert2014-01-04 16:55:29 -0800
commit81da295eebcfd94dcbd16531ceaecbf1cbad1804 (patch)
tree56f98a2792ab29aa9f4dc6096bfd45dc32110a90
parent5159d5902f0a6f48b354bc568f086d99c2e64ea0 (diff)
downloademacs-81da295eebcfd94dcbd16531ceaecbf1cbad1804.tar.gz
emacs-81da295eebcfd94dcbd16531ceaecbf1cbad1804.zip
Port to GNU/Linux with recent grsecurity/PaX patches (Bug#16343).
Problem and proposed patch reported by Ulrich Mueller; this patch uses a somewhat-different approach. * configure.ac (SETFATTR): New variable. * src/Makefile.in (SETFATTR): New macro. (temacs$(EXEEXT)): Use it.
-rw-r--r--ChangeLog7
-rw-r--r--configure.ac18
-rw-r--r--src/ChangeLog6
-rw-r--r--src/Makefile.in9
4 files changed, 37 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 24ff1b50abf..9cee33c4526 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
12014-01-05 Paul Eggert <eggert@cs.ucla.edu>
2
3 Port to GNU/Linux with recent grsecurity/PaX patches (Bug#16343).
4 Problem and proposed patch reported by Ulrich Mueller;
5 this patch uses a somewhat-different approach.
6 * configure.ac (SETFATTR): New variable.
7
12014-01-03 Paul Eggert <eggert@cs.ucla.edu> 82014-01-03 Paul Eggert <eggert@cs.ucla.edu>
2 9
3 Merge from gnulib, incorporating: 10 Merge from gnulib, incorporating:
diff --git a/configure.ac b/configure.ac
index 6d46c5b67c5..3822f4a8927 100644
--- a/configure.ac
+++ b/configure.ac
@@ -988,6 +988,24 @@ if test $opsys = gnu-linux; then
988 [if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then AC_MSG_RESULT(yes) 988 [if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then AC_MSG_RESULT(yes)
989 else AC_MSG_RESULT(no); PAXCTL=""; fi]) 989 else AC_MSG_RESULT(no); PAXCTL=""; fi])
990 fi 990 fi
991
992 if test "${SETFATTR+set}" != set; then
993 AC_CACHE_CHECK([for setfattr],
994 [emacs_cv_prog_setfattr],
995 [touch conftest.tmp
996 if (setfattr -n user.pax.flags conftest.tmp) >/dev/null 2>&1; then
997 emacs_cv_prog_setfattr=yes
998 else
999 emacs_cv_prog_setfattr=no
1000 fi])
1001 if test "$emacs_cv_prog_setfattr" = yes; then
1002 SETFATTR=setfattr
1003 else
1004 SETFATTR=no
1005 fi
1006 rm -f conftest.tmp
1007 AC_SUBST([SETFATTR])
1008 fi
991fi 1009fi
992 1010
993## Need makeinfo >= 4.7 (?) to build the manuals. 1011## Need makeinfo >= 4.7 (?) to build the manuals.
diff --git a/src/ChangeLog b/src/ChangeLog
index 2c4c7921147..42f79d2ae46 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,9 @@
12014-01-05 Paul Eggert <eggert@cs.ucla.edu>
2
3 Port to GNU/Linux with recent grsecurity/PaX patches (Bug#16343).
4 * Makefile.in (SETFATTR): New macro.
5 (temacs$(EXEEXT)): Use it.
6
12014-01-04 Martin Rudalics <rudalics@gmx.at> 72014-01-04 Martin Rudalics <rudalics@gmx.at>
2 8
3 Fix maximization behavior on Windows (Bug#16300). 9 Fix maximization behavior on Windows (Bug#16300).
diff --git a/src/Makefile.in b/src/Makefile.in
index 78e555d8733..00889e9a277 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -108,11 +108,12 @@ LD_SWITCH_SYSTEM_TEMACS=@LD_SWITCH_SYSTEM_TEMACS@
108## Flags to pass to ld only for temacs. 108## Flags to pass to ld only for temacs.
109TEMACS_LDFLAGS = $(LD_SWITCH_SYSTEM) $(LD_SWITCH_SYSTEM_TEMACS) 109TEMACS_LDFLAGS = $(LD_SWITCH_SYSTEM) $(LD_SWITCH_SYSTEM_TEMACS)
110 110
111## If available, the full path to the paxctl program. 111## If available, the names of the paxctl and setfattr programs.
112## On grsecurity/PaX systems, unexec will fail due to a gap between 112## On grsecurity/PaX systems, unexec will fail due to a gap between
113## the bss section and the heap. This can be prevented by disabling 113## the bss section and the heap. Older versions nee paxctl to work
114## memory randomization in temacs with "paxctl -r". See bug#11398. 114## around this, newer ones setfattr. See Bug#11398 and Bug#16343.
115PAXCTL = @PAXCTL@ 115PAXCTL = @PAXCTL@
116SETFATTR = @SETFATTR@
116 117
117## Some systems define this to request special libraries. 118## Some systems define this to request special libraries.
118LIBS_SYSTEM=@LIBS_SYSTEM@ 119LIBS_SYSTEM=@LIBS_SYSTEM@
@@ -494,6 +495,8 @@ temacs$(EXEEXT): $(LIBXMENU) $(ALLOBJS) \
494 $(TEMACS_POST_LINK) 495 $(TEMACS_POST_LINK)
495 test "$(CANNOT_DUMP)" = "yes" || \ 496 test "$(CANNOT_DUMP)" = "yes" || \
496 test "X$(PAXCTL)" = X || $(PAXCTL) -r temacs$(EXEEXT) 497 test "X$(PAXCTL)" = X || $(PAXCTL) -r temacs$(EXEEXT)
498 test "$(CANNOT_DUMP)" = "yes" || test -z "$(SETFATTR)" || \
499 $(SETFATTR) -n user.pax.flags -v r $@
497 500
498## The following oldxmenu-related rules are only (possibly) used if 501## The following oldxmenu-related rules are only (possibly) used if
499## HAVE_X11 && !USE_GTK, but there is no harm in always defining them. 502## HAVE_X11 && !USE_GTK, but there is no harm in always defining them.