porting icedtea6 to FreeBSD
Andrew Hughes
ahughes at redhat.com
Wed Apr 18 16:51:17 PDT 2012
----- Original Message -----
> On Wed, Apr 18, 2012 at 09:21:36AM -0700, Jason Helfman thus spake:
> >On Wed, Apr 18, 2012 at 09:23:43AM -0400, Andrew Hughes thus spake:
> >>----- Original Message -----
> >>> On Tue, Apr 17, 2012 at 08:08:43AM -0700, Jason Helfman thus
> >>> spake:
> >>> >On Tue, Apr 17, 2012 at 7:56 AM, Andrew Hughes
> >>> ><ahughes at redhat.com>
> >>> >wrote:
> >>> >
> >>> >> ----- Original Message -----
> >>> >> >
> >>> >> >
> >>> >> >
> >>> >> > On Tue, Apr 17, 2012 at 4:51 AM, Andrew Hughes <
> >>> >> > ahughes at redhat.com >
> >>> >> > wrote:
> >>> >> >
> >>> >> >
> >>> >> >
> >>> >> > ----- Original Message -----
> >>> >> > > On Mon, Apr 16, 2012 at 09:59:00AM -0400, Andrew Hughes
> >>> >> > > thus
> >>> >> > > spake:
> >>> >> > > >> Any thoughts on any of this?
> >>> >> > > >> Thanks, again.
> >>> >> > > >>
> >>> >> > > >> -jgh
> >>> >> > > >
> >>> >> > > >What are you doing here?
> >>> >> > > >
> >>> >> > > >/usr/bin/sed -i.bak -e 's|--dry-run||g'
> >>> >> > >
> >>> >> >/usr/local/workspace/redports/java/icedtea6/work/icedtea6-1.11.1/Makefile.am
> >>> >> > >
> >>> >> >/usr/local/workspace/redports/java/icedtea6/work/icedtea6-1.11.1/Makefile.in
> >>> >> > > >/usr/bin/sed -i.bak -e 's|--check|-q|g'
> >>> >> > >
> >>> >> >/usr/local/workspace/redports/java/icedtea6/work/icedtea6-1.11.1/Makefile.am
> >>> >> > >
> >>> >> >/usr/local/workspace/redports/java/icedtea6/work/icedtea6-1.11.1/Makefile.in
> >>> >> > > >
> >>> >> > > >If you're removing --dry-run, you're going to be applying
> >>> >> > > >the
> >>> >> > > >patch
> >>> >> > > >twice, which is why it's failing.
> >>> >> > > >--
> >>> >> > > >Andrew :)
> >>> >> > >
> >>> >> > > I've modified this to test the patch which in FreeBSD is
> >>> >> > > the
> >>> >> > > "-C"
> >>> >> > > switch,
> >>> >> > > and the "-q" is for SHASUM's to only output the hash.
> >>> >> > >
> >>> >> > > I was able to get much further in the build! Any thoughts
> >>> >> > > on
> >>> >> > > why
> >>> >> > > this
> >>> >> > > patch
> >>> >> > > was seen as already applied?
> >>> >> > >
> >>> >> >
> >>> >> > Because the build tests the patch, then applies it if that
> >>> >> > passes. If
> >>> >> > you
> >>> >> > removed --dry-run from the first invocation and didn't
> >>> >> > replace
> >>> >> > it
> >>> >> > with -C,
> >>> >> > you'd be applying the patch twice instead.
> >>> >> >
> >>> >> >
> >>> >> >
> >>> >> > That is what I have done, though. --dry-run is being
> >>> >> > replaced
> >>> >> > with -C
> >>> >> > in the build.
> >>> >> > Is something else showing up?
> >>> >> >
> >>> >> > -jgh
> >>> >> >
> >>> >> >
> >>> >>
> >>> >> And it's still failing in the same way? I thought you said
> >>> >> you'd
> >>> >> got much
> >>> >> further... :-S
> >>> >> --
> >>> >> Andrew :)
> >>> >>
> >>> >
> >>> >Yes, it is failing in the same way but much further into the
> >>> >build.
> >>> >Initially, it would fail at the first/second patch.
> >>> >I attached the latest buildlog to my email last night. It should
> >>> >show the
> >>> >issue, and with what patch the problem
> >>> >was with.
> >>> >
> >>> >-jgh
> >>>
> >>> I believe I found part of the issue. In the patchset, the file
> >>> openjdk/7034464-hugepage.patch has a number of repatched
> >>> instances
> >>> within
> >>> os_linux.cpp, which is more than likely the cause of this issue.
> >>> It
> >>> is being
> >>> patched twice.
> >>>
> >>> Starting at line 40, and another starting at line 209.
> >>>
> >>> For instance, both are adding this information to the same file:
> >>>
> >>> 47 +// Define MAP_HUGETLB here so we can build HotSpot on old
> >>> systems.
> >>> 48 +#ifndef MAP_HUGETLB
> >>> 49 +#define MAP_HUGETLB 0x40000
> >>> 50 +#endif
> >>>
> >>> 227 +// Define MAP_HUGETLB here so we can build HotSpot on old
> >>> systems.
> >>> 228 +#ifndef MAP_HUGETLB
> >>> 229 +#define MAP_HUGETLB 0x40000
> >>> 230 +#endif
> >>>
> >>> -jgh
> >>>
> >>> --
> >>> Jason Helfman | FreeBSD Committer
> >>> jgh at FreeBSD.org | http://people.freebsd.org/~jgh
> >>>
> >>
> >>Ah right, now that's more helpful :-)
> >>
> >>It looks like the patch is a bit messed up, and BSD's patch program
> >>is just not as tolerant as the GNU one. My log shows this:
> >>
> >>Checking patches/openjdk/7034464-hugepage.patch
> >>Applying patches/openjdk/7034464-hugepage.patch
> >>patching file openjdk/hotspot/src/os/linux/vm/globals_linux.hpp
> >>patching file openjdk/hotspot/src/os/linux/vm/os_linux.cpp
> >>patching file openjdk/hotspot/src/os/linux/vm/os_linux.cpp.orig
> >>patching file openjdk/hotspot/src/os/linux/vm/os_linux.hpp
> >>Checking patches/openjdk/7037939-hugepage.patch
> >>Applying patches/openjdk/7037939-hugepage.patch
> >>patching file openjdk/hotspot/src/os/linux/vm/os_linux.cpp
> >>Hunk #1 succeeded at 4148 (offset -22 lines).
> >>patching file openjdk/hotspot/src/os/solaris/vm/os_solaris.cpp
> >>Hunk #2 succeeded at 5041 (offset -2 lines).
> >>Checking patches/openjdk/7043564-hugepage.patch
> >>Applying patches/openjdk/7043564-hugepage.patch
> >>patching file openjdk/hotspot/src/os/linux/vm/os_linux.cpp
> >>Hunk #1 succeeded at 5084 (offset 2234 lines).
> >>
> >>I'll look at fixing this up in HEAD, but for BSD you can just
> >>disabled these
> >>three by deleting the references from Makefile.am.
> >
> >Great, thanks. I don't see what to delete though. Would you mind
> >sending a
> >diff?
> >
Sorry only just saw your reply. Glad you sorted it.
>
> I've got it. I ended up dropping one more patch file, and now I am
> getting
> this error:
>
> patches/openjdk/7103610-_NET_WM_PID_and_WM_CLIENT_MACHINE_are_not_set.patch
> patch: **** misordered hunks! output would be garbled
> ERROR patch
> patches/openjdk/7103610-_NET_WM_PID_and_WM_CLIENT_MACHINE_are_not_set.patch
> FAILED!
> WARNING make clean-patch before retrying a fix
>
> Is this patch necessary for FreeBSD?
>
It's to make the system tray work correctly with GNOME Shell, so if you're not
using that, then no you don't need it.
I'm curious as to why it failed though...
> -jgh
>
> --
> Jason Helfman | FreeBSD Committer
> jgh at FreeBSD.org | http://people.freebsd.org/~jgh
>
--
Andrew :)
Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)
PGP Key: 248BDC07 (https://keys.indymedia.org/)
Fingerprint = EC5A 1F5E C0AD 1D15 8F1F 8F91 3B96 A578 248B DC07
More information about the distro-pkg-dev
mailing list