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

document requirements and build procedure #10

Open
bertsky opened this issue Nov 13, 2020 · 8 comments
Open

document requirements and build procedure #10

bertsky opened this issue Nov 13, 2020 · 8 comments

Comments

@bertsky
Copy link
Contributor

bertsky commented Nov 13, 2020

I understand one needs to install Eclipse and import each of the directories under java? (If so, please make this explicit and prominent in the README. It may sound trivial, but other PRImA components depend on this and have no pre-builts, so non-Java / non-Eclipse developers will already stumble here.)

However, I get the following build errors I am unable to get around:

Project 'PrimaDla' is missing required Java project: 'json-simple-tag_release_1_1_1'

I even cloned https://github.com/fangyidong/json-simple and imported it into Eclipse, checkout out release 1.1.1 and had Eclipse rebuild (after deactivating the tests, which would not compile under OpenJDK 11). But it seems like the exported name is different and I have no idea how to set it to 'json-simple-tag_release_1_1_1 as required by PrimaDla.

@maxnth
Copy link
Contributor

maxnth commented Nov 13, 2020

Not sure if this is helpful but I use IntelliJ IDEA to build prima-core-libs and adding the json-simple-1.1.1 jar as Library works for me (using Java 1.8 as target).

@chris1010010
Copy link
Contributor

Will do at some point, thanks

@bertsky
Copy link
Contributor Author

bertsky commented Nov 13, 2020

Not sure if this is helpful but I use IntelliJ IDEA to build prima-core-libs

I don't want to get into yet another IDE I don't know well. If @chris1010010 says Eclipse is recommended, Eclipse it is (for me).

and adding the json-simple-1.1.1 jar as Library works for me (using Java 1.8 as target).

No luck with that (or JAR I built from within Eclipse or linking the classes from the json-simple project directly). I have even started fiddling with the destination and package names in json-simple's build.xml but the failing dependency in PrimaDla never goes away. (Plus I have no idea where to look for build artifacts – it's all hidden away in Eclipse.)

@chris1010010
Copy link
Contributor

image
That's how I have it set up, if that helps. No time to update documentation or releases right now

@bertsky
Copy link
Contributor Author

bertsky commented Nov 13, 2020

That's how I have it set up, if that helps. No time to update documentation or releases right now

It did – thanks!

So I had to change the Projects settings (which is where your published .project configured the json-simple-tag_release_1_1_1 dependency, instead of under Libraries).

prima-core-libs build completely now. On to the prima-gwt-lib problems...

@mikegerber
Copy link

I stumbled over this today, too.

I am not 100% sure about this, due to build problems, but I also think the latest release is outdated and does not contain org.primaresearch.dla.page.io.xml.XmlPageWriter_Alto yet, which is required for building PRImA-Research-Lab/prima-page-converter.

@chris1010010
Copy link
Contributor

I'll have a look as soon as I can, sorry for that

@mikegerber
Copy link

This build.gradle file seems to do the job at least partly:

plugins {
    id 'java-library'
}
apply plugin: 'eclipse'

sourceSets {
    main {
        java {
          srcDir 'java/PrimaBasic/src'
          srcDir 'java/PrimaDla/src'
          srcDir 'java/PrimaIo/src'
          srcDir 'java/PrimaMaths/src'
        }
    }
}


repositories {
    mavenCentral()
}

dependencies {
    implementation 'com.googlecode.json-simple:json-simple:1.1.1'
}

This builds the project, when using the fix in #11, but does not build 4 JARs as in the releases, but only one - which almost* lets prima-page-converter build.

(* There is another issue I'll investigate later)

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

4 participants