This bug includes notes on how to get Prefix fully running on OS X 10.8 Mountain Lion. Reproducible: Always
Created attachment 319612 [details] 10.8 Installation Notes
If you need additional info, and testing for fixed things, I'm glad to help (hachre on irc.freenode.net #gentoo-prefix)
Hmm, so I gather that two major things will help: 1) package md.c and install it 2) figure out that CHOST switching thing Also, why do you need to set PYTHONPATH. We already do that in bootstrap-prefix.sh: # Set correct PYTHONPATH for Portage, since our Python lives in # $EPREFIX/tmp, bug #407573 echo "PYTHONPATH=${ROOT}/usr/lib/portage/pym" >> "${profile}"/make.defaults
I guess it is because I had to manually create the make.profile symlink and create my own 10.8 profile the way I did? Not entirely sure... I'll try to figure it out and get back to you.
Ok, yea. I hinted at that in IRC. The first step for 10.8 support should be: 1) Create 10.8 profile by renaming 10.7 2) Test that bootstrap-prefix.sh uses the 10.8 profile 3) Edit/modify 10.8 profile as needed. If you can confirm 1) & 2) - that is a good first step and we can commit that (I've been waiting for someone to report this from everyone that I talk to).
Will do!
Created attachment 319726 [details, diff] Patch to include 10.8 in bootstrap-prefix.sh
This patch together with copying the 10.7 profile to 10.8 and editing the following files to update the version or CHOST correctly installed the profile: profiles/prefix/darwin/macos/10.8: make.defaults profile.bashrc x64/make.defaults x86/make.defaults More testing results coming soon!
Created attachment 319780 [details] 10.8 Installation Notes Revision 1
Some things have been fixed through the new profile thing, others have not. The new attachment represents that current state of how things are working.
that CHOST hack hints are some libtool fix waiting to be made, and need for elibtoolize/ELT-patch
oh, and someone should add the 10.8 profile for you + bootstrap script support, before I get to it
bootstrap-prefix.sh done (warning, profiles not added yet)
Profiles added to CVS.
Fabian, do you know why the bootstrap-macos.xml guide has the user install readline? Was it an oversight from when bash grew the readline USE flag? Note: I added USE=-readline to bootstrap-prefix.sh some time ago, so I feel like macos has this readline stuff by error now.
revision 1.70 date: 2012-06-30 20:09:55 +0200; author: grobian; state: Exp; lines: +4 -3; commitid: 70284fef40f34567; Fix bootstrapping of bash if it has -readline these days, I think it can go
(In reply to comment #16) > revision 1.70 > date: 2012-06-30 20:09:55 +0200; author: grobian; state: Exp; lines: +4 > -3; commitid: 70284fef40f34567; > Fix bootstrapping of bash > > if it has -readline these days, I think it can go Yea, I did that some time ago. ------------------------------------------------------------------------ r61050 | darkside | 2012-07-09 10:13:33 -0500 (Mon, 09 Jul 2012) | 1 line disable USE=readline since that is fragile when initially installing bash (bash needs readline, readline needs ncurses) ------------------------------------------------------------------------ So, we see a divergance of the guides by both of us. You preferred to fix macos guide (and not solaris) and I fixed the solaris guide (via bootstrap-prefix.sh) but didn't look at macos guide. :)
(In reply to comment #17) > So, we see a divergance of the guides by both of us. You preferred to fix > macos guide (and not solaris) and I fixed the solaris guide (via > bootstrap-prefix.sh) but didn't look at macos guide. :) :) Heads up, I did some major work on bootstrap-prefix.sh. I dropped all versions, each target tries all versions we know until one succeeds. Next step is to make a function to perform all the initial packages to bootstrap based on CHOST. This way, we put all the knowledge in the script. (yes, I've started to change my mind on education/understanding/etc.)
Great, I'm excited :) Can't wait to try it out!
Modified: bootstrap-macos.xml bootstrap-solaris.xml Log: try to create some synergy wrt bash in the bootstrap instructions
I'm running a bootstrap with the new bootstrap-prefix script and the edited guide with a latest-tree to see what issues remain now atm. I will post once I have results!
(In reply to comment #3) > Hmm, so I gather that two major things will help: > 1) package md.c and install it This is now available in the main tree as sys-devel/md. I am the maintainer.
which md is that? wasn't it a bit more sensical to just include this in darwin-miscutils?
(In reply to comment #23) > which md is that? wasn't it a bit more sensical to just include this in > darwin-miscutils? It is the following md: http://www.opensource.apple.com/source/adv_cmds/adv_cmds-147/md/ It would be less hassle to have a separate ebuild. The GNU project will eventually patch binutils' build system so that it no longer needs this tool. If we want to eliminate the separate ebuild, patching binutils for upstream would probably be better than moving this into sys-apps/darwin-miscutils.
I don't understand. md seems to be necessary on a Mac, on Linux I don't have md (besides md being used by the compiler, isn't it?) so isn't it just another "darwin" tool then? It's obviously an Apple tool... and my gx86 cvs tree has no sys-devel/md
(In reply to comment #25) > I don't understand. > > md seems to be necessary on a Mac, on Linux I don't have md > > (besides md being used by the compiler, isn't it?) > > so isn't it just another "darwin" tool then? It's obviously an Apple tool... This appears to be a tool that Darwin inherited from Carnegie Mellon's Mach. The man page says that it processes "raw dependency files produced by cpp -MD". The build system should require this functionality on all platforms. Using a platform-specific tool to do it only makes sense if no one cared enough to make the behavior consistent. Upstream needs to change this now that md is no longer provided on Mac OS X 10.8. If they do not, they will no longer be able to claim Mac OS X as a supported platform. > and my gx86 cvs tree has no sys-devel/md Update your CVS checkout. I committed the ebuild today in response to popular demand on IRC.
(In reply to comment #26) > (In reply to comment #25) > > I don't understand. > > > > md seems to be necessary on a Mac, on Linux I don't have md > > > > (besides md being used by the compiler, isn't it?) > > > > so isn't it just another "darwin" tool then? It's obviously an Apple tool... > > This appears to be a tool that Darwin inherited from Carnegie Mellon's Mach. > The man page says that it processes "raw dependency files produced by cpp > -MD". The build system should require this functionality on all platforms. > Using a platform-specific tool to do it only makes sense if no one cared > enough to make the behavior consistent. Upstream needs to change this now > that md is no longer provided on Mac OS X 10.8. If they do not, they will no > longer be able to claim Mac OS X as a supported platform. You DO realise that you're on thin ice, right? OSX doesn't come with a GCC compiler any more. > > and my gx86 cvs tree has no sys-devel/md > > Update your CVS checkout. I committed the ebuild today in response to > popular demand on IRC. Seems I'm not the only one who hasn't got it: http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/sys-devel/md
anyway, it's in darwin-miscutils-10 now
(In reply to comment #27) > Seems I'm not the only one who hasn't got it: > http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/sys-devel/md You can tell that I do not commit new packages very often. I failed to `cvs add` the new directory. Anyway, lets forget about sys-devel/md.
Created attachment 320296 [details] 10.8 Installation Notes Revision 2 Noteable changes: This was run on latest-tree from August 2nd using the new bootstrap-prefix script. * bash is no longer masked in my solution, instead =p10 is emerged in the first step and then later updated to p36 because at that point it compiles fine. * binutils still requires md because the recent changes in this area were introduced after my testing had already started. * a new problem occurs if tar tries to extract a bzip2 archive, missing a library that is simply misnamed, solution was to symlink to the expected name. * we still have the glibc compile error not finding libiffi unless PKG_CONFIG_PATH is specified * we still have the CHOST switching requirements
Grobian, fyi, I tested your stages and got to stage3 where it died on the same bash issue that has been mentioned in my Installation Notes. I'm not sure what the preferred method is to manually intervene here so I stopped there.
I fixed some bugs in stage3 now, and an older bash is used there. Currently running on Darwin9 (Leopard), will see where I end up today.
bootstrap attempt failed. The commit regarding readline broke bash, but we work around that now. But it also broke more intense, due to pax-utils being emerged too late. I'm currently running stage{1,2,3} + emerge -e system with a moved up pax-utils to see if that works.
I've been doing the same thing, will be done in about two hours or so on Mountain Lion.
I appear to have success now
One thing I can mention right off the bat: md isn't handled by the guide and binutils still fails because it's missing, you have to manually emerge darwin-miscutils to make it work on Mountain Lion.
I just added that to stage3
Well then the only thing missing for Mountain Lion at this point seems to be the CHOST problem for readline and gettext. All the other issues have been addressed, my current test is far in the emerge -e system state already and I'd say it will run through.
Created attachment 320908 [details] 10.8 Installation Notes Revision 3 Describes the last outstanding issues as of now.
Opened bug #430848 for the gettext chost problem which blocks this bug.
Opened bug #430860 for the readline chost problem which blocks this bug.
Gonna do a new bootstrap tonight!
you need latest tree, so perform stage2 manually Going to bump the snapshot now (Darwin/Solaris fixes)!
The bootstrap was a full success, not a single issue - yes I manually did latest_tree! But great result: 0 issues!
Created attachment 321144 [details] 10.8 Installation Notes Revision 4
Ok, very cool. I hope you would like to try my interactive installer that I'm about to commit this afternoon. It should do exactly as you did, so be a success too!
Sure thing, let me know when it's ready :)
A couple quick questions: in the installation notes (rev. 4), it says to "follow the instructions at: http://www.gentoo.org/proj/en/gentoo-alt/prefix/bootstrap-solaris.xml" First, since the "Code Listing 1.7: emerge bash" command on that page still fails, should I assume we should only run the $ ./bootstrap-prefix.sh $EPREFIX/tmp make ... $ ./bootstrap-prefix.sh $EPREFIX/tmp python and $ ./bootstrap-prefix.sh $EPREFIX tree $ ./bootstrap-prefix.sh $EPREFIX portage portions before bootstrapping stage 1/2/3? (building stage3 now, btw) Second, is http://www.gentoo.org/proj/en/gentoo-alt/prefix/bootstrap-macos.xml obsolete? Is it only a subset of bootstrap-solaris.xml (which also addresses OSX)?
a) My guide doesn't fully cover the current way to get it working because it was a test run mainly to see if the last remaining bugs had been fixed. The instructions are only a fallback by now and not a requirement anymore. In a perfect world all you would need to run is: ./bootstrap-script.sh $EPREFIX/tmp stage1 ./bootstrap-script.sh $EPREFIX/tmp stage2 ./bootstrap-script.sh $EPREFIX/tmp stage3 emerge -e system Right now - because the newest fixes aren't yet in a release tree - you need to run the stage2 part manually, as described in the script, and use latest_tree instead of tree. Stage2 is what the solaris guide does in code listings 1.4 and 1.5. b) I believe the OSX guide is merged into to solaris guide and obsolete, yes
Make sure you have the latest bootstrap-prefix script, bash should not fail at this point!
Created attachment 321156 [details] 10.8 Installation Notes Revison 4.1 Revision to the 4.0 version, making some things more clear.
Made a mistake in my previous listing which is corrected below, also please see the new Revision 4.1 for more clear instructions on how to do this right now. (In reply to comment #49) > ./bootstrap-script.sh $EPREFIX/tmp stage1 > ./bootstrap-script.sh $EPREFIX stage2 > ./bootstrap-script.sh $EPREFIX stage3 > emerge -e system
(In reply to comment #52) > Made a mistake in my previous listing which is corrected below, also please > see the new Revision 4.1 for more clear instructions on how to do this right > now. > > (In reply to comment #49) > > ./bootstrap-script.sh $EPREFIX/tmp stage1 > > ./bootstrap-script.sh $EPREFIX stage2 > > ./bootstrap-script.sh $EPREFIX stage3 > > emerge -e system Or, IMO much better/easier/fool-proof: ./bootstrap-prefix.sh and the script will try to get you where you want to go today.
I gotta say the new bootstrap script is great comedy ;D
Running with the new fully automated script. Works like a charm. I'm in 'emerge -e system' and not a single issue so far. Looking good :)
The automated bootstrap worked like a charm :) I consider this bug fixed!
Created attachment 321384 [details] 10.8 Installation Notes Revision 5
very cool! that reduces your instructions to install xcode, download the script and run it.