summaryrefslogtreecommitdiffstats
path: root/source/n/nn
diff options
context:
space:
mode:
author Patrick J Volkerding <volkerdi@slackware.com>2010-05-19 08:58:23 +0000
committer Eric Hameleers <alien@slackware.com>2018-05-31 22:43:05 +0200
commitb76270bf9e6dd375e495fec92140a79a79415d27 (patch)
tree3dbed78b2279bf9f14207a16dc634b90995cbd40 /source/n/nn
parent5a12e7c134274dba706667107d10d231517d3e05 (diff)
downloadcurrent-b76270bf9e6dd375e495fec92140a79a79415d27.tar.gz
current-b76270bf9e6dd375e495fec92140a79a79415d27.tar.xz
Slackware 13.1slackware-13.1
Wed May 19 08:58:23 UTC 2010 Slackware 13.1 x86_64 stable is released! Lots of thanks are due -- see the RELEASE_NOTES and the rest of the ChangeLog for credits. The ISOs are on their way to replication, a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. We are taking pre-orders now at store.slackware.com, and offering a discount if you sign up for a subscription. Consider picking up a copy to help support the project. Thanks again to the Slackware community for testing, contributing, and generally holding us to a high level of quality. :-) Enjoy!
Diffstat (limited to 'source/n/nn')
-rw-r--r--source/n/nn/m-x86_64.h37
-rwxr-xr-xsource/n/nn/nn.SlackBuild33
-rw-r--r--source/n/nn/nn.diff39
3 files changed, 99 insertions, 10 deletions
diff --git a/source/n/nn/m-x86_64.h b/source/n/nn/m-x86_64.h
new file mode 100644
index 000000000..931a6139f
--- /dev/null
+++ b/source/n/nn/m-x86_64.h
@@ -0,0 +1,37 @@
+/************** Machine (and compiler) dependent definitions. **************
+ *
+ * This file is for 80386 based UNIX/XENIX systems.
+ */
+
+
+/* MACHINE TYPE DEFINED TYPE VALUE RANGE */
+
+typedef unsigned char int8; /* 0 .. 255 */
+typedef short int16; /* -10,000 .. 10,000 */
+typedef int int32; /* -100,000 .. 100,000 */
+typedef unsigned int uint32; /* 0 .. 2^31-1 */
+
+
+
+#ifdef NETWORK_DATABASE
+
+#if 1
+
+/* If you want network byte order, you most likely have TCP as well. */
+/* else... why want network byte order??? */
+
+#define NETWORK_BYTE_ORDER /* THEY ARE NOT */
+#include <netinet/in.h>
+
+#else
+
+#undef NETWORK_BYTE_ORDER /* THEY ARE NOT */
+/*
+YOU LOSE -- I DON'T KNOW HOW TO DO THIS ON 80386 BASED SYSTEMS!
+*/
+#define htonl(l) ... /* host long to network long */
+#define ntohl(l) ... /* network long to host long */
+
+#endif
+
+#endif /* NETWORK DATABASE */
diff --git a/source/n/nn/nn.SlackBuild b/source/n/nn/nn.SlackBuild
index 45b694375..41757fcca 100755
--- a/source/n/nn/nn.SlackBuild
+++ b/source/n/nn/nn.SlackBuild
@@ -21,18 +21,30 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
VERSION=6.7.3
-ARCH=${ARCH:-x86_64}
-BUILD=${BUILD:-2}
+BUILD=${BUILD:-3}
+
+# Automatically determine the architecture we're building on:
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) export ARCH=i486 ;;
+ arm*) export ARCH=arm ;;
+ # Unless $ARCH is already set, use uname -m for all other archs:
+ *) export ARCH=$( uname -m ) ;;
+ esac
+fi
if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
LIBDIRSUFFIX=""
-elif [ "$ARCH" = "s390" ]; then
- SLKCFLAGS="-O2"
- LIBDIRSUFFIX=""
+ MFILE="m-i80386.h"
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
+ MFILE="m-x86_64.h"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+ MFILE="m-i80386.h"
fi
CWD=$(pwd)
@@ -53,14 +65,19 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
-zcat $CWD/nn.diff.gz | sed -e "s#/usr/lib/nn#/usr/lib${LIBDIRSUFFIX}/nn#" \
- | patch -p1 --verbose || exit 1
+zcat $CWD/nn.diff.gz \
+ | sed -e "s#m-sparc.h#${MFILE}#" \
+ | sed -e "s#/usr/lib/nn#/usr/lib${LIBDIRSUFFIX}/nn#" \
+ | patch -p0 --verbose || exit 1
+if [ $ARCH = "x86_64" ]; then
+ zcat $CWD/m-x86_64.h.gz > conf/m-x86_64.h
+fi
zcat $CWD/nn.badnntphost.diff.gz | patch -p1 --verbose || exit 1
# Taken from slamd64 (who adapted an old Ubuntu patch);
# Besides adding DESTDIR support, it gets rid of the hardlinks that are created:
zcat $CWD/nn.destdir.diff.gz | patch -p1 --verbose || exit 1
-cp config.h-dist config.h
+cat config.h-dist | sed -e "s#m-sparc.h#${MFILE}#" > config.h
make all
echo "*** USE install option 's'"
diff --git a/source/n/nn/nn.diff b/source/n/nn/nn.diff
index 04ec3c4c2..e78cad97e 100644
--- a/source/n/nn/nn.diff
+++ b/source/n/nn/nn.diff
@@ -1,5 +1,19 @@
---- ./config.h-dist.orig 2005-04-01 14:44:22.000000000 -0600
-+++ ./config.h-dist 2006-06-27 16:33:00.000000000 -0500
+--- conf/s-linux.h.orig 2009-11-11 15:43:05.780197095 -0500
++++ conf/s-linux.h 2009-11-11 15:44:38.760195349 -0500
+@@ -131,9 +131,9 @@
+ * (in config.h).
+ */
+
+-#define HAVE_GETHOSTNAME /* BSD systems */
++/* #define HAVE_GETHOSTNAME /* BSD systems */
+ /* #define HAVE_UNAME */ /* System V */
+-/* #define HOSTNAME_FILE "/etc/uucpname" /* or another file */
++#define HOSTNAME_FILE "/etc/HOSTNAME" /* or another file */
+ /* #define HOSTNAME_WHOAMI /* in <whoami.h> */
+
+ /*
+--- config.h-dist.orig 2009-11-11 15:44:13.560225381 -0500
++++ config.h-dist 2009-11-11 15:49:36.937239629 -0500
@@ -45,7 +45,7 @@
#define DO_NOV_DIGEST
@@ -73,6 +87,17 @@
#define DAEMON_MAN_SECTION "8"
+@@ -301,8 +301,8 @@
+ * SIGN_TYPE is the program to be used to create digital signatures.
+ */
+
+-/* #define SIGN_TYPE "gpg" */
+-#define SIGN_TYPE "pgp"
++#define SIGN_TYPE "gpg"
++/* #define SIGN_TYPE "pgp" */
+
+ /*
+ * If no "Lines:" header field is present, NN can be made to
@@ -425,7 +425,7 @@
* Default: NEWS_LIB_DIR/{rm,del}group
*/
@@ -83,3 +108,13 @@
+/* #define NEWS_LIB_DIRECTORY "/var/lib/news" */
/************************ CONFIGURATION COMPLETED ************************/
+--- hostname.c.orig 2009-11-11 16:00:16.485194441 -0500
++++ hostname.c 2009-11-11 16:15:25.741225660 -0500
+@@ -17,6 +17,7 @@
+ #include <unistd.h>
+ #include <string.h>
+ #include "config.h"
++#include "global.h"
+
+ #undef DONE
+