mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-24 20:02:58 +03:00
openjdk-bootstrap: nukerefs the whole thing and put it in a tarball
This commit is contained in:
parent
6ed6d1c5c0
commit
a4b39fac65
@ -1,19 +1,24 @@
|
||||
{ runCommand, openjdk }:
|
||||
{ runCommand, openjdk, nukeReferences }:
|
||||
|
||||
let arch = if openjdk.system == "x86_64-linux" then "amd64" else "i386"; in
|
||||
|
||||
runCommand "${openjdk.name}-bootstrap" {} ''
|
||||
mkdir -p $out/bin
|
||||
mkdir -p $out/lib
|
||||
mkdir -p $out/jre/lib/{security,ext,${arch}/{jli,server,headless}}
|
||||
cp ${openjdk}/bin/{idlj,ja{va{,c,p,h},r},rmic} $out/bin
|
||||
cp ${openjdk}/lib/tools.jar $out/lib
|
||||
cp ${openjdk}/jre/lib/{meta-index,{charsets,jce,jsse,rt,resources}.jar,currency.data} $out/jre/lib
|
||||
cp ${openjdk}/jre/lib/security/java.security $out/jre/lib/security
|
||||
cp ${openjdk}/jre/lib/ext/{meta-index,sunjce_provider.jar} $out/jre/lib/ext
|
||||
cp ${openjdk}/jre/lib/${arch}/{jvm.cfg,lib{awt,java,verify,zip,nio,net}.so} $out/jre/lib/${arch}
|
||||
cp ${openjdk}/jre/lib/${arch}/jli/libjli.so $out/jre/lib/${arch}/jli
|
||||
cp ${openjdk}/jre/lib/${arch}/server/libjvm.so $out/jre/lib/${arch}/server
|
||||
cp ${openjdk}/jre/lib/${arch}/headless/libmawt.so $out/jre/lib/${arch}/headless
|
||||
cp -a ${openjdk}/include $out
|
||||
runCommand "${openjdk.name}-bootstrap.tar.xz" {} ''
|
||||
mkdir -p openjdk-bootstrap/bin
|
||||
mkdir -p openjdk-bootstrap/lib
|
||||
mkdir -p openjdk-bootstrap/jre/lib/{security,ext,${arch}/{jli,server,headless}}
|
||||
cp ${openjdk}/bin/{idlj,ja{va{,c,p,h},r},rmic} openjdk-bootstrap/bin
|
||||
cp ${openjdk}/lib/tools.jar openjdk-bootstrap/lib
|
||||
cp ${openjdk}/jre/lib/{meta-index,{charsets,jce,jsse,rt,resources}.jar,currency.data} openjdk-bootstrap/jre/lib
|
||||
cp ${openjdk}/jre/lib/security/java.security openjdk-bootstrap/jre/lib/security
|
||||
cp ${openjdk}/jre/lib/ext/{meta-index,sunjce_provider.jar} openjdk-bootstrap/jre/lib/ext
|
||||
cp ${openjdk}/jre/lib/${arch}/{jvm.cfg,lib{awt,java,verify,zip,nio,net}.so} openjdk-bootstrap/jre/lib/${arch}
|
||||
cp ${openjdk}/jre/lib/${arch}/jli/libjli.so openjdk-bootstrap/jre/lib/${arch}/jli
|
||||
cp ${openjdk}/jre/lib/${arch}/server/libjvm.so openjdk-bootstrap/jre/lib/${arch}/server
|
||||
cp ${openjdk}/jre/lib/${arch}/headless/libmawt.so openjdk-bootstrap/jre/lib/${arch}/headless
|
||||
cp -a ${openjdk}/include openjdk-bootstrap
|
||||
|
||||
chmod -R +w openjdk-bootstrap
|
||||
find openjdk-bootstrap -print0 | xargs -0 ${nukeReferences}/bin/nuke-refs
|
||||
|
||||
tar cv openjdk-bootstrap | xz > $out
|
||||
''
|
||||
|
Loading…
Reference in New Issue
Block a user