Maven complains that "org.omg.CORBA" does not exist while trying to build JacORB

403 Views Asked by At

I'm trying to build JacORB via Maven under version 17 of the JDK. I've run the command mvn clean install as instructed in page 14 of the docs, but got the following error:

[ERROR] /home/mehdi/JacORB/idl-compiler/src/main/java/org/jacorb/idl/StructType.java:[146,29] package org.omg.CORBA does not exist

The error seems to originate from the idl-compiler module. The block that corresponds to the error is this:

public int getTCKind() {
    return org.omg.CORBA.TCKind._tk_struct;
}

The package org.omg.CORBA seems to exist under the module omgapi of the same project, so I thought to try and include this module as a dependency in the pom file of idl-compiler as follows:

<dependency>
     <groupId>org.jacorb</groupId>
     <artifactId>jacorb-omgapi</artifactId>
</dependency>

However, after running mvn clean install I got a complaint about cyclic dependencies:

[ERROR] [ERROR] The projects in the reactor contain a cyclic reference: Edge between 'Vertex{label='org.jacorb:jacorb-idl-compiler:3.10-SNAPSHOT'}' and 'Vertex{label='org.jacorb:jacorb-omgapi:3.10-SNAPSHOT'}' introduces to cycle in the graph org.jacorb:jacorb-omgapi:3.10-SNAPSHOT --> org.jacorb:jacorb-idl-compiler:3.10-SNAPSHOT --> org.jacorb:jacorb-omgapi:3.10-SNAPSHOT @

This doesn't seem to make sense as the pom file of the module omgapi doesn't have any <dependencies>. Is there a way to solve this?

I also tried to remove the dependency and then execute the command:

mvn clean install -Dorg.omg.CORBA.ORBClass=org.jacorb.orb.ORB

But got the same error indicating that there is no org.omg.CORBA package.

Not sure if this might be helpful, but when I echo $JAVA_HOME I get the following result:

/usr/lib/jvm/java-17-openjdk-amd64
0

There are 0 best solutions below