Hi there,
I would like to package nodebox but I am stuck. Till now I have the following code
{
lib,
stdenv,
fetchFromGitHub,
jre,
makeWrapper,
maven,
}:
maven.buildMavenPackage rec {
pname = "nodebox";
version = "3.0.53";
src = fetchFromGitHub {
owner = "nodebox";
repo = "nodebox";
rev = "v${version}";
hash = "sha256-IJw83rtsl3yRQ2ZOWlqTgHomE+qpEQeqH/81aQvr+Fw=";
};
mvnHash = "sha256-00CBcvl7WBSyNZH9ySHXYyrv9kLAKBfsurtGIvigKZU=";
nativeBuildInputs = [ makeWrapper ];
doCheck = false; # TODO fix
installPhase = ''
mkdir -p $out/bin $out/share/nodebox
install -Dm644 target/nodebox-3.0.44.jar $out/share/nodebox
makeWrapper ${jre}/bin/java $out/bin/nodebox \
--add-flags "-jar $out/share/nodebox/nodebox-3.0.44.jar"
'';
meta = {
description = "Node-based data application for visualization and generative design";
homepage = "https://github.com/nodebox/nodebox.git";
license = lib.licenses.unfree; # FIXME: nix-init did not find a license
maintainers = with lib.maintainers; [ ];
mainProgram = "nodebox";
platforms = lib.platforms.all;
};
}
This creates a derivation but when I try to run it, I get the error message no main manifest attribute, in /nix/store/slswf3aj88n3dqqhqcbbbb732yjyjlda-nodebox-3.0.53/share/nodebox/nodebox-3.0.44.jar
.
When I omit the doCheck=false;
the system complains about missing dev dependencies
> [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.2.5:test (default-test) on project nodebox: The following artifacts could not be resolved: org.apache.maven.surefire:surefire-junit4:jar:3.2.5 (absent): Cannot access central (https://repo.maven.apache.org/maven2) in offline mode and the artifact org.apache.maven.surefire:surefire-junit4:jar:3.2.5 has not been downloaded from it before. -> [Help 1]
> [ERROR]
> [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
> [ERROR] Re-run Maven using the -X switch to enable full debug logging.
> [ERROR]
> [ERROR] For more information about the errors and possible solutions, please read the following articles:
> [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
I am not familiar with the java enviroment. Does anybody have a hint what I could do to get this fixed?
Thank you in advance