diff options
author | Ashish SHUKLA <ashish@FreeBSD.org> | 2013-05-13 05:14:24 +0000 |
---|---|---|
committer | Ashish SHUKLA <ashish@FreeBSD.org> | 2013-05-13 05:14:24 +0000 |
commit | 383c41acbdc54056ec7d4e438e15c5645236ef0e (patch) | |
tree | ccfded74e1e37be1687ef3a6db680d249ec1eed3 /editors | |
parent | 6db4b595801f3c8dfa5f8fc9f37f5c661df0fb99 (diff) |
- Unbreak on FreeBSD 9.x and later
Notes
Notes:
svn path=/head/; revision=317995
Diffstat (limited to 'editors')
-rw-r--r-- | editors/emacs22/Makefile | 3 | ||||
-rw-r--r-- | editors/emacs22/files/patch-src-filelock.c | 56 |
2 files changed, 54 insertions, 5 deletions
diff --git a/editors/emacs22/Makefile b/editors/emacs22/Makefile index 5db92c31dead..b672591f8b11 100644 --- a/editors/emacs22/Makefile +++ b/editors/emacs22/Makefile @@ -3,7 +3,6 @@ PORTNAME= emacs PORTVERSION= ${EMACS_VER} -PORTREVISION= 6 PORTEPOCH= 1 CATEGORIES= editors ipv6 MASTER_SITES= ${MASTER_SITE_GNU} @@ -68,8 +67,6 @@ LATEST_LINK= emacs22 .if ${ARCH} == "ia64" BROKEN= Emacs 22.X does not currently build on ia64 -.elif ${OSVERSION} >= 900007 -BROKEN= does not build .endif pre-everything:: diff --git a/editors/emacs22/files/patch-src-filelock.c b/editors/emacs22/files/patch-src-filelock.c index aa91b98f2aeb..7ed56f40a81e 100644 --- a/editors/emacs22/files/patch-src-filelock.c +++ b/editors/emacs22/files/patch-src-filelock.c @@ -1,5 +1,8 @@ ---- src/filelock.c.org 2008-01-07 23:30:11.000000000 -0500 -+++ src/filelock.c 2010-02-12 17:50:08.000000000 -0500 + +$FreeBSD$ + +--- src/filelock.c.orig ++++ src/filelock.c @@ -64,7 +64,12 @@ #ifdef CLASH_DETECTION @@ -32,3 +35,52 @@ int desc; if (filename) +@@ -272,16 +281,28 @@ + + emacs_close (desc); + ++#if __FreeBSD_version >= 900007 ++ setutxdb (UTXDB_ACTIVE, filename); ++#else + utmpname (filename); ++#endif + } + ++#if __FreeBSD_version >= 900007 ++ setutxent (); ++#else + setutent (); ++#endif + + while (1) + { + /* Find the next reboot record. */ + ut.ut_type = BOOT_TIME; ++#if __FreeBSD_version >= 900007 ++ utp = getutxid (&ut); ++#else + utp = getutid (&ut); ++#endif + if (! utp) + break; + /* Compare reboot times and use the newest one. */ +@@ -293,11 +314,19 @@ + } + /* Advance on element in the file + so that getutid won't repeat the same one. */ ++#if __FreeBSD_version >= 900007 ++ utp = getutxent (); ++#else + utp = getutent (); ++#endif + if (! utp) + break; + } ++#if __FreeBSD_version >= 900007 ++ endutxent(); ++#else + endutent (); ++#endif + } + #endif /* BOOT_TIME */ + |