To expand on this.. Given the following command line options defined for the compiler; -idirafterdir Add directory (dir) to the second include file search path (after -I). -Idirectory Specifies an additional directory to search for include files -Ldirectory Instruct linker to search directory for libraries
one would modify the sample pom and adjust the start, middle and end options of the compiler and linker as required or suggested by output. Good luck, <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>com.mycompany.app</groupId> <artifactId>my-app</artifactId> <packaging>so</packaging> <version>1.0-SNAPSHOT</version> <name>my-app</name> <url>http://maven.apache.org</url> <dependencies> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>3.8.1</version> <scope>test</scope> </dependency> </dependencies> <build> <plugins> <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>native-maven-plugin</artifactId> <extensions>true</extensions> <configuration> <compilerProvider>generic</compilerProvider> <compilerExecutable>icl</compilerExecutable> <compilerStartOptions>-I"C:\Programme\Intel\Compiler\C++\9.1\IA32\Includ e"</compilerStartOptions> <linkerStartOptions>-shared -lxml2 -lz -lpthread -ldl</linkerStartOptions> <linkerMiddleOptions>-L"C:\Programme\Intel\Compiler\C++\9.1\IA32\Lib"</l inkerMiddleOptions> <sources> <source> <directory>/src/main/native</directory> <includes> <include>*.cpp</include> </includes> </source> </sources> </configuration> </plugin> </plugins> </build> </project> -----Original Message----- From: Dan Tran [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 08, 2007 6:48 AM To: Maven Users List Subject: Re: Maven native plugin take tout <your code> <source> <directory>C:\Programme\Intel\Compiler\C++\9.1\IA32\Include</directory> <includes> <include>*.h</include> </includes> </source> <source> <source> <directory>C:\Programme\Intel\Compiler\C++\9.1\IA32\Lib</directory> <includes> <include>*.lib</include> </includes> <includes> <include>*.dll</include> </includes> </source> </yourcode> - Dont think we support compilation of .h file - Dont think the compliler can compile .dll files - Dont think we support *.lib, you must explicitely link it via LinkerStartOption using your linker specific arguments Best to take to present INCLUDE and LIB system environment variables prior to running mvn -D On 5/7/07, jBeuchat <[EMAIL PROTECTED]> wrote: > > > Thank you for your answer. > I have done what you told me to do, but still have an error. There is > something wrong, but i don't know what. > > > The dependencies? > The sources? > > or that? > <compilerProvider>generic</compilerProvider> > <compilerExecutable>icl</compilerExecutable> > > ?? > > THank you for your help! > > Here my "pom.xml" : > > <project xmlns="http://maven.apache.org/POM/4.0.0" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 > http://maven.apache.org/maven-v4_0_0.xsd"> > <modelVersion>4.0.0</modelVersion> > <groupId>com.mycompany.app</groupId> > <artifactId>my-app</artifactId> > <packaging>so</packaging> > <version>1.0-SNAPSHOT</version> > <name>my-app</name> > <url>http://maven.apache.org</url> > <dependencies> > <dependency> > <groupId>junit</groupId> > <artifactId>junit</artifactId> > <version>3.8.1</version> > <scope>test</scope> > </dependency> > </dependencies> > <build> > <plugins> > <plugin> > <groupId>org.codehaus.mojo</groupId> > <artifactId>native-maven-plugin</artifactId> > <extensions>true</extensions> > <configuration> > <linkerStartOptions> > <linkerStartOption>-shared -lxml2 -lz -lpthread > -ldl</linkerStartOption> > </linkerStartOptions> > <sources> > <source> > <directory>/src/main/native</directory> > <includes> > <include>*.cpp</include> > </includes> > </source> > <source> > > <directory>C:\Programme\Intel\Compiler\C++\9.1\IA32\Include</directory> > <includes> > <include>*.h</include> > </includes> > </source> > <source> > > <directory>C:\Programme\Intel\Compiler\C++\9.1\IA32\Lib</directory> > <includes> > <include>*.lib</include> > </includes> > <includes> > <include>*.dll</include> > </includes> > </source> > </sources> > <compilerProvider>generic</compilerProvider> > <compilerExecutable>icl</compilerExecutable> > </configuration> > </plugin> > </plugins> > </build> > </project> > > > Sean Hennessy wrote: > > > > > > It appears that an include path directive is missing on the command > line. > > Hunt through the Intel compiler and the native documentation > > http://mojo.codehaus.org/maven-native/native-maven-plugin/usage.html > > and find the section in the pom that allows one to specify include > files/paths > > for the compiler. > > It might be that you will experiment with the > > <compilerStartOptions>.. > > > > > > -- > View this message in context: > http://www.nabble.com/Maven-native-plugin-tf3639190s177.html#a10370684 > Sent from the Maven - Users mailing list archive at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]