[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Ltib] ncurses patching fails
From: |
Mark |
Subject: |
Re: [Ltib] ncurses patching fails |
Date: |
Thu, 5 Aug 2010 15:20:49 +0100 |
User-agent: |
KMail/1.13.5 (Linux/2.6.34-12-desktop; KDE/4.4.4; x86_64; ; ) |
Hello Stuart
The version of patch on my machine is "GNU patch 2.6.1.81-5b68" (I'm using
openSUSE 11.3).
Your patch to the spec file works, however more files need to be added as
aclocal.m4 is not the only read-only file that needs to be patched. For
ncurses I would need to add the following lines:
chmod +w aclocal.m4
chmod +w configure
chmod +w c++/cursesw.cc
chmod +w include/curses.h.in
This problem is not limited to ncurses, so far I have run into the same issue
with tcp_wrappers, portmap and timezone(tzcode,tzdata). I've run 'chmod -R +w
*' on the tarballs, perhaps it would be better to include this in the spec
files?
Regards
Mark
On Wednesday 04 Aug 2010 18:58:44 Stuart Hughes wrote:
> Hi Mark,
>
> Nothing has changed with that package in ages. I suspect the problem is
> to do with your host distribution and its version of patch. I just
> tried on a Dreamlinux 3.5 (Debian Lenny vintage) and I see:
>
> + STATUS=0
> + '[' 0 -ne 0 ']'
> + cd ncurses-5.3
> + echo 'Patch #0 (ncurses-5.3-etip-2.patch):'
> Patch #0 (ncurses-5.3-etip-2.patch):
> + patch -p1 -s
> + echo 'Patch #1 (ncurses-5.3-vsscanf.patch):'
> Patch #1 (ncurses-5.3-vsscanf.patch):
> + patch -p1 -s
> + echo 'Patch #2 (ncurses-5.3-wint_t.patch):'
> Patch #2 (ncurses-5.3-wint_t.patch):
> + patch -p1 -s
> + exit 0
> Executing(%build): /bin/sh -e
> /data/seh/Src/ltib_bsps/savannah_ltib/tmp/rpm-tmp.52436
> + umask 022
>
> Looking at aclocal.m4 I see:
> -r--r--r-- 1 seh seh 82995 2010-08-04 18:50 aclocal.m4
>
> and checking the file I can see it got patched.
>
> Can you check your version of patch to confirm this, mine is:
>
> $ patch --version
> patch --versionpatch 2.5.9
> [snip]
>
> I think the new one is being too helpful. I think the best think
> overall is to change the spec file and make the offending file writeable.
>
> Could you try this on your machine (rm -rf rpm/BUILD/ncurses* first):
>
> edit: dist/lfs-5.1/ncurses/ncurses.spec
>
> and apply this patch:
>
>
> Index: dist/lfs-5.1/ncurses/ncurses.spec
> ===================================================================
> RCS file: /sources/ltib/ltib/dist/lfs-5.1/ncurses/ncurses.spec,v
> retrieving revision 1.2
> diff -u -r1.2 ncurses.spec
> --- dist/lfs-5.1/ncurses/ncurses.spec 10 Jul 2009 09:21:05 -0000 1.2
> +++ dist/lfs-5.1/ncurses/ncurses.spec 4 Aug 2010 17:58:02 -0000
> @@ -20,6 +20,8 @@
>
> %Prep
> %setup
> +# make aclocal.m4 writable for later versions of patch
> +chmod +w aclocal.m4
> %patch0 -p1
> %patch1 -p1
> %patch2 -p1
>
> Then run:
>
> $ ./ltib -p ncurses
>
> If that fixes it, I'll check in the update.
>
> Regards, Stuart
>
> Mark wrote:
> > Hello
> >
> > I've just updated my copy of LTIB via CVS and can no longer get ncurses
> > to build because the source cannot be patched:
> >
> >
> > + cd ncurses-5.3
> > + echo 'Patch #0 (ncurses-5.3-etip-2.patch):'
> > Patch #0 (ncurses-5.3-etip-2.patch):
> > + patch -p1 -s
> > File aclocal.m4 is read-only; refusing to patch
> > 1 out of 1 hunk ignored -- saving rejects to file aclocal.m4.rej
> > File configure is read-only; refusing to patch
> > 1 out of 1 hunk ignored -- saving rejects to file configure.rej
> > error: Bad exit status from /home/mark/ltib/tmp/rpm-tmp.13551 (%prep)
> >
> >
> > The problem appears to be that the permissions for the relevant source
> > files are set to read-only and so the patches cannot be applied. I
> > haven't had (or haven't noticed) any problems building ncurses in the
> > past, and I can't see that any of the sources have changed recently.
> >
> > Anybody else had this problem?
> >
> > Thanks
> >
> > Mark
> >
> > _______________________________________________
> > LTIB home page: http://ltib.org
> >
> > Ltib mailing list
> > address@hidden
> > http://lists.nongnu.org/mailman/listinfo/ltib