[arch-commits] Commit in nawk/trunk (PKGBUILD manpage-naming.patch)
Dave Reisner
dreisner at archlinux.org
Sat Aug 25 10:41:14 UTC 2018
Date: Saturday, August 25, 2018 @ 10:41:13
Author: dreisner
Revision: 333001
upgpkg: nawk 20180824-1
- pull latest from github sources
- fix license, it's a custom lucent deal
- ensure binary has full RELRO
- include testsuite in packaging
Modified:
nawk/trunk/PKGBUILD
nawk/trunk/manpage-naming.patch
----------------------+
PKGBUILD | 45 +++++++++++++++++++++++++++++++--------------
manpage-naming.patch | 35 +++++++++++++++--------------------
2 files changed, 46 insertions(+), 34 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2018-08-25 08:35:48 UTC (rev 333000)
+++ PKGBUILD 2018-08-25 10:41:13 UTC (rev 333001)
@@ -2,37 +2,54 @@
# Maintainer: Dave Reisner <dreisner at archlinux.org>
pkgname=nawk
-pkgver=20121220
-pkgrel=3
+pkgver=20180824
+pkgrel=1
pkgdesc="The one, true implementation of AWK"
-url="https://www.cs.princeton.edu/~bwk/btl.mirror/"
-license=('MIT')
+url="https://github.com/onetrueawk/awk"
+license=('custom')
arch=('x86_64')
options=('!makeflags')
depends=('glibc')
-source=("$pkgname-$pkgver.tar.gz::https://www.cs.princeton.edu/~bwk/btl.mirror/awk.tar.gz"
+makedepends=('git')
+source=(git+https://github.com/onetrueawk/awk
'manpage-naming.patch')
-md5sums=('b74ca7f8f4284fc82ccee6b4e34531d8'
- '8486d387a51fe3b3c9875c4151ad92b4')
+md5sums=('SKIP'
+ '5413692140f8366f8ae6bcecc9a40f2f')
+pkgver() {
+ cd awk
+
+ git --no-pager log --pretty='format:%ad' --date=format:%Y%m%d HEAD~..
+}
+
prepare() {
+ cd awk
+
# awk -> nawk
patch -Np1 <"$srcdir"/manpage-naming.patch
- # create license
- sed -n '/Copyright/,/THIS SOFTWARE\./p' README > LICENSE
+ bsdtar xf awktest.tar
+}
- # fix build
- sed -i '/YACC = yacc -d -S/ s|^|#|' makefile
+check() {
+ cd awk
+
+ ./REGRESS
}
build() {
- make "CPPFLAGS=-DHAS_ISBLANK $CPPFLAGS" \
- "LDFLAGS=$LDFLAGS" \
- "CFLAGS=$CFLAGS"
+ cd awk
+
+ # the final linking step doesn't honor LDFLAGS, so let's just throw it all
+ # together into CFLAGS.
+ make \
+ "CPPFLAGS=-DHAS_ISBLANK $CPPFLAGS" \
+ "CFLAGS=$CFLAGS $LDFLAGS"
}
package() {
+ cd awk
+
install -Dm755 a.out "$pkgdir/usr/bin/nawk"
install -Dm644 awk.1 "$pkgdir/usr/share/man/man1/nawk.1"
install -Dm644 LICENSE "$pkgdir/usr/share/licenses/nawk/LICENSE"
Modified: manpage-naming.patch
===================================================================
--- manpage-naming.patch 2018-08-25 08:35:48 UTC (rev 333000)
+++ manpage-naming.patch 2018-08-25 10:41:13 UTC (rev 333001)
@@ -1,14 +1,14 @@
-diff -uNr ./nawk-20100523.orig/awk.1 nawk-20100523/awk.1
---- ./nawk-20100523.orig/awk.1 2007-03-31 16:56:19.000000000 -0400
-+++ nawk-20100523/awk.1 2010-09-20 21:49:16.840069318 -0400
-@@ -7,13 +7,11 @@
+diff --git a/awk.1 b/awk.1
+index 5830143..339271e 100644
+--- a/awk.1
++++ b/awk.1
+@@ -7,12 +7,12 @@
.fi
.ft 1
..
--awk
-.TH AWK 1
--.CT 1 files prog_other
+.TH NAWK 1
+ .CT 1 files prog_other
.SH NAME
-awk \- pattern-directed scanning and processing language
+nawk \- pattern-directed scanning and processing language
@@ -18,7 +18,7 @@
[
.BI \-F
.I fs
-@@ -32,7 +30,7 @@
+@@ -31,7 +31,7 @@ awk \- pattern-directed scanning and processing language
.I file ...
]
.SH DESCRIPTION
@@ -27,20 +27,15 @@
scans each input
.I file
for lines that match any of a set of patterns specified literally in
-@@ -198,7 +196,6 @@
- .BR atan2
- are built in.
- Other built-in functions:
--.TF length
- .TP
- .B length
- the length of its argument
-@@ -407,7 +404,6 @@
+@@ -426,7 +426,7 @@ and
do not combine with other patterns.
+ They may appear multiple times in a program and execute
+ in the order they are read by
+-.IR awk .
++.IR nawk .
.PP
Variable names with special meanings:
--.TF FILENAME
- .TP
- .B CONVFMT
- conversion format used when converting numbers
+ .TF FILENAME
+--
+2.18.0
More information about the arch-commits
mailing list