-
Notifications
You must be signed in to change notification settings - Fork 551
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Configure shouldn't write source tree #13712
Comments
From afresh1@openbsd.orgCreated by afresh1@openbsd.orgOpenBSD installs perl using an build directory, not directly in the source This is a local patch we are using with perl 5.18.2, but it should be able to The patch is against bleed. Perl Info
|
From afresh1@openbsd.org0001-Don-t-let-Configure-write-to-the-src-tree.patchFrom 99ecece5ba3e330bc54ea4fb1ee3bc13ad66f2aa Mon Sep 17 00:00:00 2001
From: Andrew Fresh <afresh1@openbsd.org>
Date: Sat, 29 Mar 2014 15:33:33 -0700
Subject: [PATCH] Don't let Configure write to the src tree
In OpenBSD perl is built with a read-only source tree. This was writing
temp files into that part of the tree.
This keeps the tempfiles in the writable obj directory.
---
Configure | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/Configure b/Configure
index 15b3da1..7f22025 100755
--- a/Configure
+++ b/Configure
@@ -22384,8 +22384,8 @@ find_extensions='
Scalar/List/Utils) this_ext="List/Util" ;;
PathTools) this_ext="Cwd" ;;
esac;
- echo " $xs_extensions $nonxs_extensions" > $$.tmp;
- if $contains " $this_ext " $$.tmp; then
+ echo " $xs_extensions $nonxs_extensions" > $tdir/$$.tmp;
+ if $contains " $this_ext " $tdir/$$.tmp; then
echo >&4;
echo "Duplicate directories detected for extension $xxx" >&4;
echo "Configure cannot correctly recover from this - shall I abort?" >&4;
@@ -22403,15 +22403,15 @@ find_extensions='
esac;
echo "Ok. You will need to correct config.sh before running make." >&4;
fi;
- $ls -1 $xxx > $$.tmp;
- if $contains "\.xs$" $$.tmp > /dev/null 2>&1; then
+ $ls -1 $xxx > $tdir/$$.tmp;
+ if $contains "\.xs$" $tdir/$$.tmp > /dev/null 2>&1; then
xs_extensions="$xs_extensions $this_ext";
- elif $contains "\.c$" $$.tmp > /dev/null 2>&1; then
+ elif $contains "\.c$" $tdir/$$.tmp > /dev/null 2>&1; then
xs_extensions="$xs_extensions $this_ext";
elif $test -d $xxx; then
nonxs_extensions="$nonxs_extensions $this_ext";
fi;
- $rm -f $$.tmp;
+ $rm -f $tdir/$$.tmp;
;;
esac;
done'
--
1.8.5.3
|
From @avarOn Sat, Apr 5, 2014 at 11:45 PM, via RT <perlbug-followup@perl.org> wrote:
How do you build against a read-only source tree? Are you using some Sure it seems that we should use the $tdir there, but I don't get how ./Configure .. && make -j 10 test_harness While running this in another window, which only gives the *untracked* while true; do git status --porcelain | tee -a /tmp/dirty.txt; done And after that I get: $ sort /tmp/dirty.txt |uniq -c|sort -nr|wc -l I.e. 450 unique untracked dirty files (full list attached). A lot of Or am I mistunderstanding what you're doing here? |
From @avar 1896 ?? dist/IO/io_utf8 |
The RT System itself - Status changed from 'new' to 'open' |
From andrew@afresh1.comOn Sun, Apr 06, 2014 at 02:08:44PM -0700, AEvar Arnfj"ord Bjarmason via RT wrote:
The general idea is that we create an "obj" directory, symlink the files See Makefile.bsdwrapper which ends up including the relevant target from bsd.obj.mk You might be interested in trying it out, but this is unlikely to work While we could likely change Configure to look in $tdir/{cpan,dist,ext} l8rZ, What are the unsurpassable real world weaknesses in OpenBSD, |
From afresh1@openbsd.orgOn Sun, Apr 06, 2014 at 02:08:44PM -0700, AEvar Arnfj"ord Bjarmason via RT wrote:
The general idea is that we create an "obj" directory, symlink the files See Makefile.bsdwrapper which ends up including the relevant target from bsd.obj.mk You might be interested in trying it out, but this is unlikely to work While we could likely change Configure to look in $tdir/{cpan,dist,ext} l8rZ, The power!!!! The nightmares!!!! The strange medication!!!!!!!! |
From afresh1@openbsd.orgOn Sun, Apr 06, 2014 at 02:08:44PM -0700, AEvar Arnfj"ord Bjarmason via RT wrote:
The general idea is that we create an "obj" directory, symlink the files See Makefile.bsdwrapper which ends up including the relevant target from bsd.obj.mk You might be interested in trying it out, but this is unlikely to work While we could likely change Configure to look in $tdir/{cpan,dist,ext} l8rZ, What are the unsurpassable real world weaknesses in OpenBSD, |
From @doughera88On Sun, Apr 06, 2014 at 08:52:35PM -0700, Andrew Fresh wrote:
Good catch. I build all the time using Configure -Dmksymlinks, which Though I haven't tested it myself, your patch looks good. -- |
From @TuxOn Mon, 7 Apr 2014 07:17:24 -0400, Andy Dougherty
I agree, but I think it is beyond code-freeze and will have to wait for -- |
From andrew@afresh1.comWhat's the proper way to bump this ticket now that 5.21 is available to On Mon, Apr 07, 2014 at 01:27:32PM +0200, H.Merijn Brand wrote:
-- People who invent random theories which only defend the vendor must have |
From @TuxOn Tue, 10 Jun 2014 22:47:34 -0700, Andrew Fresh <andrew@afresh1.com>
Replying like this is :) Committed in d611994
-- |
From @tonycozOn Wed Jun 11 00:46:55 2014, hmbrand wrote:
So closing the ticket. Tony |
@tonycoz - Status changed from 'open' to 'resolved' |
Migrated from rt.perl.org#121585 (status was 'resolved')
Searchable as RT121585$
The text was updated successfully, but these errors were encountered: