Uploaded image for project: 'Bigtop'
  1. Bigtop
  2. BIGTOP-2618

bigtop-jsvc build fails with OpenJDK-1.8

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 1.2.0
    • Fix Version/s: 1.2.0
    • Component/s: build, jsvc
    • Labels:
      None
    • Environment:

      Fedora 2.5 x86 and Power

      Description

      Error msg:
      In file included from java.c:24:0:
      /usr/lib/jvm/java-1.8.0-openjdk/include/jni.h:45:20: fatal error: jni_md.h: No such file or directory
      #include "jni_md.h"

        Issue Links

          Activity

          Hide
          asanjar Amir Sanjar added a comment - - edited

          The failure is caused by change to the location of jni_md.h from $JAVA_HOME/include to $JAVA_HOME/include/linux in OpenJDK 1.8.
          Workaround:
          create a simple symbolic link as follow:
          ln -s $JAVA_HOME/include/linux/jni_md.h $JAVA_HOME/include/jni_md.h
          or
          adding -I$(JAVA_HOME)/include/linux/ to the makefile compiler options.
          Any thoughts?

          Show
          asanjar Amir Sanjar added a comment - - edited The failure is caused by change to the location of jni_md.h from $JAVA_HOME/include to $JAVA_HOME/include/linux in OpenJDK 1.8. Workaround: create a simple symbolic link as follow: ln -s $JAVA_HOME/include/linux/jni_md.h $JAVA_HOME/include/jni_md.h or adding -I$(JAVA_HOME)/include/linux/ to the makefile compiler options. Any thoughts?
          Hide
          rvs Roman Shaposhnik added a comment -

          How about telling autoconf to look for an extra dir when it comes to -I ?

          Show
          rvs Roman Shaposhnik added a comment - How about telling autoconf to look for an extra dir when it comes to -I ?
          Hide
          asanjar Amir Sanjar added a comment - - edited

          Roman, that would only work for x86, however autoconf has yet to add Power support .

          checking build system type... powerpc64le-unknown-linux-gnu
          checking host system type... powerpc64le-unknown-linux-gnu
          checking cached host system type... ok
          C-Language compilation tools
          checking for gcc... gcc
          checking whether the C compiler works... yes
          checking for C compiler default output file name... a.out
          checking for suffix of executables...
          checking whether we are cross compiling... no
          checking for suffix of object files... o
          checking whether we are using the GNU C compiler... yes
          checking whether gcc accepts -g... yes
          checking for gcc option to accept ISO C89... none needed
          checking for ranlib... ranlib
          checking for strip... strip
          Host support
          checking C flags dependant on host system type... failed
          configure: error: Unsupported CPU architecture "powerpc64le"
          error: Bad exit status from /var/tmp/rpm-tmp.pIDqNT (%build)

          Show
          asanjar Amir Sanjar added a comment - - edited Roman, that would only work for x86, however autoconf has yet to add Power support . checking build system type... powerpc64le-unknown-linux-gnu checking host system type... powerpc64le-unknown-linux-gnu checking cached host system type... ok C-Language compilation tools checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking for ranlib... ranlib checking for strip... strip Host support checking C flags dependant on host system type... failed configure: error: Unsupported CPU architecture "powerpc64le" error: Bad exit status from /var/tmp/rpm-tmp.pIDqNT (%build)
          Hide
          rvs Roman Shaposhnik added a comment -

          I think we have to fix autoconf issue upstream similarly to what we did for ARM.

          Also, I don't think your patch will work cases where JAVA_HOME is coming from a system-level location.

          Show
          rvs Roman Shaposhnik added a comment - I think we have to fix autoconf issue upstream similarly to what we did for ARM. Also, I don't think your patch will work cases where JAVA_HOME is coming from a system-level location.
          Hide
          asanjar Amir Sanjar added a comment -

          Roman, I agree with your assessment, however the issue we are dealing is with autoconf and common-daemon very slow release cycle.

          Show
          asanjar Amir Sanjar added a comment - Roman, I agree with your assessment, however the issue we are dealing is with autoconf and common-daemon very slow release cycle.
          Hide
          rvs Roman Shaposhnik added a comment -

          Ok, I'm motivated enough to do that. Can you hook me up with creds for a PPC env where the problem happens?

          Show
          rvs Roman Shaposhnik added a comment - Ok, I'm motivated enough to do that. Can you hook me up with creds for a PPC env where the problem happens?
          Hide
          oflebbe Olaf Flebbe added a comment - - edited

          Sorry Amir Sanjar: -1 to this patch.

          1) Autoconf has detection code for jni_md.h in various positions. Why does it fail ?
          2) Why guard the link with a os dependency ???
          3) Why guard the reconfiguration with a dependency???

          I cannot reproduce the problem with debian 8 , There is not fedora25 in dockerhub. I will first generate the image before accepting patches triggered by fedora 25.

          And btw. There is no fedora2.5 and we do not support x86. (Please check the environment of this issue)

          Show
          oflebbe Olaf Flebbe added a comment - - edited Sorry Amir Sanjar : -1 to this patch. 1) Autoconf has detection code for jni_md.h in various positions. Why does it fail ? 2) Why guard the link with a os dependency ??? 3) Why guard the reconfiguration with a dependency??? I cannot reproduce the problem with debian 8 , There is not fedora25 in dockerhub. I will first generate the image before accepting patches triggered by fedora 25. And btw. There is no fedora2.5 and we do not support x86. (Please check the environment of this issue)
          Hide
          rvs Roman Shaposhnik added a comment -

          Olaf Flebbe & Amir Sanjar please take a look at the attached patch. This one actually correctly lifts DAEMON-349 into Bigtop while simultaneously getting rid of the configure patch (we shouldn't really ever patch configure anyway – since it is always autogenerated).

          Show
          rvs Roman Shaposhnik added a comment - Olaf Flebbe & Amir Sanjar please take a look at the attached patch. This one actually correctly lifts DAEMON-349 into Bigtop while simultaneously getting rid of the configure patch (we shouldn't really ever patch configure anyway – since it is always autogenerated).
          Hide
          asanjar Amir Sanjar added a comment -

          hmm, I just noticed this.. I have added Fedora25 support for both x86 and Power few weeks ago, check the github. However there are issues with JAVA 8 support that I am working to resolve. I was waiting to resolve all these issues before uploading the fedora 25 images to dockerhub. But I could do it now if you want.

          Show
          asanjar Amir Sanjar added a comment - hmm, I just noticed this.. I have added Fedora25 support for both x86 and Power few weeks ago, check the github. However there are issues with JAVA 8 support that I am working to resolve. I was waiting to resolve all these issues before uploading the fedora 25 images to dockerhub. But I could do it now if you want.
          Hide
          asanjar Amir Sanjar added a comment -

          +1 thanks a lot Roman.

          Show
          asanjar Amir Sanjar added a comment - +1 thanks a lot Roman.
          Hide
          oflebbe Olaf Flebbe added a comment -

          +2 (i.e. both thumbs up) Thanks!

          Show
          oflebbe Olaf Flebbe added a comment - +2 (i.e. both thumbs up) Thanks!

            People

            • Assignee:
              asanjar Amir Sanjar
              Reporter:
              asanjar Amir Sanjar
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Due:
                Created:
                Updated:
                Resolved:

                Development