From flynn@isengard.energyhq.tk  Fri Apr 25 01:21:33 2003
Return-Path: <flynn@isengard.energyhq.tk>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 1EEA737B401
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 25 Apr 2003 01:21:33 -0700 (PDT)
Received: from isengard.energyhq.tk (213-97-200-73.uc.nombres.ttd.es [213.97.200.73])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 5EE2F43FAF
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 25 Apr 2003 01:21:29 -0700 (PDT)
	(envelope-from flynn@isengard.energyhq.tk)
Received: from isengard.energyhq.tk (localhost [127.0.0.1])
	by isengard.energyhq.tk (8.12.6p2/8.12.6) with ESMTP id h3P8LcF7040012
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 25 Apr 2003 10:21:39 +0200 (CEST)
	(envelope-from flynn@isengard.energyhq.tk)
Received: (from flynn@localhost)
	by isengard.energyhq.tk (8.12.6p2/8.12.6/Submit) id h3P8Lbf3040011;
	Fri, 25 Apr 2003 10:21:37 +0200 (CEST)
Message-Id: <200304250821.h3P8Lbf3040011@isengard.energyhq.tk>
Date: Fri, 25 Apr 2003 10:21:37 +0200 (CEST)
From: Miguel Mendez <flynn@energyhq.homeip.net>
Reply-To: Miguel Mendez <flynn@energyhq.homeip.net>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: Add linprocfs mount check to emulators/linux_base
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         51406
>Category:       ports
>Synopsis:       Add linprocfs mount check to emulators/linux_base
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Fri Apr 25 01:30:13 PDT 2003
>Closed-Date:    Wed Jul 23 22:41:53 PDT 2003
>Last-Modified:  Wed Jul 23 22:41:53 PDT 2003
>Originator:     Miguel Mendez
>Release:        FreeBSD 5.0-RELEASE-p7 i386
>Organization:
>Environment:
System: FreeBSD isengard.energyhq.tk 5.0-RELEASE-p7 FreeBSD 5.0-RELEASE-p7 #0: Fri Apr 11 10:51:38 CEST 2003 root@isengard.energyhq.tk:/usr/obj/usr/src/sys/ISENGARD i386


	
>Description:
If one has linux_base and linprofcs mounted and tries to portupgrade it,
cpio will fail in /compat/linux/proc. This little patch makes it possible
to portupgrade linux_base if linprocfs is mounted.
>How-To-Repeat:
	
>Fix:

	

--- linux_base.diff begins here ---
diff -ruN linux_base.old/Makefile linux_base/Makefile
--- linux_base.old/Makefile	Wed Apr  9 04:05:12 2003
+++ linux_base/Makefile	Fri Apr 25 09:54:29 2003
@@ -165,6 +165,7 @@
 	@${LN} -sf /var/tmp ${LINUXBASE}/usr/tmp
 
 post-install:
+	@${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
 	@${ECHO} ''
 	@fmt ${PKGMESSAGE}
 	@${ECHO} ''
diff -ruN linux_base.old/pkg-install linux_base/pkg-install
--- linux_base.old/pkg-install	Tue Aug 22 01:43:25 2000
+++ linux_base/pkg-install	Fri Apr 25 10:06:53 2003
@@ -11,7 +11,18 @@
 			echo 'Please enable linux mode manually and retry.'
 			exit 1
 		fi
+# Make sure linprocfs is not mounted so we can portupgrade this
+#
 	fi
+		echo "------------------------------------------------------------"
+		echo "Note: /compat/linux/proc will be umounted for the install..."
+		echo "------------------------------------------------------------"
+		/sbin/mount|grep linproc>/dev/null \
+			&& /sbin/umount /compat/linux/proc
+	;;
+
+POST-INSTALL)
+	mount_linprocfs linproc /compat/linux/proc
 	;;
 esac
 
--- linux_base.diff ends here ---


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: daichi 
State-Changed-When: Wed Jul 23 22:40:59 PDT 2003 
State-Changed-Why:  
The same treatment is committed. Please check it. Thanks! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=51406 
>Unformatted:
