Last active
December 23, 2015 08:09
-
-
Save joelthompson/7f7a716bf3b16599c051 to your computer and use it in GitHub Desktop.
osv java bug repro
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Hello | |
{ | |
public static void main(String[] args) | |
{ | |
System.out.println("Hello, World!"); | |
java.nio.file.Path path = java.nio.file.Paths.get("/"); | |
System.out.println("Path is " + path); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Copyright (C) 2013 Cloudius Systems, Ltd. | |
# | |
# This work is open source software, licensed under the terms of the | |
# BSD license as described in the LICENSE file in the top-level directory. | |
# | |
.PHONY: module clean | |
jvm_dir=install/usr/lib/jvm | |
#java_version=$(shell ./latest.sh java-1.8.0-openjdk-headless x86_64) | |
#java_dir=http://mirrors.kernel.org/fedora/development/rawhide/x86_64/os/Packages/j/ | |
java_version=1.8.0.65-3.b17.fc22 | |
java_dir=https://kojipkgs.fedoraproject.org//packages/java-1.8.0-openjdk/1.8.0.65/3.b17.fc22/x86_64/ | |
java_fullname=java-1.8.0-openjdk-headless-$(java_version).x86_64.rpm | |
tzdata_version=$(shell ./latest.sh tzdata-java noarch) | |
tzdata_dir=http://mirrors.kernel.org/fedora/development/rawhide/x86_64/os/Packages/t/ | |
tzdata_fullname=tzdata-java-$(tzdata_version).noarch.rpm | |
SRC = $(shell readlink -f ../..) | |
module: | |
cd $(SRC)/java && mvn package -q -DskipTests=true | |
mkdir -p upstream | |
wget -c -O upstream/$(java_fullname) $(java_dir)$(java_fullname) | |
wget -c -O upstream/$(tzdata_fullname) $(tzdata_dir)$(tzdata_fullname) | |
rm -rf install | |
mkdir -p install | |
rpm2cpio upstream/$(java_fullname) | (cd install && cpio -id) | |
ln -sf java-1.8.0-openjdk-$(java_version).x86_64 $(jvm_dir)/java | |
rm -rf $(jvm_dir)/java/jre/lib/security/cacerts | |
rm -rf $(jvm_dir)/java/jre/lib/audio/* | |
rpm2cpio upstream/$(tzdata_fullname) | (cd install && cpio -id) | |
cp $(SRC)/java/runjava/target/runjava.jar install/usr/lib/jvm/java/jre/lib/ext/ | |
ln -s /etc/pki/java/cacerts install/usr/lib/jvm/java/jre/lib/security/ | |
clean: | |
rm -rf upstream install | |
cd $(SRC)/java && mvn clean -q | |
-rm -f dependency-reduced-pom.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
git clone https://github.com/cloudius-systems/osv.git --recursive | |
cd osv | |
sudo scripts/setup.py | |
make | |
cp -R apps/java-example apps/java-repro | |
wget -O apps/java-repro/Hello.java 'https://gist.githubusercontent.com/joelthompson/7f7a716bf3b16599c051/raw/39088e7fd94775c8059755dc3d58cc32ba38e6b3/Hello.java' | |
scripts/build-capstan-img java-nio-repro openjdk8-fedora,java-repro "App showing java.nio issues" | |
scripts/run.py -V | |
### Observe crash | |
### Kill qemu | |
wget -O apps/openjdk8-fedora/Makefile 'https://gist.githubusercontent.com/joelthompson/7f7a716bf3b16599c051/raw/f56215f35f180f8b738336618c0da9e3a18311f8/Makefile' | |
scripts/build-capstan-img java-nio-repro openjdk8-fedora,java-repro "App showing java.nio issues" | |
scripts/run.py -V | |
### No crash |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment