From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Richard Todd Newsgroups: gmane.lisp.guile.devel Subject: PATCH for guile-readline/Makefile.am Date: Wed, 7 Jan 2004 15:56:37 -0600 Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Message-ID: <20040107215637.GA5971@pazuzu> Reply-To: Richard Todd NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0114064210==" X-Trace: sea.gmane.org 1073513218 19196 80.91.224.253 (7 Jan 2004 22:06:58 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 7 Jan 2004 22:06:58 +0000 (UTC) Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Wed Jan 07 23:06:46 2004 Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AeLp7-0001ML-00 for ; Wed, 07 Jan 2004 23:06:45 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AeMma-0000G6-P3 for guile-devel@m.gmane.org; Wed, 07 Jan 2004 18:08:12 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.24) id 1AeMfI-000711-Es for guile-devel@gnu.org; Wed, 07 Jan 2004 18:00:40 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.24) id 1AeMeT-0006Yo-9R for guile-devel@gnu.org; Wed, 07 Jan 2004 18:00:21 -0500 Original-Received: from [66.171.59.140] (helo=smtp.vzavenue.net) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AeMdQ-00065V-AM for guile-devel@gnu.org; Wed, 07 Jan 2004 17:58:44 -0500 Original-Received: from demon.pazuzu.hrn (80.154.171.66.subscriber.vzavenue.net [66.171.154.80]) by smtp.vzavenue.net (Mirapoint Messaging Server MOS 3.2.4-GA) with SMTP id BCI00723; Wed, 7 Jan 2004 16:56:40 -0500 (EST) Original-Received: by demon.pazuzu.hrn (sSMTP sendmail emulation); Wed, 7 Jan 2004 15:56:37 -0600 Original-To: guile-devel@gnu.org User-Agent: Mutt/1.5.4i X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Developers list for Guile, the GNU extensibility library List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: main.gmane.org gmane.lisp.guile.devel:3167 X-Report-Spam: http://spam.gmane.org/gmane.lisp.guile.devel:3167 --===============0114064210== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="KFztAG8eRSV9hGtP" Content-Disposition: inline --KFztAG8eRSV9hGtP Content-Type: multipart/mixed; boundary="UlVJffcvxoiEqYs2" Content-Disposition: inline --UlVJffcvxoiEqYs2 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Please consider the following patch for inclusion in guile. Problem: The guile-readline/Makefile unconditionally removes and remakes a link from ice-9/readline.scm to ../readline.scm. There are two problems with this: 1) When you run, say, 'sudo make install', the link is remade as root! 2) When you run a VPATH build, ../readline.scm does not exist. You'd only notice (2) if you wanted to test (ice-9 readline) prior to installation. You notice (1) quite often if you want to remove your build tree, or even if you 'sudo make install' and then 'make' as a normal user again. The patch fixes both these issues. It was a bit tricky, and I could not find a single 'ln -s' line that worked for both in-tree builds and VPATH builds (it's harder than it sounds!). The patch just does an 'if' on $(top_srcdir) == $(top_builddir) and issues the correct command. If you don't like this method and can find a better way, please do so, because we need a change to this file! thanks, Richard Todd --UlVJffcvxoiEqYs2 Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="rdln.patch" Content-Transfer-Encoding: quoted-printable --- orig/guile-core/guile-readline/ChangeLog +++ mod/guile-core/guile-readline/ChangeLog @@ -1,3 +1,9 @@ +2004-01-07 Richard Todd + + * Makefile.am (ice-9/readline.scm): link to $srcdir, so VPATH builds=20 + work. Make the link depend on the source file, so that it doesn't=20 + get re-made as a root link during 'sudo make install', for instance. + 2003-05-04 Marius Vollmer =20 * configure.in: When checking whether readline clears SA_RESTART, --- orig/guile-core/guile-readline/Makefile.am +++ mod/guile-core/guile-readline/Makefile.am @@ -57,11 +57,15 @@ =20 CLEANFILES =3D *.x =20 -ice-9/readline.scm: +ice-9/readline.scm: readline.scm -rm ice-9/readline.scm -rmdir ice-9 mkdir ice-9 - cd ice-9 && ln -s ../readline.scm + if [ "$(top_srcdir)" =3D=3D "$(top_builddir)" ] ; then \ + (cd ice-9 && $(LN_S) ../$<) \ + else \ + (cd ice-9 && $(LN_S) $<) \ + fi =20 all-local: ice-9/readline.scm =20 --UlVJffcvxoiEqYs2-- --KFztAG8eRSV9hGtP Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.3 (GNU/Linux) iD8DBQE//ICVa9lhNGIqsRIRAuJWAJ9o1b/9/+3MOg3WRkm+fla2fGpYfACgoiaA TSgUHmhwB2EQ4t4P8qlfOQs= =Te4q -----END PGP SIGNATURE----- --KFztAG8eRSV9hGtP-- --===============0114064210== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Guile-devel mailing list Guile-devel@gnu.org http://mail.gnu.org/mailman/listinfo/guile-devel --===============0114064210==--