On Fri, May 21, 2010 at 4:17 AM, MartyMcFly <[email protected]> wrote:
>
> Hi all,
>
> I'm looking for a Visibroker Maven plugin to generate java files from IDL
> files.
>
> I found http://mojo.codehaus.org/visibroker-maven-plugin/index.html which
> apparently is dead and not available anymore (nothing on the repositories).
>
> Does anyone know if there is another working plugin available somewhere ?
>
> Thanks

i'm sure there's a better way to do this, but we're slowly trying to
expunge the CORBA from our systems so it hasn't been a high priority.
in one of our artifacts that occasionally requires IDL compilation we
have a profile set up to make an ANT call:

        <profiles>
                <profile>
                        <id>idl2java</id>
                        <build>
                                <plugins>
                                        <plugin>
                                                <!--
                                                        using antrun to execute 
idl2java has the portability issue, but
the codehaus plugin
                                                        couldn't generate the 
nonstandard tie method created by
visibroker. Hence, visibroker
                                                        idl2java must be 
installed in C: drive before this can be run
                                                -->
                                                
<groupId>org.apache.maven.plugins</groupId>
                                                
<artifactId>maven-antrun-plugin</artifactId>
                                                <executions>
                                                        <execution>
                                                                
<id>idl2java</id>
                                                                
<phase>generate-sources</phase>
                                                                <configuration>
                                                                        <tasks>
                                                                                
<property name="idl2java.executable"
value="C:\Inprise\vbroker\bin\idl2java.exe"/>
                                                                                
<ant antfile="${basedir}/build.xml">
                                                                                
        <target name="idl"/>
                                                                                
</ant>
                                                                        </tasks>
                                                                </configuration>
                                                                <goals>
                                                                        
<goal>run</goal>
                                                                </goals>
                                                        </execution>
                                                </executions>
                                        </plugin>
                                </plugins>
                        </build>
                </profile>
        </profiles>

and next to that artifacts pom file we have a build.xml containing:

<?xml version="1.0"?>
<project name="test6">
        
        <target name="idl" description="compile all IDL sources to Java source 
files">
                <apply executable="${idl2java.executable}" failonerror="true">
                        <!-- generated java file in source diectory -->
                        <arg line="-all_serializable -root_dir ./src/main/java" 
/>
                        <!-- the other idl depends on StringArray.idl in 
com/abc -->
                        <arg line="-no_examples -no_tie 
-Isrc/main/java/com/abc" />
                        <arg line="-no_toString" />
                        <fileset dir="${basedir}/src/main/java/com/">
                                <include name="**/*.idl" />
                        </fileset>
                </apply>
        </target>

</project>

then, when we have IDL updates, we build the artifact with the following cmd:
mvn clean install -Pidl2java

again, i'm sure there are more elegant ways to do this, but this
currently serves our needs.

Andrew Close

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to