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

trip-discovery build.xml fails to compile #36

Open
harshil1234 opened this issue Feb 2, 2016 · 8 comments
Open

trip-discovery build.xml fails to compile #36

harshil1234 opened this issue Feb 2, 2016 · 8 comments

Comments

@harshil1234
Copy link

I am seeing an error while trying to compile trip-discovery jar. So am I doing something wrong.

/usr/local/ant/bin/ant
Buildfile: /Users/harshil/EDH/gis-tools-for-hadoop/samples/trip-discovery/build.xml

BUILD FAILED
/Users/harshil/EDH/gis-tools-for-hadoop/samples/trip-discovery/build.xml:5: Problem: failed to create task or type antlib:org.apache.maven.artifact.ant:dependencies
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any <presetdef>/<macrodef> declarations have taken place.
No types or tasks have been defined in this namespace yet

This appears to be an antlib declaration.
Action: Check that the implementing library exists in one of:
        -/usr/local/ant/lib
        -/Users/harshil/.ant/lib
        -a directory added on the command line with the -lib argument


Total time: 0 seconds

Adding following lines in build.xml fixes it:

<path id="maven-ant-tasks.classpath" path="../lib/maven-ant-tasks-2.1.3.jar" />
  <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
          uri="antlib:org.apache.maven.artifact.ant"
          classpathref="maven-ant-tasks.classpath" />

[edited 02/02 to display the output and XML correctly -- Randall]

@randallwhitman
Copy link
Contributor

Thanks.
Aside from that, I see we have not mavenized the samples.

@randallwhitman
Copy link
Contributor

For me ant clean; ant succeeds out of the box. Maybe some configuration or environment affects it.

@harshil1234 What operating system and Ant version do you have?

@climbage Any insights offhand?

@harshil1234
Copy link
Author

Hi Randall,

I am running on Mac OS X Yosemite 10.10.1. Is there something specific that you want me to check in my environment ?

Thanks,
Harshil

@randallwhitman
Copy link
Contributor

Thanks for the OS version. What is your Ant version? Not that I have any real reason to think it makes a difference - I'm making wild guesses. Maybe a colleague with a Mac will be able to try it out.

@harshil1234
Copy link
Author

Below is the ant info:
/usr/local/ant/bin/ant -version
Apache Ant(TM) version 1.9.3 compiled on December 23 2013

Thanks,
Harshil

@randallwhitman
Copy link
Contributor

Harshil, would you be able to submit a merge/pull request? In your patch, please adapt the build.xml snippet in your original comment to declare a property for the maven-ant-tasks version rather than hardcoding 2.1.3 inline. Thanks.
@harshil1234

@harshil1234
Copy link
Author

Hi Randall, Yes I can do that, one question so I had manually copied this jar file at this location: ../lib/maven-ant-tasks-2.1.3.jar. So you are ok with jar file being copied at this location.

@randallwhitman
Copy link
Contributor

Ideally it would pick up the maven-ant-tasks jar location from the default location in the OS.
Second choice would be a property for the location, which I guess would be necessary anyway to override a default.

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

2 participants