Re: flex-2.5.31
David Jensen wrote: 1. The order of the files in flex-2.5.31-debian_fixes-2.patch may sometimes trigger regenerating scan.c, which causes the build to fail if flex is not already installed. -- Solution: Move the scan.c section of the patch to after the scan.l section. Build and install per the current instructions. OK, see http://www.linuxfromscratch.org/~matthew/flex-2.5.31-debian_fixes-3.patch for the updated patch. I realise Alexander posted another solution, but I'm worried folks get so accustomed to *not* having to use the '-Z' switch, they'll miss it out on this one, then get bitten by what is a pretty obscure error. 2. Now there is a flex installed but it does not incorporate the patched scan.l and flex.skl. -- Solution: touch scan.l flex.skl; ./configure --prefix=/usr; make; make install. the ./configure, again, is required to pick up the newly installed flex, else scan.c is destroyed and it bombs. OK, you've lost me here. If I understand correctly, we've just changed the patch from updating scan.l *after* scan.c to have it update scan.l *before* scan.c so that scan.c doesn't get rebuilt, thus requiring a host-installed flex to be present. Now you're saying that we need scan.c to be rebuilt anyway, so that it includes the patched contents of scan.l? Is there some way we can change the patch so that it changes scan.c only, but includes all the changes from scan.l too? Looking at the two hunks of the patch, this would seem to be trivial enough, but I'm not at all familiar with flex and the whole scanner/grammar stuff to be certain of what to do. 3. The flex++ link has not been created since the switch to 2.5.31. I didn't miss it in nearly a year, but maybe it is supposed to be there. -- Solution: ln -s flex++ /usr/bin/flex Well, that's trivial enough I suppose. I could file a bug. Issue 1 is bug #1506. Regards, Matt. -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
Re: flex-2.5.31
Jim Gifford wrote: Does the problem occur with the -4 patch I posted a while back?? http://www.linuxfromscratch.org/patches/downloads/flex/flex-2.5.31-debian_fixes-4.patch Yes, visual inspection shows the scan.c hunk will be applied before the scan.l hunk Matt. -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
Re: flex-2.5.31
Matthew Burgess wrote: David Jensen wrote: 1. The order of the files in flex-2.5.31-debian_fixes-2.patch may sometimes trigger regenerating scan.c, which causes the build to fail if flex is not already installed. -- Solution: Move the scan.c section of the patch to after the scan.l section. Build and install per the current instructions. OK, see http://www.linuxfromscratch.org/~matthew/flex-2.5.31-debian_fixes-3.patch for the updated patch. I realise Alexander posted another solution, but I'm worried folks get so accustomed to *not* having to use the '-Z' switch, they'll miss it out on this one, then get bitten by what is a pretty obscure error. Great, I'll look at it. 2. Now there is a flex installed but it does not incorporate the patched scan.l and flex.skl. -- Solution: touch scan.l flex.skl; ./configure --prefix=/usr; make; make install. the ./configure, again, is required to pick up the newly installed flex, else scan.c is destroyed and it bombs. OK, you've lost me here. If I understand correctly, we've just changed the patch from updating scan.l *after* scan.c to have it update scan.l *before* scan.c so that scan.c doesn't get rebuilt, thus requiring a host-installed flex to be present. Now you're saying that we need scan.c to be rebuilt anyway, so that it includes the patched contents of scan.l? Is there some way we can change the patch so that it changes scan.c only, but includes all the changes from scan.l too? Yes, but it is huge, see the size of the flex-2.5.31-debian_fixes-4.patch, it is all in there. 924K. It seems easier, perhaps 'more pure' to regenerate locally. -- David Jensen -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
Re: flex-2.5.31
David Jensen wrote: Yes, but it is huge, see the size of the flex-2.5.31-debian_fixes-4.patch, it is all in there. 924K. It seems easier, perhaps 'more pure' to regenerate locally. Wait, there is more in the -4.patch than needed. So it's not that bad, skel.c and scan.c patch is only 152K, and parts of them are already included. Still large though. -- David Jensen -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
Re: flex-2.5.31
Matthew Burgess wrote: I suppose the 20 line scan.l hunk in it is redundant, though it's not going to save that much space in the grand scheme of things. It won't save space, but removing that file from the patch will prevent scan.c from being rebuilt. Which was (part of) the whole point. ;-) signature.asc Description: OpenPGP digital signature -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
Re: flex-2.5.31
David Jensen wrote: I poked at this for a couple days, and there are problems with the current flex build instructions: 1. The order of the files in flex-2.5.31-debian_fixes-2.patch may sometimes trigger regenerating scan.c, which causes the build to fail if flex is not already installed. -- Solution: Move the scan.c section of the patch to after the scan.l section. Build and install per the current instructions. Goto 2. The livecd scripts implement another solution: patch -Z -Np1 -i flex-2.5.31-debian_fixes-2.patch Note the -Z option which causes dates to be set from the patch. -- Alexander E. Patrakov -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page