Subject: pkg/7288: Enable lynx package to patch for ssleay automatically
To: None <gnats-bugs@gnats.netbsd.org>
From: Frederick Bruckman <fb@enteract.com>
List: netbsd-bugs
Date: 03/29/1999 21:13:10
>Number: 7288
>Category: pkg
>Synopsis: Enable lynx package to patch for ssleay automatically
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: gnats-admin (GNATS administrator)
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Mon Mar 29 19:20:01 1999
>Last-Modified:
>Originator: Frederick Bruckman
>Organization:
>Release: Mar 29, 1999
>Environment:
System: NetBSD corwin.home 1.3K NetBSD 1.3K (CORWIN) #31:
Sun Mar 28 09:50:24 CST 1999
fredb@corwin.home:/usr/src/sys/arch/mac68k/compile/CORWIN mac68k
>Description:
This update enables building Crypto Lynx, by setting USE_SSLEAY
in /etc/mk.conf. This enables support for https and snews urls.
(snews not tested.) Without USE_SSLEAY, it should produce a
binary that's identical to the old package.
I took a few other liberties with the package. I feel adding
another mk.conf variable, KEEP_COOKIES, is justified, for two
reasons. 1) You will never convince a substantial number of
individuals that cookies are not an Orwellian plot to control
our lives, and therefore many would object strongly, were
persistant cookies enabled by default. 2) OTH, if you don't
store them, they're completely useless for many purposes (CPAN
comes to mind immediatley), so the naive (trusting?) user needs
a simple way to enable them.
I've also moved the help docs to /usr/pkg/share/lynx, where they
belong, and also lynx.cfg. On the face of it, lynx.cfg looks
like it actually belongs in pkg/etc, but upon further
inspection, that file mainly points to the location of the help
docs. The way the package is set up, the path of least
resistance is to put them both together in pkg/share/lynx.
Additionally, now that there's a place for them, we install all
the supplemental docs.
>How-To-Repeat:
>Fix:
--- /usr/pkgsrc/www/lynx/files/md5.orig Thu Mar 25 17:26:29 1999
+++ /usr/pkgsrc/www/lynx/files/md5 Thu Mar 25 17:26:12 1999
@@ -2,2 +2,3 @@
MD5 (lynx2-8-1.tar.gz) = 7cf5e545052fb24a9b449d02865c803a
+MD5 (lynx-281-ssl.patch.gz) = ea9fa16ce066a68b0c9357bf46a35c0b
--- /usr/pkgsrc/www/lynx/pkg/PLIST.orig Tue Mar 16 20:45:21 1999
+++ /usr/pkgsrc/www/lynx/pkg/PLIST Tue Mar 16 20:47:21 1999
@@ -2,25 +2,52 @@
bin/lynx
-etc/lynx.cfg
-etc/lynx_help/Lynx_users_guide.html
-etc/lynx_help/about_lynx.html
-etc/lynx_help/keystrokes/bookmark_help.html
-etc/lynx_help/keystrokes/cookie_help.html
-etc/lynx_help/keystrokes/dired_help.html
-etc/lynx_help/keystrokes/edit_help.html
-etc/lynx_help/keystrokes/follow_help.html
-etc/lynx_help/keystrokes/gopher_types_help.html
-etc/lynx_help/keystrokes/history_help.html
-etc/lynx_help/keystrokes/keystroke_help.html
-etc/lynx_help/keystrokes/movement_help.html
-etc/lynx_help/keystrokes/option_help.html
-etc/lynx_help/keystrokes/other_help.html
-etc/lynx_help/keystrokes/print_help.html
-etc/lynx_help/keystrokes/scrolling_help.html
-etc/lynx_help/keystrokes/visited_help.html
-etc/lynx_help/keystrokes/xterm_help.html
-etc/lynx_help/lynx-dev.html
-etc/lynx_help/lynx_help_main.html
-etc/lynx_help/lynx_url_support.html
man/man1/lynx.1
-@dirrm etc/lynx_help/keystrokes
-@dirrm etc/lynx_help
+share/lynx/lynx.cfg
+share/lynx/lynx_doc/CHANGES
+share/lynx/lynx_doc/COPYHEADER
+share/lynx/lynx_doc/COPYING
+share/lynx/lynx_doc/PROBLEMS
+share/lynx/lynx_doc/README
+share/lynx/lynx_doc/samples/jumpsUnix.html
+share/lynx/lynx_doc/samples/jumpsVMS.html
+share/lynx/lynx_doc/samples/lynx-keymaps
+share/lynx/lynx_doc/samples/lynx.com
+share/lynx/lynx_doc/samples/lynx.lss
+share/lynx/lynx_doc/samples/mailcap
+share/lynx/lynx_doc/samples/mime.types
+share/lynx/lynx_doc/test/ALT88592.html
+share/lynx/lynx_doc/test/ISO_LATIN1_test.html
+share/lynx/lynx_doc/test/README.txt
+share/lynx/lynx_doc/test/TestComment.html
+share/lynx/lynx_doc/test/c1.html
+share/lynx/lynx_doc/test/iso8859-1.html
+share/lynx/lynx_doc/test/iso88592.html
+share/lynx/lynx_doc/test/raw8bit.html
+share/lynx/lynx_doc/test/sgml.html
+share/lynx/lynx_doc/test/spaces.html
+share/lynx/lynx_doc/test/tabtest.html
+share/lynx/lynx_doc/test/unicode.html
+share/lynx/lynx_help/Lynx_users_guide.html
+share/lynx/lynx_help/about_lynx.html
+share/lynx/lynx_help/keystrokes/bookmark_help.html
+share/lynx/lynx_help/keystrokes/cookie_help.html
+share/lynx/lynx_help/keystrokes/dired_help.html
+share/lynx/lynx_help/keystrokes/edit_help.html
+share/lynx/lynx_help/keystrokes/follow_help.html
+share/lynx/lynx_help/keystrokes/gopher_types_help.html
+share/lynx/lynx_help/keystrokes/history_help.html
+share/lynx/lynx_help/keystrokes/keystroke_help.html
+share/lynx/lynx_help/keystrokes/movement_help.html
+share/lynx/lynx_help/keystrokes/option_help.html
+share/lynx/lynx_help/keystrokes/other_help.html
+share/lynx/lynx_help/keystrokes/print_help.html
+share/lynx/lynx_help/keystrokes/scrolling_help.html
+share/lynx/lynx_help/keystrokes/visited_help.html
+share/lynx/lynx_help/keystrokes/xterm_help.html
+share/lynx/lynx_help/lynx-dev.html
+share/lynx/lynx_help/lynx_help_main.html
+share/lynx/lynx_help/lynx_url_support.html
+@dirrm share/lynx/lynx_help/keystrokes
+@dirrm share/lynx/lynx_help
+@dirrm share/lynx/lynx_doc/samples
+@dirrm share/lynx/lynx_doc/test
+@dirrm share/lynx/lynx_doc
--- /usr/pkgsrc/www/lynx/patches/patch-aa.orig Tue Mar 16 20:47:22 1999
+++ /usr/pkgsrc/www/lynx/patches/patch-aa Tue Mar 16 20:47:22 1999
@@ -0,0 +1,40 @@
+$NetBSD$
+
+--- userdefs.h.orig Sat Oct 24 11:49:07 1998
++++ userdefs.h Sun Mar 14 06:53:39 1999
+@@ -269,7 +269,7 @@
+ #ifdef DOSPATH
+ #define LYNX_CFG_FILE "./lynx.cfg"
+ #else
+-#define LYNX_CFG_FILE "/usr/local/lib/lynx.cfg"
++#define LYNX_CFG_FILE "/usr/pkg/share/lynx/lynx.cfg"
+ #endif /* DOSPATH */
+ #endif /* LYNX_CFG_FILE */
+ #endif /* HAVE_CONFIG_H */
+@@ -280,7 +280,7 @@
+ * These global and personal files override anything in
+ * lynx.cfg or src/HTInit.c
+ */
+-#define GLOBAL_EXTENSION_MAP "/usr/local/lib/mosaic/mime.types"
++#define GLOBAL_EXTENSION_MAP "/usr/pkg/etc/mime.types"
+ #define PERSONAL_EXTENSION_MAP ".mime.types"
+
+ /**************************
+@@ -289,7 +289,7 @@
+ * These global and personal files override anything in
+ * lynx.cfg or src/HTInit.c
+ */
+-#define GLOBAL_MAILCAP "/usr/local/lib/mosaic/mailcap"
++#define GLOBAL_MAILCAP "/usr/pkg/etc/mailcap"
+ #define PERSONAL_MAILCAP ".mailcap"
+
+ /**************************
+@@ -408,7 +408,7 @@
+ * -lss command line switch will override these definitions.
+ */
+ #ifndef LYNX_LSS_FILE
+-#define LYNX_LSS_FILE "/usr/local/lib/lynx.lss"
++#define LYNX_LSS_FILE "/usr/pkg/etc/lynx.lss"
+ #endif /* LYNX_LSS_FILE */
+
+ #endif /* VMS OR UNIX */
--- /usr/pkgsrc/www/lynx/Makefile.orig Tue Mar 16 20:45:21 1999
+++ /usr/pkgsrc/www/lynx/Makefile Tue Mar 16 20:47:22 1999
@@ -10,13 +10,32 @@
MAINTAINER= packages@netbsd.org
HOMEPAGE= http://sol.slcc.edu/lynx/
+.include "../../mk/bsd.prefs.mk"
+
+.if defined(USE_SSLEAY)
+PATCH_SITES= http://www.moxienet.com/lynx/
+PATCHFILES= lynx-281-ssl.patch.gz
+PATCH_DIST_ARGS= ${WRKSRC}/WWW/Library/Implementation/HTAAUtil.c
+PATCH_DIST_ARGS+= + ${WRKSRC}/WWW/Library/Implementation/HTFormat.c
+PATCH_DIST_ARGS+= + ${WRKSRC}/WWW/Library/Implementation/HTNews.c
+PATCH_DIST_ARGS+= + ${WRKSRC}/WWW/Library/Implementation/HTTP.c
+PATCH_DIST_ARGS+= + ${WRKSRC}/makefile.in
+
+DEPENDS+= ssleay-0.9.0b:../../security/ssleay
+.endif
+
DEPENDS+= libslang-1.2.2:../../devel/libslang
+.if defined(USE_SSLEAY) && defined(USE_RSAREF2) && ${USE_RSAREF2} == YES
+MAKE_ENV+= RSAREFLIB="-lrsaref"
+.endif
+
GNU_CONFIGURE= YES
-CONFIGURE_ARGS+= --with-screen=slang --with-zlib --libdir="${PREFIX}/etc"
-# see if PASSIVE_FETCH is defined in /etc/mk.conf. If so compile
-# with the ftp code set to passive mode (-DNOPORT)
-.include "../../mk/bsd.prefs.mk"
+
+CONFIGURE_ARGS+= --with-screen=slang --with-zlib --libdir="${PREFIX}/share/lynx"
+.if defined(KEEP_COOKIES)
+CONFIGURE_ARGS+= --enable-persistent-cookies
+.endif
.if defined(PASSIVE_FETCH)
CONFIGURE_ENV+= LIBS="-lm -ltermcap" CPPFLAGS="-Dunix -DNOPORT"
@@ -24,10 +43,11 @@
CONFIGURE_ENV+= LIBS="-lm -ltermcap" CPPFLAGS=-Dunix
.endif
-INSTALL_TARGET= install install-help
+INSTALL_TARGET= install install-help install-doc
MAKEFILE= makefile
post-install:
- chown -R ${SHAREOWN}:${SHAREGRP} ${PREFIX}/etc/lynx_help
+ chown -R ${SHAREOWN}:${SHAREGRP} ${PREFIX}/share/lynx/lynx_help
+ chown -R ${SHAREOWN}:${SHAREGRP} ${PREFIX}/share/lynx/lynx_doc
.include "../../mk/bsd.pkg.mk"
--- /usr/pkgsrc/www/lynx/scripts/post-patch.orig Tue Mar 16 20:47:23 1999
+++ /usr/pkgsrc/www/lynx/scripts/post-patch Tue Mar 16 20:47:23 1999
@@ -0,0 +1,24 @@
+#!/bin/sh
+#
+# $NetBSD$
+#
+if ! [ -f ${WRKSRC}/makefile.in.orig ]; then
+ exit
+fi
+mv ${WRKSRC}/makefile.in.orig ${WRKSRC}/makefile.in.dist
+sed 's/^PATCH//' << 'END-PATCH' | patch -d ${WRKSRC}
+PATCH--- makefile.in.orig Tue Mar 16 13:55:03 1999
+PATCH+++ makefile.in Tue Mar 16 14:25:02 1999
+PATCH@@ -65,8 +65,8 @@
+PATCH # libraries in SSL_LIBS and the location of ssl.h and crypto.h in
+PATCH # SSL_DEFINES if necessary. Defining USE_SSL below will create a binary
+PATCH # which supports "https" and "snews" URLs.
+PATCH-SSL_LIBS= -L/usr/local/ssl/lib -lssl -lcrypto
+PATCH-SSL_DEFINES= -I/usr/local/ssl/include -DUSE_SSL
+PATCH+SSL_LIBS= -L${prefix}/lib -lssl -lcrypto ${RSAREFLIB}
+PATCH+SSL_DEFINES= -I${prefix}/include/ssleay -DUSE_SSL
+PATCH
+PATCH # !!!!!!!!!!! SUN resolv LIBRARY !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+PATCH # To include resolv in the LIBS="" list for SUN 3, 4 or Solaris OS,
+END-PATCH
+exit
>Audit-Trail:
>Unformatted: