Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to manage native dep Question #23

Open
fbalicchia opened this issue Apr 11, 2022 · 0 comments
Open

How to manage native dep Question #23

fbalicchia opened this issue Apr 11, 2022 · 0 comments

Comments

@fbalicchia
Copy link

fbalicchia commented Apr 11, 2022

Tring to use a dependency that has platform-dependent dep resolver throw an NPE exception.
Excluding dependency that has classifier or adding the os-maven-plugin extension seems
that not resolve the problem.

This sounds like a bug but I'd like to know you could suggest a wa

to reproduce the problem please use testResolvePom and change the target pom to

<?xml version="1.0" encoding="UTF-8"?>

<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/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven</artifactId>
        <version>3.0.4</version>
    </parent>

    <artifactId>maven-core</artifactId>

    <name>Maven Core</name>
    <description>Maven Core classes.</description>

    <dependencies>
        <!--  Maven -->

        <dependency>
            <groupId>org.apache.arrow</groupId>
            <artifactId>flight-core</artifactId>
            <version>7.0.0</version>
        </dependency>
    </dependencies>

    <build>
        <resources>
            <resource>
                <directory>src/main/resources</directory>
                <filtering>true</filtering>
            </resource>
        </resources>
        <plugins>
            <plugin>
                <groupId>org.codehaus.plexus</groupId>
                <artifactId>plexus-component-metadata</artifactId>
            </plugin>
            <plugin>
                <groupId>org.codehaus.modello</groupId>
                <artifactId>modello-maven-plugin</artifactId>
                <configuration>
                    <version>1.0.0</version>
                    <models>
                        <model>src/main/mdo/toolchains.mdo</model>
                    </models>
                </configuration>
            </plugin>
        </plugins>
        <extensions>
            <extension>
                <groupId>kr.motd.maven</groupId>
                <artifactId>os-maven-plugin</artifactId>
                <version>1.5.0.Final</version>
            </extension>
        </extensions>
    </build>

    <profiles>
        <profile>
            <id>svn-buildnumber</id>
            <activation>
                <file>
                    <exists>.svn</exists>
                </file>
            </activation>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.codehaus.mojo</groupId>
                        <artifactId>buildnumber-maven-plugin</artifactId>
                        <executions>
                            <execution>
                                <phase>generate-resources</phase>
                                <goals>
                                    <goal>create</goal>
                                </goals>
                            </execution>
                        </executions>
                        <configuration>
                            <doCheck>false</doCheck>
                            <doUpdate>false</doUpdate>
                            <providerImplementations>
                                <svn>javasvn</svn>
                            </providerImplementations>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>non-canonical-buildnumber</id>
            <activation>
                <file>
                    <missing>.svn</missing>
                </file>
            </activation>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.codehaus.mojo</groupId>
                        <artifactId>buildnumber-maven-plugin</artifactId>
                        <executions>
                            <execution>
                                <phase>generate-resources</phase>
                                <goals>
                                    <goal>create</goal>
                                </goals>
                            </execution>
                        </executions>
                        <configuration>
                            <doCheck>false</doCheck>
                            <doUpdate>false</doUpdate>
                            <format>NON-CANONICAL_{0,date,yyyy-MM-dd_HH-mm}_{1}</format>
                            <items>
                                <item>timestamp</item>
                                <item>${user.name}</item>
                            </items>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>

Thanks for help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant