Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 18 Jan 1999 19:03:41 +0200 (SAT)
From:      reg@shale.csir.co.za
To:        FreeBSD-gnats-submit@FreeBSD.ORG
Subject:   ports/9556: Unbreak devel/ncurses
Message-ID:  <199901181703.TAA37641@shale.csir.co.za>

next in thread | raw e-mail | index | archive | help

>Number:         9556
>Category:       ports
>Synopsis:       Unbreak devel/ncurses
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jan 18 09:10:00 PST 1999
>Closed-Date:
>Last-Modified:
>Originator:     Jeremy Lea
>Release:        FreeBSD 3.0-CURRENT i386
>Organization:
Arb's Inc.
>Environment:

	Ports Collection.

>Description:

	This patch unbreaks the devel/ncurses port for both aout and ELF. 
	Two new patches (patch-aa and patch-ab) need to be imported.

>How-To-Repeat:

	Hopefully only needs doing once... :)

>Fix:
	
	
diff -urN ncurses.old/Makefile ncurses/Makefile
--- ncurses.old/Makefile	Tue Oct  6 09:35:03 1998
+++ ncurses/Makefile	Mon Jan 18 18:47:47 1999
@@ -13,8 +13,6 @@
 
 MAINTAINER=		andy@icc.surw.chel.su
 
-BROKEN=	runs ldconfig without arguments
-
 MAN1=	captoinfo.1m clear.1 infocmp.1m tic.1m toe.1m tput.1 tset.1
 MAN3=	curs_addch.3x curs_addchstr.3x curs_addstr.3x curs_attr.3x \
 	curs_beep.3x curs_bkgd.3x curs_border.3x curs_clear.3x \
@@ -48,10 +46,18 @@
 GNU_CONFIGURE=		yes
 CONFIGURE_ARGS=	--datadir=${PREFIX}/share/misc --disable-overwrite \
 		--disable-termcap --includedir=${PREFIX}/include/ncurses \
-		--prefix=${PREFIX} --with-profile --with-shared --with-debug
-CONFIGURE_ENV=		gnat_exists="no"
+		--prefix=${PREFIX} --with-profile --with-shared
+CONFIGURE_ENV=		gnat_exists="no" ac_cv_path_LDCONFIG="/usr/bin/env OBJFORMAT=${PORTOBJFORMAT} /sbin/ldconfig -m ${PREFIX}/lib"
+
+.include <bsd.port.pre.mk>
 
 post-install:
+.if ${PORTOBJFORMAT} == "aout"
+	@ ${LN} -sf ${PREFIX}/lib/libform.so.4.2 ${PREFIX}/lib/libform.so
+	@ ${LN} -sf ${PREFIX}/lib/libmenu.so.4.2 ${PREFIX}/lib/libmenu.so
+	@ ${LN} -sf ${PREFIX}/lib/libncurses.so.4.2 ${PREFIX}/lib/libncurses.so
+	@ ${LN} -sf ${PREFIX}/lib/libpanel.so.4.2 ${PREFIX}/lib/libpanel.so
+.endif
 	@ ${MKDIR} ${PREFIX}/share/doc/ncurses
 .for file in ANNOUNCE INSTALL NEWS README TO-DO announce.html misc/hackguide.doc misc/hackguide.html misc/ncurses-intro.doc misc/ncurses-intro.html
 	@ ${INSTALL_DATA} ${WRKSRC}/${file} ${PREFIX}/share/doc/ncurses
@@ -69,4 +75,4 @@
 .endfor
 	@ ${INSTALL_DATA} ${FILESDIR}/Makefile.c++ ${PREFIX}/share/examples/ncurses/c++/Makefile
 
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
diff -urN ncurses.old/patches/patch-aa ncurses/patches/patch-aa
--- ncurses.old/patches/patch-aa	Thu Jan  1 02:00:00 1970
+++ ncurses/patches/patch-aa	Mon Jan 18 18:54:30 1999
@@ -0,0 +1,71 @@
+--- configure.orig	Fri Feb 13 01:46:01 1998
++++ configure	Mon Jan 18 18:54:10 1999
+@@ -2108,8 +2108,14 @@
+ 	profile) DFT_DEP_SUFFIX='_p.a' ;;
+ 	shared)
+ 		case $cf_cv_system_name in
+-		openbsd*|netbsd*|freebsd*)
++		openbsd*|netbsd*)
+ 			DFT_DEP_SUFFIX='.so.$(REL_VERSION)' ;;
++		freebsd*)
++			if [ `test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` = elf ]; then
++				DFT_DEP_SUFFIX='.so'
++			else
++				DFT_DEP_SUFFIX='.so.$(REL_VERSION)'
++			fi ;;
+ 		hpux*)	DFT_DEP_SUFFIX='.sl'  ;;
+ 		*)	DFT_DEP_SUFFIX='.so'  ;;
+ 		esac
+@@ -2224,10 +2230,19 @@
+ 		fi
+ 		cf_cv_do_symlinks=yes
+ 		;;
+-	openbsd*|netbsd*|freebsd*)
++	openbsd*|netbsd*)
+ 		CC_SHARED_OPTS='-fpic -DPIC'
+ 		MK_SHARED_LIB='$(LD) -Bshareable -o $@'
+ 		;;
++	freebsd*)
++		CC_SHARED_OPTS='-fpic -DPIC'
++		if [ `test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` = elf ]; then
++			MK_SHARED_LIB='$(LD) -Bshareable -o $@.$(ABI_VERSION)'
++			cf_cv_do_symlinks=yes
++		else
++			MK_SHARED_LIB='$(LD) -Bshareable -o $@'
++		fi
++		;;
+ 	osf*|mls+*)
+ 		# tested with OSF/1 V3.2 and 'cc'
+ 		# tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't
+@@ -5893,8 +5908,14 @@
+ 	profile) cf_suffix='_p.a' ;;
+ 	shared)
+ 		case $cf_cv_system_name in
+-		openbsd*|netbsd*|freebsd*)
++		openbsd*|netbsd*)
+ 			cf_suffix='.so.$(REL_VERSION)' ;;
++		freebsd*)
++			if [ `test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` = elf ]; then
++				cf_suffix='.so'
++			else
++				cf_suffix='.so.$(REL_VERSION)'
++			fi ;;
+ 		hpux*)	cf_suffix='.sl'  ;;
+ 		*)	cf_suffix='.so'  ;;
+ 		esac
+@@ -5936,8 +5957,14 @@
+ 	profile) cf_suffix='_p.a' ;;
+ 	shared)
+ 		case $cf_cv_system_name in
+-		openbsd*|netbsd*|freebsd*)
++		openbsd*|netbsd*)
+ 			cf_suffix='.so.$(REL_VERSION)' ;;
++		freebsd*)
++			if [ `test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` = elf ]; then
++				cf_suffix='.so'
++			else
++				cf_suffix='.so.$(REL_VERSION)'
++			fi ;;
+ 		hpux*)	cf_suffix='.sl'  ;;
+ 		*)	cf_suffix='.so'  ;;
+ 		esac
diff -urN ncurses.old/patches/patch-ab ncurses/patches/patch-ab
--- ncurses.old/patches/patch-ab	Thu Jan  1 02:00:00 1970
+++ ncurses/patches/patch-ab	Mon Jan 18 18:54:47 1999
@@ -0,0 +1,33 @@
+--- mk-1st.awk.orig	Wed Feb 11 14:13:53 1998
++++ mk-1st.awk	Mon Jan 18 18:54:12 1999
+@@ -56,11 +56,9 @@
+ 	}
+ function sharedlinks(directory, add) {
+ 		if ( end_name != lib_name ) {
+-			abi_name = sprintf("%s.$(ABI_VERSION)", lib_name);
+ 			if (add) {
+ 				printf "\tcd %s && (", directory
+-				symlink(end_name, abi_name);
+-				symlink(abi_name, lib_name);
++				symlink(end_name, lib_name);
+ 				printf ")\n"
+ 			} else {
+ 				printf "\t-@rm -f %s/%s\n", directory, abi_name
+@@ -75,7 +73,7 @@
+ 	}
+ function installed_name() {
+ 		if ( DO_LINKS == "yes" ) {
+-			return sprintf("%s.$(REL_VERSION)", lib_name);
++			return sprintf("%s.$(ABI_VERSION)", lib_name);
+ 		} else {
+ 			return lib_name;
+ 		}
+@@ -136,7 +134,7 @@
+ 			if ( MODEL == "SHARED" )
+ 			{
+ 				if ( DoLinks == "yes" ) {
+-					end_name = sprintf("%s.$(REL_VERSION)", lib_name);
++					end_name = sprintf("%s.$(ABI_VERSION)", lib_name);
+ 				} else {
+ 					end_name = lib_name;
+ 				}
diff -urN ncurses.old/pkg/PLIST ncurses/pkg/PLIST
--- ncurses.old/pkg/PLIST	Sat Aug 29 22:24:34 1998
+++ ncurses/pkg/PLIST	Mon Jan 18 15:57:47 1999
@@ -24,19 +24,23 @@
 include/ncurses/termcap.h
 include/ncurses/unctrl.h
 lib/libform.a
+lib/libform.so
 lib/libform.so.4.2
 lib/libform_g.a
 lib/libform_p.a
 lib/libmenu.a
+lib/libmenu.so
 lib/libmenu.so.4.2
 lib/libmenu_g.a
 lib/libmenu_p.a
 lib/libncurses++.a
 lib/libncurses.a
+lib/libncurses.so
 lib/libncurses.so.4.2
 lib/libncurses_g.a
 lib/libncurses_p.a
 lib/libpanel.a
+lib/libpanel.so
 lib/libpanel.so.4.2
 lib/libpanel_g.a
 lib/libpanel_p.a

>Release-Note:
>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199901181703.TAA37641>