<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>88961</bug_id>
          
          <creation_ts>2005-04-13 06:52 0000</creation_ts>
          <short_desc>Error building eclipse-sdk 3.1_pre6: jni.h: No such file</short_desc>
          <delta_ts>2005-04-13 14:10:29 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Ebuilds</component>
          <version>unspecified</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>hermetica@gmail.com</reporter>
          <assigned_to>java@gentoo.org</assigned_to>
          

      

      
          <long_desc isprivate="0">
            <who>hermetica@gmail.com</who>
            <bug_when>2005-04-13 06:52:50 0000</bug_when>
            <thetext>When I emerge eclipse-sdk with USE=&quot;mozilla&quot; it fails because dont found jni.h, that file is in $JAVA_HOME/include, but the &quot;-I$JAVA_HOME/include&quot; is not in the ebuild:

---------------------------------------------------------------------------
export SWT_PTR_CFLAGS=&quot;${swt_ptr_cflags} -I${JAVA_HOME}/include -I${JAVA_HOME}/include/linux&quot;
---------------------------------------------------------------------------

Adding &quot;-I${JAVA_HOME}/include&quot; in file /usr/portage/dev-util/eclipse-sdk/eclipse-sdk-3.1_pre6.ebuild, line 481 fix the problem.

Reproducible: Always
Steps to Reproduce:
1. USE=&quot;mozilla&quot; emerge -av eclipse-sdk
2. Wait start the compilation for xpcom.cpp
3. Get the error:
7/include/linux  -I/opt/sun-jdk-1.4.2.07/include/linux -c xpcom.cpp
distcc[3302] ERROR: compile (null) on localhost failed
In file included from xpcom.cpp:29:
swt.h:23:17: jni.h: No such file or directory
In file included from xpcom.cpp:29:
swt.h:64: error: `JNIEnv&apos; was not declared in this scope
swt.h:64: error: `env&apos; was not declared in this scope
swt.h:64: error: variable or field `throwOutOfMemory&apos; declared void
In file included from xpcom.cpp:30:
xpcom_structs.h:32: error: `JNIEnv&apos; was not declared in this scope
xpcom_structs.h:32: error: `env&apos; was not declared in this scope
xpcom_structs.h:32: error: `jobject&apos; was not declared in this scope
xpcom_structs.h:32: error: parse error before `)&apos; token
xpcom_structs.h:33: error: `JNIEnv&apos; was not declared in this scope


Actual Results:  
Error:
7/include/linux  -I/opt/sun-jdk-1.4.2.07/include/linux -c xpcom.cpp
distcc[3302] ERROR: compile (null) on localhost failed
In file included from xpcom.cpp:29:
swt.h:23:17: jni.h: No such file or directory
In file included from xpcom.cpp:29:
swt.h:64: error: `JNIEnv&apos; was not declared in this scope
swt.h:64: error: `env&apos; was not declared in this scope
swt.h:64: error: variable or field `throwOutOfMemory&apos; declared void
In file included from xpcom.cpp:30:
xpcom_structs.h:32: error: `JNIEnv&apos; was not declared in this scope
xpcom_structs.h:32: error: `env&apos; was not declared in this scope
xpcom_structs.h:32: error: `jobject&apos; was not declared in this scope
xpcom_structs.h:32: error: parse error before `)&apos; token
xpcom_structs.h:33: error: `JNIEnv&apos; was not declared in this scope


Expected Results:  
Emerge ends succefully :)</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>luckyduck@gentoo.org</who>
            <bug_when>2005-04-13 12:29:50 0000</bug_when>
            <thetext>does it work without distcc? looks like it&apos;s related to distcc, only guessing however</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>hermetica@gmail.com</who>
            <bug_when>2005-04-13 12:58:42 0000</bug_when>
            <thetext>With and without distcc I get the same error, the fix/workaround I found is editing the ebuild and add the gcc&apos;s &quot;-I....&quot; option.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>axxo@gentoo.org</who>
            <bug_when>2005-04-13 13:48:06 0000</bug_when>
            <thetext>indeed
added the include, thanks

(lucky it was probably picking up yours from gcc with +gcj)</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>luckyduck@gentoo.org</who>
            <bug_when>2005-04-13 14:08:55 0000</bug_when>
            <thetext>ah, i see.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>axxo@gentoo.org</who>
            <bug_when>2005-04-13 14:10:29 0000</bug_when>
            <thetext>forgot to mark fixed :-)</thetext>
          </long_desc>
      
    </bug>

</bugzilla>