-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathcreate-java-app.nix
More file actions
executable file
·33 lines (28 loc) · 1001 Bytes
/
create-java-app.nix
File metadata and controls
executable file
·33 lines (28 loc) · 1001 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
{ nixpkgs ? ../nixpkgs
, webdsl ? {outPath = builtins.storePath /nix/store/fsvgski1a52w9373yq09qraa77r666ij-webdsl-java-0pre5668;}
, nixos ? ../nixos
, reposearchSrc ? { outPath = ../reposearch; rev = 1234; }
}:
let
pkgs = import nixpkgs { system = "i686-linux"; };
build = appname : src :
pkgs.stdenv.mkDerivation rec {
name = "${appname}-r${toString src.rev}";
buildInputs = [webdsl pkgs.ant pkgs.openjdk pkgs.zip];
buildCommand = ''
ensureDir $out/nix-support
ulimit -s unlimited
export ANT_ARGS="-lib `ls ${pkgs.hydraAntLogger}/lib/java/*.jar | head -1`"
export ANT_LOGGER="org.hydra.ant.HydraLogger"
header "Copying sources"
cp -vR ${src}/* .
chmod -R 755 .
./create-java-app.sh
zip -r $out/reposearch-app.zip reposearch-app/
echo "file zip $out/reposearch-app.zip" > $out/nix-support/hydra-build-products
'';
};
in
{
reposearch-app = build "reposearch-app" reposearchSrc;
}