[MacPorts] #21603: openjdk6 build fails on Leopard

MacPorts noreply at macports.org
Sun Jan 24 08:51:39 PST 2010


#21603: openjdk6 build fails on Leopard
----------------------------------+-----------------------------------------
 Reporter:  heapifyman@…          |       Owner:  landonf@…           
     Type:  defect                |      Status:  new                 
 Priority:  Normal                |   Milestone:                      
Component:  ports                 |     Version:  1.8.0               
 Keywords:                        |        Port:  openjdk6            
----------------------------------+-----------------------------------------

Comment(by email.macports@…):

 I've run across the same problem and did some digging into the problem.  I
 think I've identified two distinct issues.  One in the build and a second
 in the source code that is being built.  I don't really understand the
 root cause of the build problem, but found a simple tweak that made it
 work on my system (MacBook Pro 17"; Intel Core Duo; Mac OS X 10.5.8).

 After googling ALT_JDK_IMPORT_PATH to try and understand what it is used
 for, it seemed like it ought to point to the same place as the bootstrap
 JDK.  So, I modified the Portfile to include a build argument of
 ALT_JDK_IMPORT_PATH="${bootstrapvm}".  THe build proceeded father, but
 failed again with the following error:

 {{{
 make[5]: *** No rule to make target `-j1'.  Stop.
 make[4]: *** [sa_stuff] Error 2
 make[3]: *** [product] Error 2
 make[2]: *** [generic_build2] Error 2
 make[1]: *** [product] Error 2
 make: *** [hotspot-build] Error 2
 make: *** Waiting for unfinished jobs....
 }}}

 That made me wonder if something about building in parallel might be the
 problem, so I added the following line to the Portfile to restrict the
 build to a single job:

 {{{
 use_parallel_build     no
 }}}

 The build again progressed further, but failed again with the following
 error:

 {{{
 ../../../src/solaris/native/sun/awt/awt_GraphicsEnv.c: In function
 'makeDefaultConfig':
 ../../../src/solaris/native/sun/awt/awt_GraphicsEnv.c:291: warning: format
 '%x' expects type 'unsigned int *', but argument 3 has type 'VisualID *'
 ../../../src/solaris/native/sun/awt/awt_GraphicsEnv.c: In function
 'J2DXErrHandler':
 ../../../src/solaris/native/sun/awt/awt_GraphicsEnv.c:966: error:
 'X_ShmAttach' undeclared (first use in this function)
 ../../../src/solaris/native/sun/awt/awt_GraphicsEnv.c:966: error: (Each
 undeclared identifier is reported only once
 ../../../src/solaris/native/sun/awt/awt_GraphicsEnv.c:966: error: for each
 function it appears
 make[4]: ***
 [/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_java_openjdk6/work/build/bsd-i586/tmp/sun/sun.awt.X11/xawt/obj/awt_GraphicsEnv.o]
 Error 1
 make[4]: *** Waiting for unfinished jobs....
 make[3]: *** [library_parallel_compile] Error 2
 make[2]: *** [all] Error 1
 make[1]: *** [all] Error 1
 make: *** [jdk-build] Error 2
 }}}

 After digging around to find where X_ShmAttach was declared, I found it in
 X11/extensions/shmproto.h.  It failed again because of something that it
 used in shmproto.h that is declared in X11/Xmd.h, but Xmd.h wasn't
 included in shmproto.h.  So, I added that to awt_GraphicsEnv.c as well.

 I built again and...SUCCESS!!!

 I've attached patch files for Portfile and files/patch-set that address
 the problems.  Hopefully, these are acceptable solutions to the issue and
 can be incorporated and released.

-- 
Ticket URL: <http://trac.macports.org/ticket/21603#comment:8>
MacPorts <http://www.macports.org/>
Ports system for Mac OS


More information about the macports-tickets mailing list