Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 806341

Summary: TPS SRPM Failures : JAVA_INCLUDE_PATH2
Product: Red Hat Enterprise Linux 6 Reporter: Jenny Severance <jgalipea>
Component: pki-coreAssignee: Matthew Harmsen <mharmsen>
Status: CLOSED WONTFIX QA Contact: IDM QE LIST <seceng-idm-qe-list>
Severity: unspecified Docs Contact:
Priority: high    
Version: 6.3CC: ckannan, nkinder
Target Milestone: rc   
Target Release: 6.3   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-03-30 17:49:10 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jenny Severance 2012-03-23 13:41:46 UTC
Description of problem:

<snip>

BUILDLOG: pki-core-9.0.3-24.el6.src.rpm-x86_64-rebuild.log contains full details. Reports from make and rpmbuild, with line numbers: 
269-Please set them or make sure they are set and tested correctly in the CMake files: 
270-JAVA_INCLUDE_PATH2 
271- used as include directory in directory /usr/src/redhat/BUILD/pki-core-9.0.3/base/symkey/src/com/netscape/symkey 
272- 
273--- Configuring incomplete, errors occurred! 
274:error: Bad exit status from /var/tmp/rpm-tmp.3F1RPv (%build) 
</snip>


Version-Release number of selected component (if applicable):
pki-core-9.0.3-24.el6.x86_64

How reproducible:


Steps to Reproduce:
1. Please see errata TPS reports
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Matthew Harmsen 2012-03-27 02:07:05 UTC
'JAVA_INCLUDE_PATH2' is defined in the 'pki-core-9.0.3-24.el6.x86_64' source tarball under the following file:

    * cmake/Modules/FindJNI.cmake

which is included by the top-level 'CMakeLists.txt' file:

    * # where to look first for cmake modules
      # (before ${CMAKE_ROOT}/Modules/ is checked)
      set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/Modules)

      # add definitions
      include(DefineCMakeDefaults)
      include(DefinePlatformDefaults)
      include(DefineCompilerFlags)
      include(DefineInstallationPaths)
      include(DefineOptions.cmake)
      include(CPackConfig.cmake)

      # disallow in-source build
      include(MacroEnsureOutOfSourceBuild)
      macro_ensure_out_of_source_build("${PROJECT_NAME} requires an out of source build. Please create a separate build directory and run 'cmake /path/to/${PROJECT_NAME} [options]' there.")

      # add macros
      include(MacroCopyFile)
      include(UseJava)

The "FindJNI.cmake" file contains the following definition:

    * find_path(JAVA_INCLUDE_PATH2
          NAMES
              jni_md.h
          PATHS
              ${JAVA_INCLUDE_PATH}
              ${JAVA_INCLUDE_PATH}/win32
              ${JAVA_INCLUDE_PATH}/linux
              ${JAVA_INCLUDE_PATH}/freebsd
              ${JAVA_INCLUDE_PATH}/solaris
      )

For RHEL 6 platforms, the 'java-1.6.0-openjdk-devel' package contains the 'jni_md.h' file:

    * /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/include/linux/jni_md.h

I successfully tested a rebuild on my system (non-mock):

    * rpmbuild --rebuild   --define "dist .el6" --define "_topdir `pwd`" ./SRPMS/pki-core-9.0.3-24.el6.src.rpm


The only possible explanation I can offer is that the FindJNI file is somehow not getting included for "TPS" tests.  For example:

    * find . -name CMakeLists.txt  | xargs grep ^include\(
    ./CMakeLists.txt:include(DefineCMakeDefaults)
    ./CMakeLists.txt:include(DefinePlatformDefaults)
    ./CMakeLists.txt:include(DefineCompilerFlags)
    ./CMakeLists.txt:include(DefineInstallationPaths)
    ./CMakeLists.txt:include(DefineOptions.cmake)
    ./CMakeLists.txt:include(CPackConfig.cmake)
    ./CMakeLists.txt:include(MacroEnsureOutOfSourceBuild)
    ./CMakeLists.txt:include(MacroCopyFile)
    ./CMakeLists.txt:include(UseJava)
    ./CMakeLists.txt:include(ConfigureChecks.cmake)

I could find no place that specifically defined inclusion of "FindJNI.cmake", but this has never been a problem before, and does not seem to cause issues outside of TPS.

Comment 2 Matthew Harmsen 2012-03-28 00:38:19 UTC
Attempted to replicate this issue in a 'mock' environment (using copies of RHEL 6 'mock' configuration files for i386 and x86_64) produced success for the following cases:

    * rpm -q mock
    mock-1.1.21-1.fc16.noarch

    * mock -v -r rhel-6-i386 --rebuild ./pki-core-9.0.3-24.el6.src.rpm

    * mock -v -r rhel-6-x86_64 --rebuild ./pki-core-9.0.3-24.el6.src.rpm

As I am unable to replicate this issue, may I suggest that TPS tests be re-run to see if the same error is encountered?

If it isn't, could you please consider waiving this TPS test?

Comment 3 Jenny Severance 2012-03-29 19:04:04 UTC
There are two arches that are still failing with this error on SRPM rebuild testing.  I would also suggest we waive the failures for the 6.3 errata, ship we ship and support built rpms, not rebuild rpms.  Please advise ...

Comment 4 Chandrasekar Kannan 2012-03-30 17:43:45 UTC
Go ahead and waive it. Its pretty clear we can do builds on brew that we consider is a sane build env. So not seeing it as an issue. And it builds just fine on 6Server(the most important flavor).

Comment 5 Jenny Severance 2012-03-30 17:49:10 UTC
closing bug ... wont fix