Merge pull request #1 from sampottinger/master

Java 11, OpenJDK, ANTLR 4, and Travis
This commit is contained in:
Ben Fry
2019-10-07 16:53:54 -04:00
committed by GitHub
321 changed files with 16494 additions and 8817 deletions

1
.gitignore vendored
View File

@@ -1,5 +1,6 @@
.DS_Store
.AppleDouble
*.iml
._*
*~
/build/shared/reference.zip

26
.travis.yml Normal file
View File

@@ -0,0 +1,26 @@
git:
depth: 1
language: java
jdk:
- openjdk11
before_install:
- sudo apt-get -qq update
- sudo apt-get install ant-optional
- sudo apt-get install wget
- wget --no-check-certificate https://www-us.apache.org/dist//ant/binaries/apache-ant-1.10.7-bin.tar.gz
- tar -xzvf apache-ant-1.10.7-bin.tar.gz
- export PATH=`pwd`/apache-ant-1.10.7/bin:$PATH
services:
- xvfb
before_script:
- export DISPLAY=:99.0
- cd build
script:
- ant clean
- ant build

1009
LICENSE.md Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -13,14 +13,14 @@
<fail unless="core-built" message="Please build the core library first and make sure it is located at ../core/library/core.jar" />
<mkdir dir="bin" />
<!-- copy languages files -->
<copy todir="bin">
<fileset dir="src">
<include name="processing/app/languages/*.properties" />
</fileset>
</copy>
<!-- in some cases, pde.jar was not getting built
https://github.com/processing/processing/issues/1792 -->
<delete file="pde.jar" />
@@ -30,22 +30,19 @@
<javac source="1.8"
target="1.8"
destdir="bin"
excludes="**/tools/format/**"
encoding="UTF-8"
includeAntRuntime="false"
classpath="../core/library/core.jar;
../core/apple.jar;
lib/ant.jar;
lib/ant-launcher.jar;
destdir="bin"
excludes="**/tools/format/**"
encoding="UTF-8"
includeAntRuntime="false"
classpath="../core/library/core.jar;
../core/apple.jar;
lib/ant.jar;
lib/ant-launcher.jar;
lib/jna.jar;
lib/jna-platform.jar"
debug="on"
nowarn="true"
compiler="org.eclipse.jdt.core.JDTCompilerAdapter">
nowarn="true">
<src path="src" />
<compilerclasspath path="../java/mode/org.eclipse.jdt.core.jar;
../java/mode/jdtCompilerAdapter.jar" />
</javac>
</target>

Binary file not shown.

Binary file not shown.

View File

@@ -75,6 +75,10 @@ public class Platform {
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
static public boolean isInit() {
return inst != null;
}
static public void init() {
try {
@@ -339,10 +343,10 @@ public class Platform {
File[] plugins = getContentFile("../PlugIns").listFiles(new FilenameFilter() {
public boolean accept(File dir, String name) {
return dir.isDirectory() &&
name.endsWith(".jdk") && !name.startsWith(".");
name.contains("jdk") && !name.startsWith(".");
}
});
return new File(plugins[0], "Contents/Home/jre");
return new File(plugins[0], "Contents/Home");
}
// On all other platforms, it's the 'java' folder adjacent to Processing
return getContentFile("java");
@@ -412,4 +416,4 @@ public class Platform {
static public int getSystemDPI() {
return inst.getSystemDPI();
}
}
}

View File

@@ -40,20 +40,6 @@ public class LinuxPlatform extends DefaultPlatform {
public void initBase(Base base) {
super.initBase(base);
String javaVendor = System.getProperty("java.vendor");
String javaVM = System.getProperty("java.vm.name");
if (javaVendor == null ||
(!javaVendor.contains("Sun") && !javaVendor.contains("Oracle")) ||
javaVM == null || !javaVM.contains("Java")) {
Messages.showWarning("Not fond of this Java VM",
"Processing requires Java 8 from Oracle.\n" +
"Other versions such as OpenJDK, IcedTea,\n" +
"and GCJ are strongly discouraged. Among other things, you're\n" +
"likely to run into problems with sketch window size and\n" +
"placement. For more background, please read the wiki:\n" +
"https://github.com/processing/processing/wiki/Supported-Platforms#linux", null);
}
// Set x11 WM_CLASS property which is used as the application
// name by Gnome3 and other window managers.
// https://github.com/processing/processing/issues/2534

View File

@@ -24,11 +24,15 @@ package processing.app.platform;
import java.awt.event.*;
import java.io.File;
import java.lang.reflect.InvocationHandler;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.lang.reflect.Proxy;
import java.util.List;
import javax.swing.*;
import com.apple.eawt.*;
import com.apple.eawt.AppEvent.*;
import com.apple.eawt.Application;
import processing.app.*;
import processing.app.ui.About;
@@ -65,44 +69,40 @@ public class ThinkDifferent {
if (adapter == null) {
adapter = new ThinkDifferent(); //base);
}
application.setAboutHandler(new AboutHandler() {
public void handleAbout(AboutEvent ae) {
new About(null);
}
});
application.setPreferencesHandler(new PreferencesHandler() {
public void handlePreferences(PreferencesEvent arg0) {
base.handlePrefs();
}
setHandler(application, "setAboutHandler", (proxy, method, args) -> {
new About(null);
return null;
});
application.setOpenFileHandler(new OpenFilesHandler() {
public void openFiles(OpenFilesEvent event) {
for (File file : event.getFiles()) {
base.handleOpen(file.getAbsolutePath());
}
}
});
application.setPrintFileHandler(new PrintFilesHandler() {
public void printFiles(PrintFilesEvent event) {
// TODO not yet implemented
}
});
application.setQuitHandler(new QuitHandler() {
public void handleQuitRequestWith(QuitEvent event, QuitResponse response) {
if (base.handleQuit()) {
response.performQuit();
} else {
response.cancelQuit();
}
}
setHandler(application, "setPreferencesHandler", (proxy, method, args) -> {
base.handlePrefs();
return null;
});
// Set the menubar to be used when nothing else is open.
setHandler(application, "setOpenFileHandler", (proxy, method, args) -> {
Method m = args[0].getClass().getMethod("getFiles");
for (File file : (List<File>) m.invoke(args[0])) {
base.handleOpen(file.getAbsolutePath());
}
return null;
});
setHandler(application, "setPrintFileHandler", (proxy, method, args) -> {
// TODO not yet implemented
return null;
});
setHandler(application, "setQuitHandler", (proxy, method, args) -> {
if (base.handleQuit()) {
args[1].getClass().getMethod("performQuit").invoke(args[1]);
} else {
args[1].getClass().getMethod("cancelQuit").invoke(args[1]);
}
return null;
});
// Set the menubar to be used when nothing else is open.
JMenuBar defaultMenuBar = new JMenuBar();
JMenu fileMenu = buildFileMenu(base);
defaultMenuBar.add(fileMenu);
@@ -117,12 +117,12 @@ public class ThinkDifferent {
e.printStackTrace(); // oh well, never mind
}
// } else {
// // The douchebags at Oracle didn't feel that a working f*king menubar
// // on OS X was important enough to make it into the 7u40 release.
// // The douchebags at Oracle didn't feel that a working f*king menubar
// // on OS X was important enough to make it into the 7u40 release.
// //http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=8007267
// // It languished in the JDK 8 source and has been backported for 7u60:
// //http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=8022667
//
//
// JFrame offscreen = new JFrame();
// offscreen.setUndecorated(true);
// offscreen.setJMenuBar(defaultMenuBar);
@@ -131,12 +131,51 @@ public class ThinkDifferent {
// offscreen.setVisible(true);
// }
}
// public ThinkDifferent(Base base) {
// this.base = base;
// }
/**
* Sets a handler on an instance of {@link Application}, taking into account JVM version
* differences.
*
* @param app an instance of {@link Application}
* @param name the "set handler" method name
* @param handler the handler
*/
private static void setHandler(Application app, String name, InvocationHandler handler) {
// Determine which version of com.apple.eawt.Application to use and pass it a handler of the
// appropriate type
Method[] methods = app.getClass().getMethods();
for (Method m : methods) {
if (!name.equals(m.getName())) {
continue;
}
if (m.getParameterCount() != 1) {
continue;
}
Class paramType = m.getParameterTypes()[0];
try {
// Allow a null handler
Object proxy = null;
if (handler != null) {
proxy = Proxy.newProxyInstance(
paramType.getClassLoader(), new Class<?>[] { paramType }, handler);
}
m.invoke(app, proxy);
} catch (IllegalArgumentException ex) {
// TODO: Print error?: method doesn't take an interface, etc.
} catch (IllegalAccessException ex) {
// TODO: Print error?: Other method invocation problem
} catch (InvocationTargetException ex) {
ex.getCause().printStackTrace();
// TODO: Print ex.getCause() a different way?
}
break;
}
}
/**
* Gimpy file menu to be used on OS X when no sketches are open.
@@ -162,7 +201,7 @@ public class ThinkDifferent {
fileMenu.add(item);
item = Toolkit.newJMenuItemShift(Language.text("menu.file.sketchbook"), 'K');
item.addActionListener(new ActionListener() {
item.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
base.getNextMode().showSketchbookFrame();

View File

@@ -64,10 +64,16 @@ public class WindowsPlatform extends DefaultPlatform {
"\\" + APP_NAME.toLowerCase() + ".exe \"%1\"";
static final String REG_DOC = APP_NAME + ".Document";
// Starting with Java 9, the scaling is done automatically. If DPI is
// used to scaling within the application, one ends up with 2x the
// expected scale. See JEP 263.
private static final int WINDOWS_NATIVE_DPI = 96;
public void initBase(Base base) {
super.initBase(base);
checkAssociations();
//checkQuickTime();
checkPath();
@@ -627,56 +633,9 @@ public class WindowsPlatform extends DefaultPlatform {
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
// Need to extend com.sun.jna.platform.win32.User32 to access
// Win32 function GetDpiForSystem()
interface ExtUser32 extends StdCallLibrary, com.sun.jna.platform.win32.User32 {
ExtUser32 INSTANCE = (ExtUser32) Native.loadLibrary("user32", ExtUser32.class, W32APIOptions.DEFAULT_OPTIONS);
public int GetDpiForSystem();
public int SetProcessDpiAwareness(int value);
public final int DPI_AWARENESS_INVALID = -1;
public final int DPI_AWARENESS_UNAWARE = 0;
public final int DPI_AWARENESS_SYSTEM_AWARE = 1;
public final int DPI_AWARENESS_PER_MONITOR_AWARE = 2;
public Pointer SetThreadDpiAwarenessContext(Pointer dpiContext);
public final Pointer DPI_AWARENESS_CONTEXT_UNAWARE = new Pointer(-1);
public final Pointer DPI_AWARENESS_CONTEXT_SYSTEM_AWARE = new Pointer(-2);
public final Pointer DPI_AWARENESS_CONTEXT_PER_MONITOR_AWARE = new Pointer(-3);
}
static private int detected = detectSystemDPI();
public int getSystemDPI() {
if (detected == -1) {
return super.getSystemDPI();
}
return detected;
// Note that this is supported "natively" within Java - See JEP 263.
return WINDOWS_NATIVE_DPI;
}
public static int detectSystemDPI() {
try {
ExtUser32.INSTANCE.SetProcessDpiAwareness(ExtUser32.DPI_AWARENESS_SYSTEM_AWARE);
} catch (Throwable e) {
// Ignore error
}
try {
ExtUser32.INSTANCE.SetThreadDpiAwarenessContext(ExtUser32.DPI_AWARENESS_CONTEXT_SYSTEM_AWARE);
} catch (Throwable e) {
// Ignore error (call valid only on Windows 10)
}
try {
return ExtUser32.INSTANCE.GetDpiForSystem();
} catch (Throwable e) {
// DPI detection failed, fall back with default
System.out.println("DPI detection failed, fallback to 96 dpi");
return -1;
}
}
}

View File

@@ -76,12 +76,17 @@ public class JEditTextArea extends JComponent
/** The size of the offset between the leftmost padding and the code */
public static final int leftHandGutter = 6;
private final Segment TEST_SEGMENT;
private InputMethodSupport inputMethodSupport;
private TextAreaDefaults defaults;
private Brackets bracketHelper = new Brackets();
private FontMetrics cachedPartialPixelWidthFont;
private float partialPixelWidth;
/**
* Creates a new JEditTextArea with the specified settings.
@@ -90,6 +95,9 @@ public class JEditTextArea extends JComponent
public JEditTextArea(TextAreaDefaults defaults, InputHandler inputHandler) {
this.defaults = defaults;
char[] testSegmentContents = {'w'};
TEST_SEGMENT = new Segment(testSegmentContents, 0, 1);
// Enable the necessary events
enableEvents(AWTEvent.KEY_EVENT_MASK);
@@ -113,6 +121,8 @@ public class JEditTextArea extends JComponent
lineSegment = new Segment();
bracketLine = bracketPosition = -1;
blink = true;
cachedPartialPixelWidthFont = null;
partialPixelWidth = 0;
// Initialize the GUI
setLayout(new ScrollLayout());
@@ -632,7 +642,7 @@ public class JEditTextArea extends JComponent
// If syntax coloring is disabled, do simple translation
if (tokenMarker == null) {
lineSegment.count = offset;
return x + Utilities.getTabbedTextWidth(lineSegment, fm, x, painter, 0);
return x + getTabbedTextWidth(lineSegment, fm, x, painter, 0);
} else {
// If syntax coloring is enabled, we have to do this
@@ -664,10 +674,10 @@ public class JEditTextArea extends JComponent
int length = tokens.length;
if (offset + segmentOffset < lineSegment.offset + length) {
lineSegment.count = offset - (lineSegment.offset - segmentOffset);
return x + Utilities.getTabbedTextWidth(lineSegment, fm, x, painter, 0);
return x + getTabbedTextWidth(lineSegment, fm, x, painter, 0);
} else {
lineSegment.count = length;
x += Utilities.getTabbedTextWidth(lineSegment, fm, x, painter, 0);
x += getTabbedTextWidth(lineSegment, fm, x, painter, 0);
lineSegment.offset += length;
}
tokens = tokens.next;
@@ -1310,6 +1320,72 @@ public class JEditTextArea extends JComponent
return CharacterKinds.Other;
}
/**
* Get the width in pixels of a segment of text within the IDE.
*
* <p>
* Fractional-font aware implementation of Utilities.getTabbedTextWidth that determines if there
* are fractional character widths present in a font in order to return a more accurate pixel
* width for an input segment.
* </p>
*
* @param s The segment of text for which a pixel width should be returned.
* @param metrics The metrics for the font in which the given segment will be drawn.
* @param x The x origin.
* @param expander The strategy for converting tabs into characters.
* @param startOffset The offset to apply before the text will be drawn.
* @return The width of the input segment in pixels with fractional character widths considered.
*/
private int getTabbedTextWidth(Segment s, FontMetrics metrics, float x, TabExpander expander,
int startOffset) {
float additionalOffset = getPartialPixelWidth(metrics, x, expander, startOffset) * s.length();
return (int) Math.round(
Utilities.getTabbedTextWidth(s, metrics, x, expander, startOffset) + additionalOffset
);
}
/**
* Get any partial widths applied within a font.
*
* <p>
* Get any partial widths applied within a font, caching results for the latest requested font
* (as identified via a FontMetrics object). Note that this is calculated for a sample character
* and is only valid for extrapolation in a monospaced font (that one might want to use in an
* IDE).
* </p>
*
* @param candidateMetrics The FontMetrics for which partial character pixel widths should be
* returned.
* @param x The x origin.
* @param expander The strategy for converting tabs into characters.
* @param startOffset The offset to apply before the text will be drawn.
* @return The partial width of a sample character within a font.
*/
private float getPartialPixelWidth(FontMetrics candidateMetrics, float x, TabExpander expander,
int startOffset) {
// See https://github.com/sampottinger/processing/issues/103
// Requires reference not object equality check
if (candidateMetrics != cachedPartialPixelWidthFont) {
float withFractional = Utilities.getTabbedTextWidth(
TEST_SEGMENT,
candidateMetrics,
x,
expander,
startOffset
);
int withoutFractional = (int) withFractional;
partialPixelWidth = withFractional - withoutFractional;
cachedPartialPixelWidthFont = candidateMetrics;
}
return partialPixelWidth;
}
protected void setNewSelectionWord( int line, int offset )
{
if (getLineLength(line) == 0) {

View File

@@ -161,4 +161,4 @@ public class InstallCommander implements Tool {
list.append(jar.getAbsolutePath());
}
}
}
}

View File

@@ -2898,7 +2898,6 @@ public abstract class Editor extends JFrame implements RunnerListener {
* Show an exception in the editor status bar.
*/
public void statusError(Exception e) {
e.printStackTrace();
// if (e == null) {
// System.err.println("Editor.statusError() was passed a null exception.");
// return;
@@ -2909,9 +2908,7 @@ public abstract class Editor extends JFrame implements RunnerListener {
// Make sure something is printed into the console
// Status bar is volatile
if (!re.isStackTraceEnabled()) {
System.err.println(re.getMessage());
}
System.err.println(re.getMessage());
// Move the cursor to the line before updating the status bar, otherwise
// status message might get hidden by a potential message caused by moving
@@ -2940,6 +2937,8 @@ public abstract class Editor extends JFrame implements RunnerListener {
textarea.getLineStopOffset(line) - 1);
}
}
} else {
e.printStackTrace();
}
// Since this will catch all Exception types, spend some time figuring

View File

@@ -1,53 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.io.Serializable;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class annotations extends PApplet {
public void setup() {
size(200,200);
}
@Deprecated
public void banana() {
println("hey");
}
@SuppressWarnings({"serial", "rawtypes"})
class Banana implements Serializable {
}
@SuppressWarnings("serial")
class Apple implements Serializable {
}
@javax.annotation.Generated(value = {"com.mrfeinberg.ImmortalAroma"
},
comments="Shazam!",
date="2001-07-04T12:08:56.235-0700")
class Pear {}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "annotations" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,29 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug1064 extends PApplet {
public void setup() {
// import ";
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug1064" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,41 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.Collections;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug136 extends PApplet {
java.util.List alist = Collections.synchronizedList(new ArrayList());
public void setup() {
size(400, 200);
alist.add("hello");
}
public void draw() {
rect(width/4, height/4, width/2, height/2);
synchronized(alist) {
alist.get(0);
}
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug136" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,29 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug1362 extends PApplet {
public void setup() {
if (true) {} else { new String(); }
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug1362" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,28 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug1442 extends PApplet {
public float a() {
return 1.0f;
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug1442" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,37 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.io.StringWriter;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug1511 extends PApplet {
public void setup() {
// \u00df
/**
* a
*/
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug1511" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,29 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug1512 extends PApplet {
public void setup() {
println("oi/*");
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug1512" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,45 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.ArrayList;
import java.util.List;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug1518a extends PApplet {
public void setup()
{
List<String> list = new ArrayList<String>();
list.add("foo");
list.add("bar");
list.add("baz");
binarySearch(list, "bar");
}
static <T> int binarySearch(List<? extends Comparable<? super T>> list, T
key) {
return 0;
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug1518a" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,43 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.ArrayList;
import java.util.List;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug1518b extends PApplet {
public void setup()
{
List<String> list = new ArrayList<String>();
list.add("foo");
list.add("bar");
list.add("baz");
}
static <T> int binarySearch(List<? extends Comparable<? super T>> list, T
key) {
return 0;
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug1518b" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,9 +0,0 @@
import java.util.ArrayList;
import java.util.List;
void setup()
{
List<String> list = new ArrayList<String>();
List<List<String>>> listOfLists = new ArrayList<List<String>>();
listOfLists.add(list);
}

View File

@@ -1,31 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug1525 extends PApplet {
public void setup() {
if (frameCount > (frameRate - 1)) {
println("My head asplode!");
}
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug1525" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,29 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug1534 extends PApplet {
public void setup() {
char c = '\"';
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug1534" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,9 +0,0 @@
println("Here comes an unterminated comment!")
/*
banana
apple
pear
* /
println("Do you see what I did there?")

View File

@@ -1,29 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug1936 extends PApplet {
public void setup() {
char a = PApplet.parseChar(PApplet.parseByte(PApplet.parseInt("15")));
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug1936" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,32 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug281 extends PApplet {
public void setup() {
if ( "monopoly".charAt( 3 ) == '(' )
{
println("parcheesi");
}
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug281" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,35 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug315g extends PApplet {
public void setup() {
size(480, 120);
smooth();
int y;
y = 60;
int d;
d = 80;
ellipse(75, y, d, d);
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug315g" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,30 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug4 extends PApplet {
public void setup() {
int x = 12;
float u = (PApplet.parseFloat(x)/width);
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug4" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,2 +0,0 @@
int x = 12;
float u = (float(x)/width);

View File

@@ -1,34 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug400g extends PApplet {
////
public void setup(){
size(100,100);
if(true){
}
else{ // Syntax error on token "else", } expected
}
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug400g" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,3 +0,0 @@
for (int i : new int[] {1,2,3}) {
println(i);
}

View File

@@ -1,6 +0,0 @@
int[] a = new int[] {
1, 2, 3, 4, 5
};
for (int i: a) {
print(i);
}

View File

@@ -1,38 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug427g extends PApplet {
static final boolean DEBUG = true;
public void setup() {
MyClass x = new MyClass();
}
public class MyClass {
public MyClass() {
if (DEBUG) println("Debug");
}
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug427g" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,32 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.applet.Applet;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug481 extends PApplet {
public void setup() {
Class[] abc = new Class[]{Applet.class};
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug481" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,70 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import static java.lang.Math.tanh;
import java.util.concurrent.Callable;
import java.util.List;
import java.util.Comparator;
import java.util.Map;
import java.util.Collection;
import java.util.Arrays;
import java.util.HashSet;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug598 extends PApplet {
// java 5 torture test
private static Comparator<String> rotarapmoc = new Comparator<String>() {
public int compare(final String o1, final String o2)
{
return o1.charAt(o1.length() - 1) - o2.charAt(o2.length() - 1);
}
};
final <T> void printClass(T t) {
println(t.getClass());
}
public final List<String> sortem(final String... strings) {
Arrays.sort(strings, rotarapmoc);
return Arrays.asList(strings);
}
final Map<String, Collection<Integer>>
charlesDeGaulle = new HashMap<String, Collection<Integer>>();
public void setup() {
charlesDeGaulle.put("banana", new HashSet<Integer>());
charlesDeGaulle.get("banana").add(0);
System.out.println(sortem("aztec", "maya", "spanish", "portuguese"));
printClass(12.d);
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug598" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,30 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug5a extends PApplet {
public void setup() {
println("The next line should not cause a failure.");
// no newline after me
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug5a" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,30 +0,0 @@
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;
import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
public class bug5b extends PApplet {
public void setup() {
println("The next line should not cause a failure.");
/* no newline after me */
noLoop();
}
static public void main(String[] passedArgs) {
String[] appletArgs = new String[] { "bug5b" };
if (passedArgs != null) {
PApplet.main(concat(appletArgs, passedArgs));
} else {
PApplet.main(appletArgs);
}
}
}

View File

@@ -1,304 +0,0 @@
package test.processing.mode.java;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.fail;
import static test.processing.mode.java.ProcessingTestUtil.COMPILER;
import static test.processing.mode.java.ProcessingTestUtil.preprocess;
import static test.processing.mode.java.ProcessingTestUtil.res;
import java.io.File;
import java.io.FileWriter;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import org.junit.BeforeClass;
import org.junit.Test;
import processing.app.SketchException;
import processing.app.exec.ProcessResult;
import antlr.RecognitionException;
public class ParserTests {
@BeforeClass
public static void init() {
ProcessingTestUtil.init();
}
static void expectRecognitionException(final String id,
final String expectedMessage,
final int expectedLine) {
try {
preprocess(id, res(id + ".pde"));
fail("Expected to fail with \"" + expectedMessage + "\" on line "
+ expectedLine);
} catch (RecognitionException e) {
assertEquals(expectedMessage, e.getMessage());
assertEquals(expectedLine, e.getLine());
} catch (Exception e) {
if (!e.equals(e.getCause()) && e.getCause() != null)
fail(e.getCause().toString());
else
fail(e.toString());
}
}
static void expectRunnerException(final String id,
final String expectedMessage,
final int expectedLine) {
try {
preprocess(id, res(id + ".pde"));
fail("Expected to fail with \"" + expectedMessage + "\" on line "
+ expectedLine);
} catch (SketchException e) {
assertEquals(expectedMessage, e.getMessage());
assertEquals(expectedLine, e.getCodeLine());
} catch (Exception e) {
if (!e.equals(e.getCause()) && e.getCause() != null)
fail(e.getCause().toString());
else
fail(e.toString());
}
}
static void expectCompilerException(final String id,
final String expectedMessage,
final int expectedLine) {
try {
final String program = ProcessingTestUtil
.preprocess(id, res(id + ".pde"));
final ProcessResult compilerResult = COMPILER.compile(id, program);
if (compilerResult.succeeded()) {
fail("Expected to fail with \"" + expectedMessage + "\" on line "
+ expectedLine);
}
final String e = compilerResult.getStderr().split("\n")[0];
final Matcher m = Pattern.compile(":(\\d+):\\s+(.+)$").matcher(e);
m.find();
assertEquals(expectedMessage, m.group(2));
assertEquals(String.valueOf(expectedLine), m.group(1));
} catch (Exception e) {
if (!e.equals(e.getCause()) && e.getCause() != null)
fail(e.getCause().toString());
else
fail(e.toString());
}
}
static void expectGood(final String id) {
try {
final String program = ProcessingTestUtil
.preprocess(id, res(id + ".pde"));
final ProcessResult compilerResult = COMPILER.compile(id, program);
if (!compilerResult.succeeded()) {
System.err.println(program);
System.err.println("----------------------------");
System.err.println(compilerResult.getStderr());
fail("Compilation failed with status " + compilerResult.getResult());
}
final File expectedFile = res(id + ".expected");
if (expectedFile.exists()) {
final String expected = ProcessingTestUtil.read(expectedFile);
assertEquals(expected, program);
} else {
System.err.println("WARN: " + id
+ " does not have an expected output file. Generating.");
final FileWriter sug = new FileWriter(res(id + ".expected"));
sug.write(ProcessingTestUtil.normalize(program));
sug.close();
}
} catch (Exception e) {
if (!e.equals(e.getCause()) && e.getCause() != null)
fail(e.getCause().toString());
else
fail(e.toString());
}
}
@Test
public void bug4() {
expectGood("bug4");
}
@Test
public void bug5a() {
expectGood("bug5a");
}
@Test
public void bug5b() {
expectGood("bug5b");
}
@Test
public void bug6() {
expectRecognitionException("bug6", "expecting EOF, found '/'", 1);
}
@Test
public void bug16() {
expectRunnerException("bug16", "Unclosed /* comment */", 2);
}
@Test
public void bug136() {
expectGood("bug136");
}
@Test
public void bug196() {
expectRecognitionException("bug196",
"Web colors must be exactly 6 hex digits. This looks like 5.", 4);
}
@Test
public void bug281() {
expectGood("bug281");
}
@Test
public void bug481() {
expectGood("bug481");
}
@Test
public void bug507() {
expectRecognitionException("bug507", "expecting EOF, found 'else'", 5);
}
@Test
public void bug598() {
expectGood("bug598");
}
@Test
public void bug631() {
expectGood("bug631");
}
@Test
public void bug763() {
expectRunnerException("bug763", "Unterminated string constant", 6);
}
@Test
public void bug820() {
expectCompilerException("bug820", "error: variable x1 is already defined in method setup()", 18);
}
@Test
public void bug1064() {
expectGood("bug1064");
}
@Test
public void bug1145() {
expectCompilerException("bug1145", "error: '.' expected", 6);
}
@Test
public void bug1362() {
expectGood("bug1362");
}
@Test
public void bug1390() {
expectGood("bug1390");
}
@Test
public void bug1442() {
expectGood("bug1442");
}
@Test
public void bug1511() {
expectGood("bug1511");
}
@Test
public void bug1512() {
expectGood("bug1512");
}
@Test
public void bug1514a() {
expectGood("bug1514a");
}
@Test
public void bug1514b() {
expectGood("bug1514b");
}
@Test
public void bug1515() {
expectGood("bug1515");
}
@Test
public void bug1516() {
expectGood("bug1516");
}
@Test
public void bug1517() {
expectGood("bug1517");
}
@Test
public void bug1518a() {
expectGood("bug1518a");
}
@Test
public void bug1518b() {
expectGood("bug1518b");
}
@Test
public void bug1519() {
expectRecognitionException("bug1519", "Maybe too many > characters?", 7);
}
@Test
public void bug1525() {
expectGood("bug1525");
}
@Test
public void bug1532() {
expectRecognitionException("bug1532", "unexpected token: break", 50);
}
@Test
public void bug1534() {
expectGood("bug1534");
}
@Test
public void bug1936() {
expectGood("bug1936");
}
@Test
public void bug315g() {
expectGood("bug315g");
}
@Test
public void bug400g() {
expectGood("bug400g");
}
@Test
public void bug427g() {
expectGood("bug427g");
}
@Test
public void annotations() {
expectGood("annotations");
}
}

6
build/.gitignore vendored
View File

@@ -1,2 +1,8 @@
work
javadoc
jre/bin-test
macosx/javafx-sdk-11.0.2
macosx/jdk-0u4.tgz
macosx/jdk-11.0.4+11
macosx/jfx-11.0.2.zip

File diff suppressed because it is too large Load Diff

View File

@@ -1,49 +1,71 @@
<project name="downloader" default="dist">
<target name="compile">
<mkdir dir="bin" />
<path id="classpath.base">
<!-- kinda gross, but if not using the JDT, this just ignored anyway -->
<pathelement location="${jdt.jar};" />
<pathelement location="${java.mode}/jdtCompilerAdapter.jar" />
</path>
<!-- Where can I expect to find Java Mode JARs? -->
<property name="java.mode" value="../../java/mode/" />
<!-- Check for JDT compiler, since this is likely a PDE build. Using
it allows us to build the PDE with only a JRE on Windows and Linux.
So that the core can be built independently of the PDE,
use javac (the "modern" compiler) if ecj is not present. -->
<property name="jdt.jar" value="${java.mode}/org.eclipse.jdt.core.jar" />
<condition property="build.compiler"
value="org.eclipse.jdt.core.JDTCompilerAdapter"
else="modern">
<available file="${jdt.jar}" />
</condition>
<!--<echo message="compiler is ${build.compiler}" />-->
<path id="classpath.test">
<pathelement location="../../core/library-test/junit-4.8.1.jar" />
<pathelement location = "bin-test" />
<path refid="classpath.base" />
</path>
<javac source="1.8"
target="1.8"
srcdir="src"
destdir="bin"
debug="true"
includeantruntime="true"
nowarn="true">
<!-- kinda gross, but if not using the JDT, this just ignored anyway -->
<compilerclasspath path="${jdt.jar}; ${java.mode}/jdtCompilerAdapter.jar" />
</javac>
<macrodef name="compilecommon">
<attribute name="destdir"/>
<attribute name="srcdir"/>
<attribute name="classpath"/>
<sequential>
<mkdir dir="@{destdir}" />
<!-- Where can I expect to find Java Mode JARs? -->
<property name="java.mode" value="../../java/mode/" />
<javac source="1.8"
target="1.8"
srcdir="@{srcdir}"
destdir="@{destdir}"
debug="true"
includeantruntime="true"
nowarn="true">
<classpath refid="@{classpath}"/>
</javac>
</sequential>
</macrodef>
<target name="test-compile">
<compilecommon srcdir="src; test" destdir="bin-test" classpath="classpath.test" />
</target>
<target name="test" depends="test-compile">
<junit haltonfailure="true">
<classpath refid="classpath.test" />
<formatter type="brief" usefile="false" />
<test name="AdoptOpenJdkDownloadUrlGeneratorTest" />
<test name="OracleDownloadUrlGeneratorTest" />
</junit>
</target>
<target name="compile" depends="test">
<compilecommon srcdir="src" destdir="bin" classpath="classpath.base" />
</target>
<target name="dist" depends="compile">
<jar basedir="bin" destfile="downloader.jar" />
</target>
<target name="demo" depends="dist">
<taskdef name="downloader"
<taskdef name="downloader"
classname="Downloader"
classpath="downloader.jar" />
<downloader version="8" update="31" build="13"
<downloader version="8" update="31" build="13"
jdk="true" flavor="macosx-x64.dmg" />
</target>
<target name="clean">
<delete dir="bin" />
<delete dir="bin-test" />
<delete file="downloader.jar" />
</target>

View File

@@ -0,0 +1,85 @@
/* -*- mode: java; c-basic-offset: 2; indent-tabs-mode: nil -*- */
/*
Part of the Processing project - http://processing.org
Copyright (c) 2019 The Processing Foundation
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
version 2, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/**
* Utility to generate download URLs from AdoptOpenJDK.
*/
public class AdoptOpenJdkDownloadUrlGenerator extends DownloadUrlGenerator {
private static final String BASE_URL = "https://github.com/AdoptOpenJDK/openjdk%d-binaries/releases/download/jdk-%d.%d.%d%%2B%d/OpenJDK%dU-%s_%d.%d.%d_%d.%s";
@Override
public String buildUrl(String platform, String component, int train, int version, int update,
int build, String flavor, String hash) {
if (!component.equalsIgnoreCase("jdk")) {
throw new RuntimeException("Can only generate JDK download URLs for AdoptOpenJDK.");
}
String filename = buildDownloadRemoteFilename(platform);
String fileExtension = buildFileExtension(platform);
return String.format(
BASE_URL,
train,
train,
version,
update,
build,
train,
filename,
train,
version,
update,
build,
fileExtension
);
}
/**
* Build a the filename (the "flavor") that is expected on AdoptOpenJDK.
*
* @param downloadPlatform The platform for which the download URL is being generated like
* "macos" or "linux64".
* @return The artifact name without extension like "jdk_x64_mac_hotspot".
*/
private String buildDownloadRemoteFilename(String downloadPlatform) {
switch (downloadPlatform.toLowerCase()) {
case "windows32": return "jdk_x86-32_windows_hotspot";
case "windows64": return "jdk_x64_windows_hotspot";
case "macosx64": return "jdk_x64_mac_hotspot";
case "linux32": throw new RuntimeException("Linux32 not supported by AdoptOpenJDK.");
case "linux64": return "jdk_x64_linux_hotspot";
case "linuxarm": return "jdk_aarch64_linux_hotspot";
default: throw new RuntimeException("Unknown platform: " + downloadPlatform);
}
}
/**
* Determine the download file extension.
*
* @param downloadPlatform The platform for which the download URL is being generated like
* "macos" or "linux64".
* @return The file extension without leading period like "zip" or "tar.gz".
*/
private String buildFileExtension(String downloadPlatform) {
return downloadPlatform.startsWith("windows") ? "zip" : "tar.gz";
}
}

View File

@@ -0,0 +1,77 @@
/* -*- mode: java; c-basic-offset: 2; indent-tabs-mode: nil -*- */
/*
Part of the Processing project - http://processing.org
Copyright (c) 2014-19 The Processing Foundation
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
version 2, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
import java.util.Optional;
/**
* Data structure describing an item to be downloaded as part the Processing build.
*/
public class DownloadItem {
private String url;
private String localPath;
private Optional<String> cookie;
/**
* Create a new download item.
*
* @param newUrl The remote URL at which the download can be found (via GET).
* @param newLocalPath The local path to which the file should be written.
* @param newCookie Optional cookie that, if present, should be given to the server along with the
* GET request for the download contents.
*/
public DownloadItem(String newUrl, String newLocalPath, Optional<String> newCookie) {
url = newUrl;
localPath = newLocalPath;
cookie = newCookie;
}
/**
* Determine where the download can be requested.
*
* @return The remote URL at which the download can be found (via GET).
*/
public String getUrl() {
return url;
}
/**
* Determine to where the download should be saved.
*
* @return The local path to which the file should be written.
*/
public String getLocalPath() {
return localPath;
}
/**
* Determine if and what cookie should be given as part of the download request.
*
* @return Optional cookie that, if present, should be given to the server along with the
* GET request for the download contents. Should be ignored otherwise.
*/
public Optional<String> getCookie() {
return cookie;
}
}

View File

@@ -0,0 +1,84 @@
/* -*- mode: java; c-basic-offset: 2; indent-tabs-mode: nil -*- */
/*
Part of the Processing project - http://processing.org
Copyright (c) 2014-19 The Processing Foundation
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
version 2, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
import java.util.Optional;
/**
* Abstract base class for strategy to generate download URLs.
*/
public abstract class DownloadUrlGenerator {
/**
* Determine the URL at which the artifact can be downloaded.
*
* @param platform The platform for which the download URL is being generated like "macos" or
* "linux64".
* @param component The component to download like "JDK", "JRE", or "JFX".
* @param train The JDK train (like 1 or 11).
* @param version The JDK version (like 8 or 1).
* @param update The update (like 13).
* @param build The build number (like 133).
* @param flavor The flavor like "macosx-x64.dmg".
* @param hash The hash like "d54c1d3a095b4ff2b6607d096fa80163".
*/
public abstract String buildUrl(String platform, String component, int train, int version,
int update, int build, String flavor, String hash);
/**
* Get the cookie that should be used in downloading the target component.
*
* @return Optional that is empty if no cookie should be used or optional with the string cookie
* value if one should be used.
*/
public Optional<String> getCookie() {
return Optional.empty();
}
/**
* Determine the name of the file to which the remote file should be saved.
*
* @param downloadPlatform The platform for which the download URL is being generated like
* "macos" or "linux64".
* @param component The component to download like "JDK", "JRE", or "JFX".
* @param train The JDK train (like 1 or 11).
* @param version The JDK version (like 8 or 1).
* @param update The update (like 13).
* @param build The build number (like 133).
* @param flavor The flavor like "macosx-x64.dmg".
* @param hash The hash like "d54c1d3a095b4ff2b6607d096fa80163".
*/
public String getLocalFilename(String downloadPlatform, String component, int train, int version,
int update, int build, String flavor, String hash) {
String baseFilename = component.toLowerCase();
String versionStr;
if (update == 0) {
versionStr = String.format("-%d-%s", version, flavor);
} else {
versionStr = String.format("-%du%d-%s", version, update, flavor);
}
return baseFilename + versionStr;
}
}

View File

@@ -1,3 +1,24 @@
/* -*- mode: java; c-basic-offset: 2; indent-tabs-mode: nil -*- */
/*
Part of the Processing project - http://processing.org
Copyright (c) 2014-19 The Processing Foundation
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
version 2, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
import java.io.*;
import java.net.*;
import java.util.*;
@@ -7,66 +28,134 @@ import org.apache.tools.ant.Task;
/**
* Ant Task for downloading the latest JRE or JDK from Oracle.
* Ant Task for downloading the latest JRE, JDK, or OpenJFX release.
*/
public class Downloader extends Task {
static final String COOKIE =
"oraclelicense=accept-securebackup-cookie";
private static final boolean PRINT_LOGGING = true;
private int version; // Java 8
private boolean openJdk; // If using openJDK.
private String platform; // macos
private int train; // Java 11 (was 1 through Java 8)
private int version; // 0 (was 8 prior to Java 9)
private int update; // Update 131
private int build; // Build 11
// https://gist.github.com/P7h/9741922
// http://stackoverflow.com/q/10268583
private String hash; // d54c1d3a095b4ff2b6607d096fa80163
private boolean jdk; // false if JRE
private String component; // "JRE", "JDK", or "JFX"
private String flavor;
private String flavor; // Like "zip"
private String path; // target path
/**
* Create a new downloader without tag attributes filled in.
**/
public Downloader() { }
/**
* Set the platform being used.
*
* @param platform The platfom for which files are being downloaded like macosx.
*/
public void setPlatform(String platform) {
this.platform = platform;
}
/**
* Indicate if the OpenJDK is being used.
*
* @param openJdk True if OpenJDK is being used. False if Oracle JDK is being used.
*/
public void setOpenJdk(boolean openJdk) {
this.openJdk = openJdk;
}
/**
* Specify the build train being used.
*
* @param train The build train like 1 (Java 8 and before) or 11 (Java 11).
*/
public void setTrain(int train) {
this.train = train;
}
/**
* Set the version to download within the given build train.
*
* @param version The version within the train to use like 0 for "11.0.1_13".
*/
public void setVersion(int version) {
this.version = version;
}
/**
* Set the update number to download within the given build train.
*
* @param update The update within the version to use like 1 for "11.0.1_13".
*/
public void setUpdate(int update) {
this.update = update;
}
/**
* Set the build number to download.
*
* @param build The build number to use within the build train like 13 for "11.0.1_13".
*/
public void setBuild(int build) {
this.build = build;
}
/**
* Set the expected hash of the download.
*
* @param hash The hash set.
*/
public void setHash(String hash) {
this.hash = hash;
}
public void setJDK(boolean jdk) {
this.jdk = jdk;
/**
* Indicate what component or release type of Java is being downloaded.
*
* @param component The component to download like "JDK", "JRE", or "OpenJFX".
*/
public void setComponent(String component) {
this.component = component;
}
/**
* Indicate the file flavor to be downloaded.
*
* @param flavor The flavor of file (dependent on platform) to be downloaded. Like "-x64.tar.gz".
*/
public void setFlavor(String flavor) {
this.flavor = flavor;
}
/**
* Set the path to which the file should be downloaded.
*
* @param path The path to which the file should be downloaded.
*/
public void setPath(String path) {
this.path = path;
}
/**
* Download the JDK or JRE.
*/
public void execute() throws BuildException {
if (version == 0) {
if (train == 0) {
// 1 if prior to Java 9
throw new BuildException("Train (i.e. 1 or 11) must be set");
}
boolean isJava11 = train == 11;
if (!isJava11 && version == 0) {
throw new BuildException("Version (i.e. 7 or 8) must be set");
}
@@ -90,33 +179,38 @@ public class Downloader extends Task {
}
}
/**
* Download the package from AdoptOpenJDK or Oracle.
*/
void download() throws IOException {
String filename = (jdk ? "jdk" : "jre") +
(update == 0 ?
String.format("-%d-%s", version, flavor) :
String.format("-%du%d-%s", version, update, flavor));
DownloadItem downloadItem;
// Determine url generator for task
Optional<DownloadItem> downloadItemMaybe = getDownloadItem();
if (downloadItemMaybe.isEmpty()) {
return; // There is nothing to do.
} else {
downloadItem = downloadItemMaybe.get();
}
// Build URL and path
if (path == null) {
path = filename;
path = downloadItem.getLocalPath();
}
String url = "http://download.oracle.com/otn-pub/java/jdk/" +
(update == 0 ?
String.format("%d-b%02d/", version, build) :
String.format("%du%d-b%02d/", version, update, build));
String url = downloadItem.getUrl();
// URL format changed starting with 8u121
if (update >= 121) {
url += hash + "/";
}
// Finally, add the filename to the end
url += filename;
// Downlaod
println("Attempting download at " + url);
HttpURLConnection conn =
(HttpURLConnection) new URL(url).openConnection();
conn.setRequestProperty("Cookie", COOKIE);
Optional<String> cookieMaybe = downloadItem.getCookie();
if (cookieMaybe.isPresent()) {
conn.setRequestProperty("Cookie", cookieMaybe.get());
}
//printHeaders(conn);
//conn.connect();
@@ -125,7 +219,7 @@ public class Downloader extends Task {
List<String> location = headers.get("Location");
if (location.size() == 1) {
url = location.get(0);
System.out.println("Redirecting to " + url);
println("Redirecting to " + url);
} else {
throw new BuildException("Got " + location.size() + " locations.");
}
@@ -136,7 +230,11 @@ public class Downloader extends Task {
conn.setRequestProperty("Cookie", cookie);
}
}
conn.setRequestProperty("Cookie", COOKIE);
if (cookieMaybe.isPresent()) {
conn.setRequestProperty("Cookie", cookieMaybe.get());
}
conn.connect();
}
@@ -144,7 +242,10 @@ public class Downloader extends Task {
InputStream input = conn.getInputStream();
BufferedInputStream bis = new BufferedInputStream(input);
File outputFile = new File(path); //folder, filename);
System.out.format("Downloading %s from %s%n", outputFile.getAbsolutePath(), url);
String msg = String.format("Downloading %s from %s%n", outputFile.getAbsolutePath(), url);
println(msg);
// Write to a temp file so that we don't have an incomplete download
// masquerading as a good archive.
File tempFile = File.createTempFile("download", "", outputFile.getParentFile());
@@ -175,19 +276,107 @@ public class Downloader extends Task {
}
}
/**
* Print the headers used for {URLConnection}.
*/
static void printHeaders(URLConnection conn) {
Map<String, List<String>> headers = conn.getHeaderFields();
Set<Map.Entry<String, List<String>>> entrySet = headers.entrySet();
for (Map.Entry<String, List<String>> entry : entrySet) {
String headerName = entry.getKey();
System.out.println("Header Name:" + headerName);
println("Header Name:" + headerName);
List<String> headerValues = entry.getValue();
for (String value : headerValues) {
System.out.print("Header value:" + value);
print("Header value:" + value);
}
System.out.println();
System.out.println();
printEmptyLine();
printEmptyLine();
}
}
/**
* Get the item to be downloaded for this task.
*
* @return The to be downloaded or empty if there is no download required.
*/
private Optional<DownloadItem> getDownloadItem() {
// Determine download type
boolean isJavaDownload = component.equalsIgnoreCase("jdk");
isJavaDownload = isJavaDownload || component.equalsIgnoreCase("jre");
boolean isJfxDownload = component.equalsIgnoreCase("jfx");
DownloadUrlGenerator downloadUrlGenerator;
// Determine url generator
if (isJavaDownload) {
if (openJdk) {
downloadUrlGenerator = new AdoptOpenJdkDownloadUrlGenerator();
} else {
downloadUrlGenerator = new OracleDownloadUrlGenerator();
}
} else if (isJfxDownload) {
if (openJdk) {
downloadUrlGenerator = new GluonHqDownloadUrlGenerator();
} else {
return Optional.empty(); // Nothing to download
}
} else {
throw new RuntimeException("Do not know how to download: " + component);
}
// Build download item
String path = downloadUrlGenerator.getLocalFilename(
platform,
component,
train,
version,
update,
build,
flavor,
hash
);
String url = downloadUrlGenerator.buildUrl(
platform,
component,
train,
version,
update,
build,
flavor,
hash
);
return Optional.of(new DownloadItem(url, path, downloadUrlGenerator.getCookie()));
}
/**
* Print a line out to console if logging is enabled.
*
* @param message The message to be printed.
*/
private static void println(String message) {
if (PRINT_LOGGING) {
System.out.println(message);
}
}
/**
* Print a line out to console if logging is enabled without a newline.
*
* @param message The message to be printed.
*/
private static void print(String message) {
if (PRINT_LOGGING) {
System.out.print(message);
}
}
/**
* Print an empty line to the system.out.
*/
private static void printEmptyLine() {
println("");
}
}

View File

@@ -0,0 +1,50 @@
/* -*- mode: java; c-basic-offset: 2; indent-tabs-mode: nil -*- */
/*
Part of the Processing project - http://processing.org
Copyright (c) 2014-19 The Processing Foundation
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
version 2, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/**
* URL generator for downloading JFX directly from OpenJFX's sponsor Gluon.
*/
public class GluonHqDownloadUrlGenerator extends DownloadUrlGenerator {
private static final String TEMPLATE_URL = "http://gluonhq.com/download/javafx-%d-%d-%d-sdk-%s/";
@Override
public String buildUrl(String platform, String component, int train, int version, int update,
int build, String flavor, String hash) {
String platformLower = platform.toLowerCase();
String platformShort;
if (platformLower.contains("linux")) {
platformShort = "linux";
} else if (platformLower.contains("mac")) {
platformShort = "mac";
} else if (platformLower.contains("windows")) {
platformShort = "windows";
} else {
throw new RuntimeException("Unsupported platform for JFX: " + platform);
}
return String.format(TEMPLATE_URL, train, version, update, platformShort);
}
}

View File

@@ -0,0 +1,72 @@
/* -*- mode: java; c-basic-offset: 2; indent-tabs-mode: nil -*- */
/*
Part of the Processing project - http://processing.org
Copyright (c) 2014-19 The Processing Foundation
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
version 2, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
import java.util.Optional;
/**
* Utility to generate the download URL from Oracle.
*/
public class OracleDownloadUrlGenerator extends DownloadUrlGenerator {
private static final String COOKIE =
"oraclelicense=accept-securebackup-cookie";
@Override
public String buildUrl(String platform, String component, int train, int version, int update,
int build, String flavor, String hash) {
if (!component.equalsIgnoreCase("jdk")) {
throw new RuntimeException("Can only generate JDK download URLs for Oracle.");
}
String filename = getLocalFilename(
platform,
component,
train,
version,
update,
build,
flavor,
hash
);
String url = "http://download.oracle.com/otn-pub/java/jdk/" +
(update == 0 ?
String.format("%d-b%02d/", version, build) :
String.format("%du%d-b%02d/", version, update, build));
// URL format changed starting with 8u121
if (update >= 121) {
url += hash + "/";
}
// Finally, add the filename to the end
url += filename;
return url;
}
public Optional<String> getCookie() {
return Optional.of(COOKIE);
}
}

View File

@@ -0,0 +1,128 @@
/* -*- mode: java; c-basic-offset: 2; indent-tabs-mode: nil -*- */
/*
Part of the Processing project - http://processing.org
Copyright (c) 2012-19 The Processing Foundation
Copyright (c) 2004-12 Ben Fry and Casey Reas
Copyright (c) 2001-04 Massachusetts Institute of Technology
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
version 2, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.assertEquals;
public class AdoptOpenJdkDownloadUrlGeneratorTest {
private static final String EXPECTED_WIN64_URL = "https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.1%2B13/OpenJDK11U-jdk_x64_windows_hotspot_11.0.1_13.zip";
private static final String EXPECTED_MAC_URL = "https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.1%2B13/OpenJDK11U-jdk_x64_mac_hotspot_11.0.1_13.tar.gz";
private static final String EXPECTED_LINUX_URL = "https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.1%2B13/OpenJDK11U-jdk_x64_linux_hotspot_11.0.1_13.tar.gz";
private static final String EXPECTED_LINUX_URL_ARM = "https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.1%2B13/OpenJDK11U-jdk_aarch64_linux_hotspot_11.0.1_13.tar.gz";
private static final String COMPONENT = "jdk";
private static final int TRAIN = 11;
private static final int VERSION = 0;
private static final int UPDATE = 1;
private static final int BUILD = 13;
private static final String FLAVOR_SUFFIX = "-x64.tar.gz";
private static final String HASH = "";
private AdoptOpenJdkDownloadUrlGenerator urlGenerator;
@Before
public void setUp() throws Exception {
urlGenerator = new AdoptOpenJdkDownloadUrlGenerator();
}
@Test
public void testBuildUrlWindows() {
String url = urlGenerator.buildUrl(
"windows64",
COMPONENT,
TRAIN,
VERSION,
UPDATE,
BUILD,
"windows" + FLAVOR_SUFFIX,
HASH
);
assertEquals(
EXPECTED_WIN64_URL,
url
);
}
@Test
public void testBuildUrlMac() {
String url = urlGenerator.buildUrl(
"macosx64",
COMPONENT,
TRAIN,
VERSION,
UPDATE,
BUILD,
"mac" + FLAVOR_SUFFIX,
HASH
);
assertEquals(
EXPECTED_MAC_URL,
url
);
}
@Test
public void testBuildUrlLinux64() {
String url = urlGenerator.buildUrl(
"linux64",
COMPONENT,
TRAIN,
VERSION,
UPDATE,
BUILD,
"linux64" + FLAVOR_SUFFIX,
HASH
);
assertEquals(
EXPECTED_LINUX_URL,
url
);
}
@Test
public void testBuildUrlLinuxArm() {
String url = urlGenerator.buildUrl(
"linuxArm",
COMPONENT,
TRAIN,
VERSION,
UPDATE,
BUILD,
"linuxArm" + FLAVOR_SUFFIX,
HASH
);
assertEquals(
EXPECTED_LINUX_URL_ARM,
url
);
}
}

View File

@@ -0,0 +1,108 @@
/* -*- mode: java; c-basic-offset: 2; indent-tabs-mode: nil -*- */
/*
Part of the Processing project - http://processing.org
Copyright (c) 2012-19 The Processing Foundation
Copyright (c) 2004-12 Ben Fry and Casey Reas
Copyright (c) 2001-04 Massachusetts Institute of Technology
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
version 2, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.assertEquals;
public class GluonHqDownloadUrlGeneratorTest {
private static final String EXPECTED_WIN64_URL = "http://gluonhq.com/download/javafx-11-0-2-sdk-windows/";
private static final String EXPECTED_MAC_URL = "http://gluonhq.com/download/javafx-11-0-2-sdk-mac";
private static final String EXPECTED_LINUX_URL = "http://gluonhq.com/download/javafx-11-0-2-sdk-linux/";
private static final String COMPONENT = "jfx";
private static final int TRAIN = 11;
private static final int VERSION = 0;
private static final int UPDATE = 2;
private static final int BUILD = 0;
private static final String FLAVOR_SUFFIX = ".zip";
private static final String HASH = "";
private AdoptOpenJdkDownloadUrlGenerator urlGenerator;
@Before
public void setUp() throws Exception {
urlGenerator = new AdoptOpenJdkDownloadUrlGenerator();
}
@Test
public void testBuildUrlWindows() {
String url = urlGenerator.buildUrl(
"windows64",
COMPONENT,
TRAIN,
VERSION,
UPDATE,
BUILD,
"windows" + FLAVOR_SUFFIX,
HASH
);
assertEquals(
EXPECTED_WIN64_URL,
url
);
}
@Test
public void testBuildUrlMac() {
String url = urlGenerator.buildUrl(
"macosx64",
COMPONENT,
TRAIN,
VERSION,
UPDATE,
BUILD,
"mac" + FLAVOR_SUFFIX,
HASH
);
assertEquals(
EXPECTED_MAC_URL,
url
);
}
@Test
public void testBuildUrlLinux() {
String url = urlGenerator.buildUrl(
"linux64",
COMPONENT,
TRAIN,
VERSION,
UPDATE,
BUILD,
"linux64" + FLAVOR_SUFFIX,
HASH
);
assertEquals(
EXPECTED_LINUX_URL,
url
);
}
}

View File

@@ -0,0 +1,59 @@
/* -*- mode: java; c-basic-offset: 2; indent-tabs-mode: nil -*- */
/*
Part of the Processing project - http://processing.org
Copyright (c) 2012-19 The Processing Foundation
Copyright (c) 2004-12 Ben Fry and Casey Reas
Copyright (c) 2001-04 Massachusetts Institute of Technology
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
version 2, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
import org.junit.Before;
import org.junit.Test;
import org.junit.Ignore;
import static org.junit.Assert.assertEquals;
public class OracleDownloadUrlGeneratorTest {
private static final String EXPECTED_URL = "http://download.oracle.com/otn-pub/java/jdk/8u131-b11/d54c1d3a095b4ff2b6607d096fa80163/jdk-8u131-macosx-x64.dmg";
private OracleDownloadUrlGenerator urlGenerator;
@Before
public void setUp() throws Exception {
urlGenerator = new OracleDownloadUrlGenerator();
}
@Test
public void testBuildUrl() {
String url = urlGenerator.buildUrl(
"macos",
"jdk",
1,
8,
131,
11,
"macosx-x64.dmg",
"d54c1d3a095b4ff2b6607d096fa80163"
);
assertEquals(
EXPECTED_URL,
url
);
}
}

Binary file not shown.

View File

@@ -0,0 +1,47 @@
/*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2003 Ant-Contrib project. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
*
* 3. The end-user documentation included with the redistribution, if
* any, must include the following acknowlegement:
* "This product includes software developed by the
* Ant-Contrib project (http://sourceforge.net/projects/ant-contrib)."
* Alternately, this acknowlegement may appear in the software itself,
* if and wherever such third-party acknowlegements normally appear.
*
* 4. The name Ant-Contrib must not be used to endorse or promote products
* derived from this software without prior written permission. For
* written permission, please contact
* ant-contrib-developers@lists.sourceforge.net.
*
* 5. Products derived from this software may not be called "Ant-Contrib"
* nor may "Ant-Contrib" appear in their names without prior written
* permission of the Ant-Contrib project.
*
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ANT-CONTRIB PROJECT OR ITS
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
* ====================================================================
*/

View File

@@ -1,11 +1,11 @@
#!/bin/sh
# This script runs Processing, using the JRE in the Processing
# This script runs Processing, using the JRE in the Processing
# installation directory.
# If your system needs a different version of Java than what's included
# in the download, replace the 'java' folder with the contents of a new
# Oracle JRE (Java 8 only), or create a symlink named "java" in the
# Oracle JRE (Java 8 only), or create a symlink named "java" in the
# Processing installation directory that points to the JRE home directory.
# This must be a Sun/Oracle JDK. For more details, see here:
# https://github.com/processing/processing/wiki/Supported-Platforms
@@ -104,7 +104,7 @@ cmd_name='processing-java'
if [ $current_name = $cmd_name ]
then
java -Djna.nosys=true -Djava.ext.dirs="$APPDIR"/java/lib/ext -Xmx256m processing.mode.java.Commander "$@"
java -Djna.nosys=true -Xmx512m processing.mode.java.Commander "$@"
exit $?
else
# Start Processing in the same directory as this script
@@ -115,5 +115,5 @@ else
fi
cd "$APPDIR"
java -splash:lib/about-1x.png -Djna.nosys=true -Djava.ext.dirs="$APPDIR"/java/lib/ext -Xmx256m processing.app.Base "$SKETCH" &
java -splash:lib/about-1x.png -Djna.nosys=true -Xmx512m processing.app.Base "$SKETCH" &
fi

Binary file not shown.

View File

@@ -1,13 +1,13 @@
appbundler
==========
This is a fork of the [infinitekind fork](https://bitbucket.org/infinitekind/appbundler) of Oracle's appbundler.
This is a fork of the [infinitekind fork](https://bitbucket.org/infinitekind/appbundler) of Oracle's appbundler.
(Many thanks for their additional work!) This fork covers several additional features (ability to remove JavaFX
binaries, a rewritten Info.plist writer, etc). See changes in the commits to this source.
binaries, a rewritten Info.plist writer, etc). See changes in the commits to this source. appbundler itself is under the GPL v2 with classpath license.
And here's the README from the [infinitekind fork](https://bitbucket.org/infinitekind/appbundler):
A fork of the [Java Application Bundler](https://svn.java.net/svn/appbundler~svn)
A fork of the [Java Application Bundler](https://svn.java.net/svn/appbundler~svn)
with the following changes:
- The native binary is created as universal (32/64)
@@ -16,7 +16,7 @@ with the following changes:
- Allows to specify the name of the executable instead of using the default `"JavaAppLauncher"` **(contributed by Karl von Randow)**
- Adds `classpathref` support to the `bundleapp` task
- Adds support for `JVMArchs` and `LSArchitecturePriority` keys
- Allows to specify a custom value for `CFBundleVersion`
- Allows to specify a custom value for `CFBundleVersion`
- Allows specifying registered file extensions using `CFBundleDocumentTypes`
- Passes to the Java application a set of environment variables with the paths of
the OSX special folders and whether the application is running in the
@@ -34,11 +34,11 @@ These are the environment variables passed to the JVM:
Example:
<target name="bundle">
<taskdef name="bundleapp"
<taskdef name="bundleapp"
classpath="appbundler-1.0ea.jar"
classname="com.oracle.appbundler.AppBundlerTask"/>
<bundleapp
<bundleapp
classpathref="runclasspathref"
outputdirectory="${dist}"
name="${bundle.name}"
@@ -51,7 +51,7 @@ Example:
mainclassname="Main"
copyright="2012 Your Company"
applicationCategory="public.app-category.finance">
<runtime dir="${runtime}/Contents/Home"/>
<arch name="x86_64"/>
@@ -61,7 +61,7 @@ Example:
icon="${bundle.icon}"
name="Images"
role="editor">
</bundledocument>
</bundledocument>
<bundledocument extensions="pdf"
icon="${bundle.icon}"

View File

@@ -73,8 +73,7 @@ questions.
</copy>
<exec executable="${cc}">
<!-- <arg line="${arch64} ${arch32}"/> -->
<arg line="${arch64}"/>
<arg line="${arch64}"/> <!-- ${arch32} not supported -->
<arg value="-I"/>
<arg value="${env.JAVA_HOME}/include"/>
<arg value="-I"/>
@@ -90,7 +89,7 @@ questions.
<arg value="/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk"/>
<arg value="-mmacosx-version-min=10.7"/>
-->
<arg value="/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk"/>
<arg value="/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk"/>
<arg value="-mmacosx-version-min=10.8"/>
<arg value="native/main.m"/>
</exec>

View File

@@ -73,6 +73,13 @@ questions.
Corresponds to the <code>CFBundleIconFile</code> key in the <tt>Info.plist</tt> file.</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">hideDockIcon</td>
<td valign="top">Set to true to prevent display of the application icon on the Mac OS X dock.
Corresponds to the <code>LSUIElement</code> key in the <tt>Info.plist</tt> file.
(<a href="https://developer.apple.com/library/mac/documentation/General/Reference/InfoPlistKeyReference/Articles/LaunchServicesKeys.html#//apple_ref/doc/uid/20001431-108256">Details</a>)</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">shortversion</td>
<td valign="top">The release version number string for the application.
@@ -100,10 +107,86 @@ questions.
file.</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">privileged</td>
<td valign="top">Bool value if the bundled application is to be launched as privileged.</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">mainclassname</td>
<td valign="top">The name of the bundled application's main class.</td>
<td align="center" valign="top">Yes, alternative to <code>jnlplaunchername</code></td>
<td align="center" valign="top">Yes</td>
</tr>
<tr>
<td valign="top">plistClassPaths</td>
<td valign="top">A comma-separated list of classpath-elements which are used for the java application.
<tt>$APP_ROOT</tt> is replaced by the path of the <tt>.app</tt>-bundle. Required only if not
the libraries specified by the <tt>classpath</tt> and <tt>librarypath</tt> should be used.</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">jvmRequired</td>
<td valign="top">Specifies the required Java virtual machine version.</td>
<td align="center" valign="top">No (defaults to <tt>1.7</tt>)</td>
</tr>
<tr>
<td valign="top">jrePreferred</td>
<td valign="top">If set to <tt>true</tt>, a Java Runtime Edition is required for execution. If both <tt>jrePreferred</tt> and <tt>jdkPreferred</tt> are set <tt>true</tt>, then a JRE is preferred but a JDK ia also accepted.</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">jdkPreferred</td>
<td valign="top">If set to <tt>true</tt>, a Java Development Kit is required for execution. If both <tt>jrePreferred</tt> and <tt>jdkPreferred</tt> are set <tt>true</tt>, then a JRE is preferred but a JDK ia also accepted.</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">minimumSystemVersion</td>
<td valign="top">Indicates the minimum version of OS X required for this app to run.
Corresponds to the <code>LSMinimumSystemVersion</code> key in the <tt>Info.plist</tt>
file.</td>
(<a href="https://developer.apple.com/library/ios/documentation/General/Reference/InfoPlistKeyReference/Articles/LaunchServicesKeys.html#//apple_ref/doc/uid/20001431-113253">Details</a>)</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">jnlplaunchername</td>
<td valign="top">The name of the bundled applications's jnlp file. The file has to be be copied to the <code>Contents/Java</code> folder. It has to be present during execution of the application. This serves as option to deliver signed applications based upon JNLP files. The application can then be signed and the signature won't break when modifying the JNLP file.</td>
<td align="center" valign="top">No, alternative to <code>mainclassname</code></td>
</tr>
<tr>
<td valign="top">workingdirectory</td>
<td valign="top">Specifies the working directory of the application.
<tt>$APP_ROOT</tt> is replaced by the path of the <tt>.app</tt>-bundle.</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">privileged</td>
<td valign="top">If set, the application is started with administrator privileges.</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">highResolutionCapable</td>
<td valign="top">Sets the <i>High Resolution Capable</i> flag.
Corresponds to the <code>NSHighResolutionCapable</code> key in the <tt>Info.plist</tt>
file.</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">supportsAutomaticGraphicsSwitching</td>
<td valign="top">Allow OpenGL applications to utilize the integrated GPU.
Corresponds to the <code>NSSupportsAutomaticGraphicsSwitching</code> key in the <tt>Info.plist</tt>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">ignorePSN</td>
<td valign="top">If set to <tt>true</tt>, the <tt>-psn...</tt> arguments passed by the OS
to the application is filtered out.</td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">isDebug</td>
<td valign="top">If set to <tt>true</tt>, additiona console output will be produced during startup.</td>
<td align="center" valign="top">No</td>
</tr>
</table>
@@ -137,6 +220,23 @@ Entries will be copied to the <tt>Contents/MacOS/</tt> folder of the generated b
<h4>option</h4>
<p>Specifies a command-line option to be passed to the JVM at startup.</p>
<p>Options may be named, which allows the bundled Java program
itself to override the option (e.g. to adjust heap settings). Changes will take effect upon restart of the
application. Assuming your <tt>CFBundleIdentifier</tt> (settable via the attribute <tt>identifier</tt>)
is <tt>com.oracle.appbundler</tt>. Then you can override a named option by calling
<xmp> import java.util.prefs.Preferences;
[...]
Preferences jvmOptions = Preferences.userRoot().node("/com/oracle/appbundler/JVMOptions");
jvmOptions.put("name", "value"); // use option name and desired value here
jvmOptions.flush();</xmp>
The corresponding entries will be stored in a file called
<tt>~/Library/Preferences/com.oracle.appbundler.plist</tt>. To manipulate the file
without Java's <tt>Preferences</tt> from the command line, you should use the tool
<a href="https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man1/defaults.1.html">defaults</a>.
For example, to add an entry via the command line, use:
<xmp> defaults write com.oracle.appbundler /com/oracle/appbundler/ -dict-add JVMOptions/ '{"name"="value";}'</xmp>
Of named options, only the value is passed to the JVM, not the name. The name merely serves as identifier.
</p>
<table border="1" cellpadding="2" cellspacing="0">
<tr>
<td valign="top"><b>Attribute</b></td>
@@ -148,6 +248,11 @@ Entries will be copied to the <tt>Contents/MacOS/</tt> folder of the generated b
<td valign="top">The option value.</td>
<td align="center" valign="top">Yes</td>
</tr>
<tr>
<td valign="top">name</td>
<td valign="top">The option name.</td>
<td align="center" valign="top">No</td>
</tr>
</table>
<h4>argument</h4>
@@ -165,6 +270,218 @@ Entries will be copied to the <tt>Contents/MacOS/</tt> folder of the generated b
</tr>
</table>
<h4>environment</h4>
<p>Specifies an environment variable set via LSEnvironment entry in the <tt>Info.plist</tt> file. See the
<a href="https://developer.apple.com/library/prerelease/mac/documentation/General/Reference/InfoPlistKeyReference/Articles/LaunchServicesKeys.html#//apple_ref/doc/uid/20001431-106825">Apple Documentation</a> for details.</p>
<p>The string <tt>$APP_ROOT</tt> will be replaced by the application bundle path in all environment variables on runtime.</p>
<table border="1" cellpadding="2" cellspacing="0">
<tr>
<td valign="top"><b>Attribute</b></td>
<td valign="top"><b>Description</b></td>
<td align="center" valign="top"><b>Required</b></td>
</tr>
<tr>
<td valign="top">name</td>
<td valign="top">The variable name.</td>
<td align="center" valign="top">Yes</td>
</tr>
<tr>
<td valign="top">value</td>
<td valign="top">The variable value.</td>
<td align="center" valign="top">Yes</td>
</tr>
</table>
<h4>architecture</h4>
<p>Specifies the elements of the <tt>LSArchitecturePriority</tt> array in <tt>Info.plist</tt>.
(<a href="https://developer.apple.com/library/ios/documentation/General/Reference/InfoPlistKeyReference/Articles/LaunchServicesKeys.html#//apple_ref/doc/uid/TP40009250-106825-TPXREF124">Details</a>)</p>
<table border="1" cellpadding="2" cellspacing="0">
<tr>
<td valign="top"><b>Attribute</b></td>
<td valign="top"><b>Description</b></td>
<td align="center" valign="top"><b>Required</b></td>
</tr>
<tr>
<td valign="top">name</td>
<td valign="top">The architecture name.</td>
<td align="center" valign="top">Yes</td>
</tr>
</table>
<h4>plistentry</h4>
<p>Adds an arbitrary entry to the generated <tt>Info.plist</tt>.</p>
<table border="1" cellpadding="2" cellspacing="0">
<tr>
<td valign="top"><b>Attribute</b></td>
<td valign="top"><b>Description</b></td>
<td align="center" valign="top"><b>Required</b></td>
</tr>
<tr>
<td valign="top">key</td>
<td valign="top">The entry's key.</td>
<td align="center" valign="top">Yes</td>
</tr>
<tr>
<td valign="top">value</td>
<td valign="top">The entry's value.</td>
<td align="center" valign="top">Yes</td>
</tr>
<tr>
<td valign="top">type</td>
<td valign="top">The entry's type.</td>
<td align="center" valign="top">No (defaults to <tt>String</tt>)</td>
</tr>
</table>
<h4>scheme</h4>
<p>Specifies a protocol for which the bundled application should be registered as a handler.</p>
<table border="1" cellpadding="2" cellspacing="0">
<tr>
<td valign="top"><b>Attribute</b></td>
<td valign="top"><b>Description</b></td>
<td align="center" valign="top"><b>Required</b></td>
</tr>
<tr>
<td valign="top">value</td>
<td valign="top">The protocol scheme.</td>
<td align="center" valign="top">Yes</td>
</tr>
</table>
<h4 id="bundledocument">bundledocument</h4>
<p>Describes a document associated with your application.</p>
<table border="1" cellpadding="2" cellspacing="0">
<tr>
<td valign="top"><b>Attribute</b></td>
<td valign="top"><b>Description</b></td>
<td valign="top"><b>Corresponding <tt>CFBundleDocumentTypes</tt> key</b></td>
<td align="center" valign="top"><b>Required</b></td>
</tr>
<tr>
<td valign="top">contentTypes</td>
<td valign="top">A comma-separated list of <a href="https://developer.apple.com/library/mac/documentation/FileManagement/Conceptual/understanding_utis/understand_utis_intro/understand_utis_intro.html#//apple_ref/doc/uid/TP40001319">Uniform Type Identifiers</a> defining each a supported file type.
If you reference custom filetypes, declare them using a <a href="#typedeclaration">typedeclaration</a>.
If set, <i>extensions</i> and <i>isPackage</i> are ignored. See the <a href="https://developer.apple.com/library/mac/documentation/Miscellaneous/Reference/UTIRef/Articles/System-DeclaredUniformTypeIdentifiers.html">UTI reference</a> for a list of default UTIs.</td>
<td valign="top"><tt>LSItemContentTypes</tt></td>
<td align="center" valign="top">Yes (or <i>extensions</i>)</td>
</tr>
<tr>
<td valign="top">extensions</td>
<td valign="top">A comma-separated list of filename extensions (minus the leading period) to map to this document type.</td>
<td valign="top"><tt>CFBundleTypeExtensions</tt></td>
<td align="center" valign="top">Yes (or <i>contentTypes</i>)</td>
</tr>
<tr>
<td valign="top">icon</td>
<td valign="top">The name of the icon file (.icns) to associate with this OS X document type.</td>
<td valign="top"><tt>CFBundleTypeIconFile</tt></td>
<td align="center" valign="top">No (But recommended)</td>
</tr>
<tr>
<td valign="top">name</td>
<td valign="top">The abstract name for the document type.</td>
<td valign="top"><tt>CFBundleTypeName</tt></td>
<td align="center" valign="top">No (But recommended)</td>
</tr>
<tr>
<td valign="top">role</td>
<td valign="top">This key specifies the app's role with respect to the type. The value can be <tt>Editor</tt>, <tt>Viewer</tt>, <tt>Shell</tt>, or <tt>None</tt>.</td>
<td valign="top"><tt>CFBundleTypeRole</tt></td>
<td align="center" valign="top">No (default: <tt>Editor</tt>)</td>
</tr>
<tr>
<td valign="top">handlerRank</td>
<td valign="top">Determines how Launch Services ranks this app among the apps that declare themselves editors or viewers of files of this type. The possible values are: <tt>Owner</tt> (this app is the creator of files of this type), <tt>Alternate</tt> (this app is a secondary viewer of files of this type), <tt>None</tt> (this app must never be used to open files of this type, but it accepts drops of files of this type), <tt>Default</tt> (default; this app doesn't accept drops of files of this type). </td>
<td valign="top"><tt>LSHandlerRank</tt></td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">isPackage</td>
<td valign="top">Specifies whether the document is distributed as a bundle. If set to true, the bundle directory is treated as a file.</td>
<td valign="top"><tt>LSTypeIsPackage</tt></td>
<td align="center" valign="top">No (default: <tt>false</tt>)</td>
</tr>
<tr>
<td valign="top">exportableTypes</td>
<td valign="top">A comma-separated list of <a href="https://developer.apple.com/library/mac/documentation/FileManagement/Conceptual/understanding_utis/understand_utis_intro/understand_utis_intro.html#//apple_ref/doc/uid/TP40001319">Uniform Type Identifiers</a> defining a supported file type to which this document can export its content.
If you reference custom filetypes, declare them using a <a href="#typedeclaration">typedeclaration</a>.
See also the <a href="https://developer.apple.com/library/mac/documentation/DataManagement/Conceptual/DocBasedAppProgrammingGuideForOSX/AdvancedTopics/AdvancedTopics.html#//apple_ref/doc/uid/TP40011179-CH7-SW8">Additional Document Type Considerations</a> of the <a href="https://developer.apple.com/library/mac/documentation/DataManagement/Conceptual/DocBasedAppProgrammingGuideForOSX/">Document-Based App Programming Guide for Mac</a>.
<td valign="top"><tt>NSExportableTypes</tt></td>
<td align="center" valign="top">No</td>
</tr>
</table>
<h4 id="typedeclaration">typedeclaration</h4>
<p>Declares a new <a href="https://developer.apple.com/library/mac/documentation/FileManagement/Conceptual/understanding_utis/understand_utis_intro/understand_utis_intro.html#//apple_ref/doc/uid/TP40001319">Uniform Type Identifier</a>.
Required if you reference non-system UTIs in <a href="#bundledocument">bundledocument's</a> <i>contentTypes</i> or <i>exportableTypes</i></p>.
<table border="1" cellpadding="2" cellspacing="0">
<tr>
<td valign="top"><b>Attribute</b></td>
<td valign="top"><b>Description</b></td>
<td valign="top"><b>Corresponding <tt>UT...TypeDeclarations</tt> key</b></td>
<td align="center" valign="top"><b>Required</b></td>
</tr>
<tr>
<td valign="top">identifier</td>
<td valign="top">The unique UTI for the declared type. Following the reverse-DNS format beginning with com.companyName is a simple way to ensure uniqueness.</td>
<td valign="top"><tt>UTTypeIdentifier</tt></td>
<td align="center" valign="top">Yes</td>
</tr>
<tr>
<td valign="top">description</td>
<td valign="top">A user-visible description of this type.</td>
<td valign="top"><tt>UTTypeDescription</tt></td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">icon</td>
<td valign="top">The name of the icon file (.icns) to associate with this UTI.</td>
<td valign="top"><tt>UTTypeIconFile</tt></td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">referenceUrl</td>
<td valign="top">The URL of a reference document describing this type.</td>
<td valign="top"><tt>UTTypeReferenceURL</tt></td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">conformsTo</td>
<td valign="top">A comma-separated list of UTIs to which this identifier conforms.
Although a custom UTI can conform to any UTI, <tt>public.data</tt> or <tt>com.apple.package</tt> must be at the root of the conformance hierarchy.</td>
<td valign="top"><tt>UTTypeConformsTo</tt></td>
<td align="center" valign="top">No (defaults to <tt>public.data</tt>)</td>
</tr>
<tr>
<td valign="top">extensions</td>
<td valign="top">A comma-separated list of filename extensions (minus the leading period) to map to this UTI.</td>
<td valign="top"><tt>UTTypeTagSpecification -> public.filename-extension</tt></td>
<td align="center" valign="top">No (but recommended)</td>
</tr>
<tr>
<td valign="top">mimeTypes</td>
<td valign="top">A comma-separated list of mime types which identify this UTI.</td>
<td valign="top"><tt>UTTypeTagSpecification -> public.mime-type</tt></td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">osTypes</td>
<td valign="top">Comma-separated list of four-character codes formerly used to identify types.
Only specify OSTypes if you really know what you're doing.</td>
<td valign="top"><tt>UTTypeTagSpecification -> com.apple.ostype</tt></td>
<td align="center" valign="top">No</td>
</tr>
<tr>
<td valign="top">imported</td>
<td valign="top">If set to <tt>true</tt>, the declaration is listed under the <tt>UTImportedTypeDeclarations</tt> key.
Otherwise, it is listed under <tt>UTExportedTypeDeclarations</tt>.
If your code relies on third-party UTI types that may not be present on the system, you should declare those UTIs as imported types.</td>
<td valign="top">-</td>
<td align="center" valign="top">No</td>
</tr>
</table>
<h3>Examples</h3>
<p>Generate a launcher for the "Swing Set" demo, bundling the JRE defined by the <tt>JAVA_HOME</tt>
environment variable with the resulting executable.</p>
@@ -187,9 +504,57 @@ environment variable with the resulting executable.</p>
&lt;runtime dir="${env.JAVA_HOME}"/&gt;
&lt;classpath file="/Library/Java/Demos/JFC/SwingSet2/SwingSet2.jar"/&gt;
&lt;option value="-Dapple.laf.useScreenMenuBar=true"/&gt;
&lt;scheme value="mailto"/&gt;
&lt;/bundleapp&gt;
&lt;/target&gt;
</pre>
<h3>Example 2: JNLP Launcher</h3>
<p>Generate a launcher for a JNLP File, copy it into the package and sign the package. You need to have a Developer ID Profile to sign the application.</p>
<p>You can now dynamically modify the zip content (only the JNLP file), deliver it with your web service and the application should directly unpack and can be run</p>
<pre>
&lt;-- Define the appbundler task --&gt;
&lt;taskdef name="bundleapp" classname="com.oracle.appbundler.AppBundlerTask"/&gt;
&lt;-- Create the app bundle --&gt;
&lt;target name="bundle-swingset" depends="package"&gt;
&lt;mkdir dir="./app"&gt;
&lt;bundleapp outputdirectory="./app"
name="SwingSet2"
displayname="SwingSet 2"
identifier="com.oracle.javax.swing.SwingSet2"
shortversion="1.0"
icon="icon.icns"
applicationCategory="public.app-category.developer-tools"
jnlplaunchername="Contents/_CodeSignature/SwingSet2.jnlp"&gt;
&lt;value="-Xdock:icon=Contents/Resources/icon.icns" /&gt;
&lt;option value="-Dapple.laf.useScreenMenuBar=true"/&gt;
&lt;/bundleapp&gt;
&lt;!-- Optionally copy an original file --&gt;
&lt;copy todir="./SwingSet2.app/Contents/_CodeSignature" includeemptydirs="true" overwrite="false"&gt;
&lt;fileset dir="."&gt;
&lt;include name="**/*.jnlp" /&gt;
&lt;/fileset&gt;
&lt;/copy&gt;
&lt;!-- Sign File --&gt;
&lt;exec executable="codesign" os="Mac OS X" failonerror="true"&gt;
&lt;arg value="-f" /&gt;
&lt;arg value="--deep" /&gt;
&lt;arg value="-s" /&gt;
&lt;arg value="Developer ID Application" /&gt;
&lt;arg value="./app/SwingSet2.app" /&gt;
&lt;/exec&gt;
&lt;zip destfile="./SwingSet2.app.zip" basedir="${copyroot}/app"&gt;&lt;/zip&gt;
&lt;/target&gt;
</pre>
<pre>
</pre>
</body>
</html>

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,7 @@
"JRELoadError" = "Die Java Laufzeitumgebung konnte nicht geladen werden.";
"JRExLoadError" = "Die Java %d Laufzeitumgebung konnte nicht geladen werden.";
"JRExLoadFullError" = "Diese Anwendung benötigt die Java %d Laufzeitumgebung oder höher auf Ihrem Computer installiert sein. Bitte installieren Sie die neueste Version von Java von www.java.com und erneut versuchen.";
"JDKxLoadFullError" = "Diese Anwendung benötigt die Java %d Laufzeitumgebung oder höher auf Ihrem Computer installiert sein. Bitte installieren Sie die neueste JDK von Oracle.com und erneut versuchen.";
"MainClassNameRequired" = "Hauptklassenname ist erforderlich.";
"JavaDirectoryNotFound" = "Das Java Verzeichnis ist nicht vorhanden.";
"BundlePathContainsColon" = "Kann nicht vom einem Ordner aus starten, der \"/\" in seinem Namen enthält.";

View File

@@ -1,3 +1,7 @@
"JRELoadError" = "Unable to load Java Runtime Environment.";
"JRExLoadError" = "Unable to load a Java %d Runtime Environment.";
"JRExLoadFullError" = "This application requires that Java %d or later be installed on your computer. Please download and install the latest version of Java from www.java.com and try again.";
"JDKxLoadFullError" = "This application requires that a Java %d JDK or later be installed on your computer. Please download and install the latest Java JDK from Oracle.com and try again.";
"MainClassNameRequired" = "Main class name is required.";
"JavaDirectoryNotFound" = "Unable to enumerate Java directory contents.";
"BundlePathContainsColon" = "Cannot launch from folder that contains a \"/\" in its name.";

View File

@@ -0,0 +1,7 @@
"JRELoadError" = "Impossible d'utiliser un environnement Java.";
"JRExLoadError" = "Impossible d'utiliser un environnement Java %d.";
"JRExLoadFullError" = "Ce logiciel nécessite que Java %d ou plus récent être installés sur votre ordinateur. S'il vous plaît télécharger et installer la dernière version de Java à partir de www.java.com et essayez à nouveau.";
"JDKxLoadFullError" = "Ce logiciel nécessite que Java %d JDK ou plus récent être installés sur votre ordinateur. S'il vous plaît télécharger et installer le JDK plus récente de Oracle.com et essayez à nouveau.";
"MainClassNameRequired" = "Principal nom de classe est nécessaire.";
"JavaDirectoryNotFound" = "Impossible d'énumérer répertoire Java contenu.";
"BundlePathContainsColon" = "Pas de commencer à partir d'un dossier qui contient un \"/\" dans son nom.";

View File

@@ -18,12 +18,14 @@
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
*
*/
package com.oracle.appbundler;
import java.io.File;
import java.util.ArrayList;
import java.util.List;
import org.apache.tools.ant.BuildException;
@@ -31,95 +33,157 @@ import org.apache.tools.ant.BuildException;
/**
* Represent a CFBundleDocument.
*/
public class BundleDocument {
private String name = "editor";
private String role = "";
private File icon = null;
private String[] extensions;
private boolean isPackage = false;
public class BundleDocument implements IconContainer {
private String name = null;
private String role = "Editor";
private String icon = null;
private String handlerRank = null;
private List<String> extensions;
private List<String> contentTypes;
private List<String> exportableTypes;
private boolean isPackage = false;
static private String capitalizeFirst(String string) {
char[] stringArray = string.toCharArray();
stringArray[0] = Character.toUpperCase(stringArray[0]);
return new String(stringArray);
}
public void setExtensions(String extensionsList) {
if (extensionsList == null) {
throw new BuildException("Extensions can't be null");
private String capitalizeFirst(String string) {
char[] stringArray = string.toCharArray();
stringArray[0] = Character.toUpperCase(stringArray[0]);
return new String(stringArray);
}
public void setExtensions(String extensionsString) {
extensions = getListFromCommaSeparatedString(extensionsString, "Extensions", true);
}
extensions = extensionsList.split(",");
for (int i = 0; i < extensions.length; i++) {
extensions[i] = extensions[i].trim().toLowerCase();
public void setContentTypes(String contentTypesString) {
contentTypes = getListFromCommaSeparatedString(contentTypesString, "Content Types");
}
}
public void setIcon(File icon) {
this.icon = icon;
}
public void setName(String name) {
this.name = name;
}
public void setRole(String role) {
this.role = capitalizeFirst(role);
}
public void setIsPackage(String isPackageString) {
this.isPackage = isPackageString.trim().equalsIgnoreCase("true");
}
public String getIconName() {
return icon.getName();
}
public File getIconFile() {
return icon;
}
public String getName() {
return name;
}
public String getRole() {
return role;
}
public String[] getExtensions() {
return extensions;
}
public boolean hasIcon() {
return icon != null;
}
public boolean isPackage() {
return isPackage;
}
@Override
public String toString() {
StringBuilder s = new StringBuilder(getName());
s.append(" ").append(getRole()).append(" ").append(getIconName()).append(" ");
for (String extension : extensions) {
s.append(extension).append(" ");
public void setExportableTypes(String exportableTypesString) {
exportableTypes = getListFromCommaSeparatedString(exportableTypesString, "Exportable Types");
}
public static List<String> getListFromCommaSeparatedString(String listAsString,
final String attributeName) {
return getListFromCommaSeparatedString(listAsString, attributeName, false);
}
public static List<String> getListFromCommaSeparatedString(String listAsString,
final String attributeName, final boolean lowercase) {
if(listAsString == null) {
throw new BuildException(attributeName + " can't be null");
}
String[] splittedListAsString = listAsString.split(",");
List<String> stringList = new ArrayList<String>();
for (String extension : splittedListAsString) {
String cleanExtension = extension.trim();
if (lowercase) {
cleanExtension = cleanExtension.toLowerCase();
}
if (cleanExtension.length() > 0) {
stringList.add(cleanExtension);
}
}
if (stringList.size() == 0) {
throw new BuildException(attributeName + " list must not be empty");
}
return stringList;
}
public void setIcon(String icon) {
this.icon = icon;
}
public void setName(String name) {
this.name = name;
}
public void setRole(String role) {
this.role = capitalizeFirst(role);
}
public void setHandlerRank(String handlerRank) {
this.handlerRank = capitalizeFirst(handlerRank);
}
public void setIsPackage(String isPackageString) {
if(isPackageString.trim().equalsIgnoreCase("true")) {
this.isPackage = true;
} else {
this.isPackage = false;
}
}
public String getIcon() {
return icon;
}
public String getName() {
return name;
}
public String getRole() {
return role;
}
public String getHandlerRank() {
return handlerRank;
}
public List<String> getExtensions() {
return extensions;
}
public List<String> getContentTypes() {
return contentTypes;
}
public List<String> getExportableTypes() {
return exportableTypes;
}
public File getIconFile() {
if (icon == null) { return null; }
File ifile = new File (icon);
if (! ifile.exists ( ) || ifile.isDirectory ( )) { return null; }
return ifile;
}
public boolean hasIcon() {
return icon != null;
}
public boolean isPackage() {
return isPackage;
}
@Override
public String toString() {
StringBuilder s = new StringBuilder(getName());
s.append(" ").append(getRole())
.append(" ").append(getIcon())
.append(" ").append(getHandlerRank())
.append(" ");
if (contentTypes != null) {
for(String contentType : contentTypes) {
s.append(contentType).append(" ");
}
}
if (extensions != null) {
for(String extension : extensions) {
s.append(extension).append(" ");
}
}
if (exportableTypes != null) {
for(String exportableType : exportableTypes) {
s.append(exportableType).append(" ");
}
}
return s.toString();
}
return s.toString();
}
}

View File

@@ -0,0 +1,30 @@
/*
* Copyright 2015, Oracle and/or its affiliates. All rights reserved.
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package com.oracle.appbundler;
public class Environment extends Option {
}

View File

@@ -0,0 +1,32 @@
/*
* Copyright 2015, Quality First Software GmbH and/or its affiliates. All rights reserved.
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
*/
package com.oracle.appbundler;
import java.io.File;
public interface IconContainer {
public boolean hasIcon();
public String getIcon();
public File getIconFile();
}

View File

@@ -28,9 +28,33 @@ package com.oracle.appbundler;
/**
* Class representing an option that will be passed to the JVM at startup.
* The class can optionally be named, which allows the bundled Java program
* itself to override the option. Changes will take effect upon restart of the
* application.<p>
* Assuming your {@code CFBundleIdentifier} (settable via {@link AppBundlerTask#setIdentifier(String)})
* is {@code com.oracle.appbundler}. Then you can override a named option by calling
* <xmp>
* import java.util.prefs.Preferences;
* [...]
* Preferences jvmOptions = Preferences.userRoot().node("/com/oracle/appbundler/JVMOptions");
* jvmOptions.put("name", "value");
* jvmOptions.flush();
* </xmp>
* The corresponding entries will be stored in a file called
* {@code ~/Library/Preferences/com.oracle.appbundler.plist}.
* To manipulate the file without Java's {@link java.util.prefs.Preferences} from the command line,
* you should use the tool
* <a href="https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man1/defaults.1.html">defaults</a>.
* For example, to add an entry via the command line, use:
* <xmp>
* defaults write com.oracle.appbundler /com/oracle/appbundler/ -dict-add JVMOptions/ '{"name"="value";}'
* </xmp>
*
* @author <a href="mailto:hs@tagtraum.com">Hendrik Schreiber</a> (preference related code only)
*/
public class Option {
private String value = null;
private String name = null;
public String getValue() {
return value;
@@ -40,8 +64,16 @@ public class Option {
this.value = value;
}
public String getName() {
return name;
}
public void setName(final String name) {
this.name = name;
}
@Override
public String toString() {
return value;
return name == null ? value : name + "=" + value;
}
}

View File

@@ -0,0 +1,46 @@
/*
* Copyright 2015, Oracle and/or its affiliates. All rights reserved.
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package com.oracle.appbundler;
public class PlistEntry extends Option {
private String type = null;
public void setKey(String key) {
setName(key);
}
public String getKey() {
return getName();
}
public void setType(String type) {
this.type = type;
}
public String getType() {
return type;
}
}

View File

@@ -0,0 +1,123 @@
/*
* Copyright 2012, Oracle and/or its affiliates. All rights reserved.
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package com.oracle.appbundler;
import java.io.File;
import java.io.IOException;
import org.apache.tools.ant.DirectoryScanner;
import org.apache.tools.ant.types.FileSet;
public class Runtime extends FileSet {
/* Override to provide canonical path so that runtime can be specified
* via a version-agnostic path (relative link, e.g. `current-jre`) while
* still preserving the original runtime directory name, e.g. `jre1.8.0_45.jre`.
*/
@Override
public File getDir() {
File dir = super.getDir();
try {
return dir.getCanonicalFile();
} catch (IOException e) {
return dir;
}
}
private void detectType() {
boolean isJDK = new File(getDir(), "jre").isDirectory();
if (isJDK) {
appendIncludes(new String[] {
"jre/lib/",
"jreCOPYRIGHT",
"jre/LICENSE",
"jre/README",
"jre/THIRDPARTYLICENSEREADME-JAVAFX.txt",
"jre/THIRDPARTYLICENSEREADME.txt",
"jre/Welcome.html"
});
appendExcludes(new String[] {
"jre/lib/deploy/",
"jre/lib/deploy.jar",
"jre/lib/javaws.jar",
"jre/lib/libdeploy.dylib",
"jre/lib/libnpjp2.dylib",
"jre/lib/plugin.jar",
"jre/lib/security/javaws.policy"
});
} else {
appendIncludes(new String[] {
"lib/",
"COPYRIGHT",
"LICENSE",
"README",
"THIRDPARTYLICENSEREADME-JAVAFX.txt",
"THIRDPARTYLICENSEREADME.txt",
"Welcome.html"
});
}
}
void copyTo(File targetDir) throws IOException {
detectType();
File runtimeHomeDirectory = getDir();
File runtimeContentsDirectory = runtimeHomeDirectory.getParentFile();
File runtimeDirectory = runtimeContentsDirectory.getParentFile();
// Create root plug-in directory
File pluginDirectory = new File(targetDir, runtimeDirectory.getName());
pluginDirectory.mkdir();
// Create Contents directory
File pluginContentsDirectory = new File(pluginDirectory, runtimeContentsDirectory.getName());
pluginContentsDirectory.mkdir();
// Copy MacOS directory
File runtimeMacOSDirectory = new File(runtimeContentsDirectory, "MacOS");
AppBundlerTask.copy(runtimeMacOSDirectory, new File(pluginContentsDirectory, runtimeMacOSDirectory.getName()));
// Copy Info.plist file
File runtimeInfoPlistFile = new File(runtimeContentsDirectory, "Info.plist");
AppBundlerTask.copy(runtimeInfoPlistFile, new File(pluginContentsDirectory, runtimeInfoPlistFile.getName()));
// Copy included contents of Home directory
File pluginHomeDirectory = new File(pluginContentsDirectory, runtimeHomeDirectory.getName());
DirectoryScanner directoryScanner = getDirectoryScanner(getProject());
String[] includedFiles = directoryScanner.getIncludedFiles();
for (int i = 0; i < includedFiles.length; i++) {
String includedFile = includedFiles[i];
File source = new File(runtimeHomeDirectory, includedFile);
File destination = new File(pluginHomeDirectory, includedFile);
AppBundlerTask.copy(source, destination);
}
}
}

View File

@@ -0,0 +1,141 @@
/*
* Copyright 2015, Quality First Software GmbH and/or its affiliates. All rights reserved.
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
*/
package com.oracle.appbundler;
import static com.oracle.appbundler.BundleDocument.getListFromCommaSeparatedString;
import java.io.File;
import java.util.Arrays;
import java.util.List;
/**
* Class representing an UTExportedTypeDeclaration or UTImportedTypeDeclaration in Info.plist
*/
public class TypeDeclaration implements IconContainer {
private boolean imported = false;
private String identifier = null;
private String referenceUrl = null;
private String description = null;
private String icon = null;
private List<String> conformsTo = null;
private List<String> osTypes = null;
private List<String> mimeTypes = null;
private List<String> extensions = null;
public TypeDeclaration() {
this.conformsTo = Arrays.asList(new String[]{"public.data"});
}
public boolean isImported() {
return imported;
}
public void setImported(boolean imported) {
this.imported = imported;
}
public String getIdentifier() {
return identifier;
}
public void setIdentifier(String identifier) {
this.identifier = identifier;
}
public String getReferenceUrl() {
return referenceUrl;
}
public void setReferenceUrl(String referenceUrl) {
this.referenceUrl = referenceUrl;
}
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public String getIcon() {
return icon;
}
public void setIcon(String icon) {
this.icon = icon;
}
public File getIconFile() {
if (icon == null) { return null; }
File ifile = new File (icon);
if (! ifile.exists ( ) || ifile.isDirectory ( )) { return null; }
return ifile;
}
public boolean hasIcon() {
return icon != null;
}
public List<String> getConformsTo() {
return conformsTo;
}
public void setConformsTo(String conformsToAsString) {
this.conformsTo = getListFromCommaSeparatedString(conformsToAsString, "Conforms To");
}
public List<String> getOsTypes() {
return osTypes;
}
public void setOsTypes(String osTypesAsString) {
this.osTypes = getListFromCommaSeparatedString(osTypesAsString, "OS Types");
}
public List<String> getMimeTypes() {
return mimeTypes;
}
public void setMimeTypes(String mimeTypesAsString) {
this.mimeTypes = getListFromCommaSeparatedString(mimeTypesAsString, "Mime Types", true);
}
public List<String> getExtensions() {
return extensions;
}
public void setExtensions(String extensionsAsString) {
this.extensions = getListFromCommaSeparatedString(extensionsAsString, "Extensions", true);
}
@Override
public String toString() {
return "" + imported;
}
}

View File

@@ -195,7 +195,7 @@ run.options =
# settings for the -XmsNNNm and -XmxNNNm command line option
run.options.memory = false
run.options.memory.initial = 64
run.options.memory.maximum = 256
run.options.memory.maximum = 512
# By default, Mac OS X 10.6 launches applications in 32-bit mode,
# which is more compatible with libraries (many have not updated to 64-bit).

View File

@@ -377,6 +377,7 @@ editor.status.archiver.cancel = Archive sketch canceled.
# Errors
editor.status.warning = Warning
editor.status.error = Error
editor.status.error.syntax = Syntax Error - %s
editor.status.error_on = Error on "%s"
editor.status.missing.default = Missing "%c"
editor.status.missing.semicolon = Missing a semicolon ";"
@@ -404,6 +405,17 @@ editor.status.uninitialized_variable = The local variable "%s" may not have been
editor.status.no_effect_assignment = The assignment to variable "%s" has no effect
editor.status.hiding_enclosing_type = The class "%s" cannot have the same name as your sketch or its enclosing class
editor.status.bad.assignment = Possible error on variable assignment near '%s'?
editor.status.bad.generic = Possibly missing type in generic near '%s'?
editor.status.bad.identifier = Bad identifier? Did you forget a variable or start an identifier with digits near '%s'?
editor.status.bad.parameter = Error on parameter or method declaration near '%s'?
editor.status.bad.import = Import not allowed here.
editor.status.extraneous = Incomplete statement or extra code near '%s'?
editor.status.mismatched = Missing operator, semicolon, or '}' near '%s'?
editor.status.missing.name = Missing name or ; near '%s'?
editor.status.missing.type = Missing name or ; or type near '%s'?
# Footer buttons
editor.footer.errors = Errors
editor.footer.errors.problem = Problem

View File

@@ -375,6 +375,9 @@ editor.status.uninitialized_variable = لم يتم تعريف المتغير ا
editor.status.no_effect_assignment = الإسناد للمتغير "%s" ليس لديه أي مفعول
editor.status.hiding_enclosing_type = لا يمكن أن يكون إسم الصنف "%s" كإسم المخطوط أو إسم الصنف المحتوي
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error.syntax = خطأ قواعدي - %s
# Footer buttons
editor.footer.errors = أخطاء
editor.footer.errors.problem = مشاكل

View File

@@ -366,6 +366,9 @@ contrib.progress.downloading = Herunterladen ...
contrib.download_error = Es trat ein Fehler beim Download auf.
contrib.unsupported_operating_system = Dein Betriebssystem wird nicht unterstützt. Rufe %s für weitere Informationen auf.
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error = Fehler
editor.status.error.syntax = Syntaxfehler - %s
# ---------------------------------------
# Warnings

View File

@@ -364,6 +364,9 @@ editor.status.no_effect_assignment = Η ανάθεση στη μεταβλητή
editor.status.archiver.create = Δημιουργήθηκε το αρχείο "%s".
editor.status.archiver.cancel = H αρχειοθέτηση σχεδίου ακυρώθηκε.
# Limited syntax error support
editor.status.error.syntax = Σφάλμα - %s
# Footer buttons
editor.footer.errors = Σφάλματα
editor.footer.errors.problem = Πρόβλημα

View File

@@ -356,6 +356,7 @@ editor.status.archiver.cancel = Archivado del sketch cancelado.
# Errors
editor.status.warning = Advertencia
editor.status.error = Error
editor.status.error.syntax = Error de sintaxis - %s
editor.status.error_on = Error en "%s"
editor.status.missing.default = Falta un "%c".
editor.status.missing.semicolon = Falta un punto y coma ";"
@@ -381,6 +382,17 @@ editor.status.uninitialized_variable = Puede que la variable local "%s" no haya
editor.status.no_effect_assignment = La asignación a la variable "%s" no tiene ningún efecto
editor.status.hiding_enclosing_type = Las clase "%s" no puede tener el mismo nombre que el sketch o su clase envolvente
# Extended syntax error translation
editor.status.bad.assignment = Error en este asignación de variable cerca '%s'?
editor.status.bad.identifier = Error en este identificador? Es posible que tu olvidaste un variable o empezaste un identificador con un numero cerca '%s'?
editor.status.bad.generic = Error en genérico cerca '%s'. Falta un tipo?
editor.status.bad.parameter = Error en un parámetro o una declaración de método cerca '%s'?
editor.status.bad.import = Una declaración de importación no es permitida en una definición de una clasa.
editor.status.extraneous = Una declaración incompleta o un imprevisto clave cerca '%s'?
editor.status.mismatched = Falta un punto y coma, un operador, o un '}' cerca '%s'?
editor.status.missing.name = Falta ; o nombre cerca '%s'?
editor.status.missing.type = Falta ; o nombre o tipo cerca '%s'?
# Footer buttons
editor.footer.errors = Errores
editor.footer.errors.problem = Problema

View File

@@ -256,6 +256,10 @@ editor.status.printing.done = Imprimerie terminé.
editor.status.printing.error = Erreur lors de l'imprimerie.
editor.status.printing.canceled = Imprimerie annulé.
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error = Erreur
editor.status.error.syntax = Erreur de syntaxe
# Footer buttons
editor.footer.errors = Erreurs
editor.footer.errors.problem = Problèmes

View File

@@ -375,6 +375,9 @@ editor.status.uninitialized_variable = La variabile locale "%s" potrebbe non ess
editor.status.no_effect_assignment = L'assegnazione alla variabile "%s" non ha effetto
editor.status.hiding_enclosing_type = La classe "%s" non può avere lo stesso nome del tuo sketch o della classe che la contiene
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error.syntax = Errore di sintassi - %s
# Footer buttons
editor.footer.errors = Errori
editor.footer.errors.problem = Problemi

View File

@@ -374,6 +374,9 @@ editor.status.unused_variable = ローカル変数 "%s" の値は使われてい
editor.status.uninitialized_variable = The local variable "%s" may not have been initialized
editor.status.no_effect_assignment = The assignment to variable "%s" has no effect
# Limited syntax error support
editor.status.error.syntax = "%s" でエラー
# Footer buttons
editor.footer.errors = エラー
editor.footer.errors.problem = 問題

View File

@@ -294,6 +294,10 @@ contrib.progress.downloading = 다운로드 중
contrib.download_error = 해당 파일 다운로드 중 에러 발생하였습니다.
contrib.unsupported_operating_system = 해당 파일 해당 컴퓨터의 운영체제를 지원하지 않습니다. %s의 웹페이지에 방문하여 확인해 보세요.
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error = 오류
editor.status.error.syntax = 구문 오류 - %s
# ---------------------------------------
# Warnings
@@ -311,4 +315,4 @@ update_check.updates_available.contributions = 설치된 컨트리뷰션(도구,
# ---------------------------------------
# Color Chooser
color_chooser = 색상 선택
color_chooser = 색상 선택

View File

@@ -262,6 +262,9 @@ editor.status.printing.done = Afdrukken gereed.
editor.status.printing.error = Fout tijdens het afdrukken.
editor.status.printing.canceled = Afdrukken geannuleerd.
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error = Fout
editor.status.error.syntax = Fout - %s
# ---------------------------------------
# Contribution Panel

View File

@@ -236,6 +236,10 @@ editor.status.printing.done = Impresso com sucesso.
editor.status.printing.error = Erro a imprimir.
editor.status.printing.canceled = Impressão cancelada.
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error = Erro
editor.status.error.syntax = Erro - %s
# ---------------------------------------
# Contribution Panel

View File

@@ -377,6 +377,9 @@ editor.status.uninitialized_variable = Локальная переменная "
editor.status.no_effect_assignment = Присвоение переменной "%s" не имеет эффекта
editor.status.hiding_enclosing_type = Класс "%s" не может иметь имя наброска
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error.syntax = Синтаксическая ошибка - %s
# Footer buttons
editor.footer.errors = Ошибки
editor.footer.errors.problem = Проблема

View File

@@ -223,6 +223,9 @@ editor.header.next_tab = Sonraki Sekme
editor.header.delete.warning.title = Evet, hayır.
editor.header.delete.warning.text = Aktif sketchteki son sekmeyi silemezsin.
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error = Hata
editor.status.error.syntax = Hata - %s
# ---------------------------------------
# Contribution Panel

View File

@@ -376,6 +376,9 @@ editor.status.unused_variable = Локальна змінна "%s" ніде не
editor.status.uninitialized_variable = Локальна змінна "%s" може бути не ініціалізована
editor.status.no_effect_assignment = Присвоєння змінної "%s" не має чинності
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error.syntax = Помилка - %s
# Footer buttons
editor.footer.errors = Помилки
editor.footer.errors.problem = Проблема

View File

@@ -257,6 +257,10 @@ editor.header.next_tab = 后一个标签
editor.header.delete.warning.title = 这样不行
editor.header.delete.warning.text = 无法删除最后一个速写本的最后一个标签
# Limited syntax error support, Wikipedia CC BY-SA
editor.status.error = 錯誤
editor.status.error.syntax = 语法错误 - %s
# Tabs
editor.tab.new = 新文件名
editor.tab.new.description = 新文件名称

View File

@@ -1,23 +1,22 @@
<?xml version="1.0"?>
<project name="Movie Maker Tool" default="build">
<target name="clean" description="Clean the build directories">
<delete dir="bin" />
<delete file="tool/MovieMaker.jar" />
</target>
<target name="compile" description="Compile sources">
<target name="compile" description="Compile sources">
<mkdir dir="bin" />
<javac target="1.8"
source="1.8"
srcdir="src"
destdir="bin"
srcdir="src"
destdir="bin"
encoding="UTF-8"
includeAntRuntime="false"
classpath="../../../../app/bin"
nowarn="true"
compiler="org.eclipse.jdt.core.JDTCompilerAdapter">
<compilerclasspath path="../../../../java/mode/org.eclipse.jdt.core.jar;
classpath="../../../../app/bin"
nowarn="true">
<compilerclasspath path="../../../../java/mode/org.eclipse.jdt.core.jar;
../../../../java/mode/jdtCompilerAdapter.jar" />
</javac>
</target>

View File

@@ -30,14 +30,14 @@
<jre>
<path>java</path>
<!-- Deal with jokers who install JOGL, ANTLR, etc system-wide -->
<opt>-Djava.ext.dirs="%EXEDIR%\\java\\lib\\ext"</opt>
<!-- <opt>-Djava.ext.dirs="%EXEDIR%\\java\\lib\\ext"</opt> -->
<!-- Prevent a user-installed JNA from conflicting with our version.
https://github.com/processing/processing/issues/2239 -->
<opt>-Djna.nosys=true</opt>
<!-- starting in 3.0, require Java 8 -->
<minVersion>1.8.0_60</minVersion>
<!-- increase available per PDE X request -->
<maxHeapSize>256</maxHeapSize>
<maxHeapSize>512</maxHeapSize>
</jre>
<messages>

View File

@@ -19,7 +19,7 @@
<cp>core/library/core.jar</cp>
<cp>lib/jna.jar</cp>
<cp>lib/jna-platform.jar</cp>
<cp>lib/antlr.jar</cp>
<cp>lib/antlr-4.7.2-complete.jar</cp>
<cp>lib/ant.jar</cp>
<cp>lib/ant-launcher.jar</cp>
<!-- <cp>%EXEDIR%/java/lib/tools.jar</cp> -->
@@ -27,11 +27,11 @@
<jre>
<path>java</path>
<!-- Deal with jokers who install JOGL, ANTLR, etc system-wide -->
<opt>-Djava.ext.dirs="%EXEDIR%\\java\\lib\\ext"</opt>
<!-- <opt>-Djava.ext.dirs="%EXEDIR%\\java\\lib\\ext"</opt> -->
<!-- https://github.com/processing/processing/issues/2239 -->
<opt>-Djna.nosys=true</opt>
<!-- Because nosys is set to true, the DLL in the current working
directory won't be considered. And we can't specify the user's
<!-- Because nosys is set to true, the DLL in the current working
directory won't be considered. And we can't specify the user's
directory here because that'll get us into encoding trouble.
(See https://github.com/processing/processing/issues/3624)
Instead, set this so that Native.loadNativeLibrary() will use
@@ -47,7 +47,7 @@
<!-- starting in 3.0, require Java 8 -->
<minVersion>1.8.0_60</minVersion>
<!-- increase available per PDE X request -->
<maxHeapSize>256</maxHeapSize>
<maxHeapSize>512</maxHeapSize>
</jre>
<splash>
<file>about.bmp</file>

View File

@@ -1,3 +1,3 @@
@echo off
.\java\bin\java -cp lib\pde.jar;core\library\core.jar;lib\jna.jar;lib\jna-platform.jar;lib\antlr.jar;lib\ant.jar;lib\ant-launcher.jar processing.app.Base
.\java\bin\java -cp lib\pde.jar;core\library\core.jar;lib\jna.jar;lib\jna-platform.jar;lib\antlr-4.7.2-complete.jar;lib\ant.jar;lib\ant-launcher.jar processing.app.Base

View File

@@ -1,9 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER">
<attributes>
<attribute name="module" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="lib" path="library/jogl-all.jar"/>
<classpathentry kind="lib" path="library/gluegen-rt.jar"/>
<classpathentry kind="lib" path="apple.jar"/>
<classpathentry kind="con" path="org.eclipse.jdt.USER_LIBRARY/JavaFX11"/>
<classpathentry kind="output" path="bin"/>
</classpath>

View File

@@ -1,8 +1,11 @@
<?xml version="1.0"?>
<project name="Processing Core" default="build">
<property environment="env"/>
<target name="clean" description="Clean out the build directories">
<delete dir="bin" />
<delete dir="bin-test" />
<delete file="library/core.jar" />
</target>
@@ -14,67 +17,102 @@
<subant buildpath="methods" target="dist" />
</target>
<target name="compile" description="Compile" depends="methods-build">
<taskdef name="methods"
classname="PAppletMethods"
classpath="methods/methods.jar" />
<methods dir="${basedir}/src/processing/core" recorder="true" />
<path id="classpath.base">
<!-- kinda gross, but if not using the JDT, this just ignored anyway -->
<pathelement location="apple.jar" />
<pathelement location="library/jogl-all.jar" />
<pathelement location="library/gluegen-rt.jar" />
<pathelement location="library/javafx-swt.jar" />
<pathelement location="library/javafx.base.jar" />
<pathelement location="library/javafx.controls.jar" />
<pathelement location="library/javafx.fxml.jar" />
<pathelement location="library/javafx.graphics.jar" />
<pathelement location="library/javafx.media.jar" />
<pathelement location="library/javafx.properties" />
<pathelement location="library/javafx.swing.jar" />
<pathelement location="library/javafx.web.jar" />
</path>
<!-- Where can I expect to find Java Mode JARs? -->
<property name="java.mode" value="../java/mode/" />
<path id="classpath.test">
<pathelement location="library-test/junit-4.8.1.jar" />
<pathelement location="library-test/mockito-all-1.10.19.jar" />
<pathelement location="bin-test" />
<path refid="classpath.base" />
</path>
<!-- Check for JDT compiler, since this is likely a PDE build. Using
it allows us to build the PDE with only a JRE on Windows and Linux.
So that the core can be built independently of the PDE,
use javac (the "modern" compiler) if ecj is not present. -->
<property name="jdt.jar" value="${java.mode}/org.eclipse.jdt.core.jar" />
<condition property="build.compiler"
value="org.eclipse.jdt.core.JDTCompilerAdapter"
else="modern">
<available file="${jdt.jar}" />
</condition>
<!--<echo message="compiler is ${build.compiler}" />-->
<macrodef name="compilecommon">
<attribute name="destdir"/>
<attribute name="srcdir"/>
<attribute name="classpath"/>
<sequential>
<taskdef name="methods"
classname="PAppletMethods"
classpath="methods/methods.jar" />
<methods dir="${basedir}/src/processing/core" recorder="true" />
<!-- JavaFX got removed from the Oracle's JDK for arm -->
<condition property="fx.unavailable" value="true">
<or>
<equals arg1="${os.arch}" arg2="arm" />
<equals arg1="${os.arch}" arg2="aarch64" />
</or>
</condition>
<!-- Where can I expect to find Java Mode JARs? -->
<property name="java.mode" value="../java/mode/" />
<!-- link against apple.jar for the ThinkDifferent class -->
<mkdir dir="bin" />
<javac source="1.8"
target="1.8"
encoding="UTF-8"
includeAntRuntime="false"
debug="true"
destdir="bin"
classpath="apple.jar;
library/jogl-all.jar;
library/gluegen-rt.jar"
nowarn="true">
<!-- kinda gross, but if not using the JDT, this just ignored anyway -->
<compilerclasspath path="${jdt.jar}; ${java.mode}/jdtCompilerAdapter.jar" />
<src path="src" />
<include name="processing/**" />
<exclude name="processing/javafx/**" if="fx.unavailable" />
</javac>
<!-- JavaFX got removed from the Oracle's JDK for arm and Java 11 -->
<condition property="fx.unavailable" value="true">
<or>
<equals arg1="${os.arch}" arg2="arm" />
<equals arg1="${os.arch}" arg2="aarch64" />
</or>
</condition>
<!-- Copy the jnilib to the bin folder so it's included. -->
<copy todir="bin/japplemenubar"
file="src/japplemenubar/libjAppleMenuBar.jnilib"
preservelastmodified="true" />
<!-- link against apple.jar for the ThinkDifferent class -->
<mkdir dir="@{destdir}" />
<javac source="1.8"
target="1.8"
encoding="UTF-8"
includeAntRuntime="false"
debug="true"
destdir="@{destdir}"
nowarn="true">
<classpath refid="@{classpath}"/>
<src path="@{srcdir}" />
<include name="processing/**" />
<exclude name="processing/javafx/**" if="fx.unavailable" />
</javac>
<!-- Copy shaders to bin. (Eclipse does this automatically.) -->
<copy todir="bin" preservelastmodified="true">
<fileset dir="src">
<include name="processing/opengl/shaders/*.glsl" />
<include name="processing/opengl/cursors/*.png" />
<include name="icon/*.png" />
</fileset>
</copy>
<!-- Copy the jnilib to the bin folder so it's included. -->
<copy todir="bin/japplemenubar"
file="src/japplemenubar/libjAppleMenuBar.jnilib" />
<!-- Copy shaders to bin. (Eclipse does this automatically.) -->
<copy todir="bin">
<fileset dir="src">
<include name="processing/opengl/shaders/*.glsl" />
<include name="processing/opengl/cursors/*.png" />
<include name="icon/*.png" />
</fileset>
</copy>
</sequential>
</macrodef>
<target name="test-compile" description="Compile" depends="methods-build">
<compilecommon srcdir="src; test" destdir="bin-test" classpath="classpath.test" />
</target>
<target name="clean-pre-test" description="Required step prior to test">
<delete dir="resource-test/scratch" />
</target>
<target name="test" depends="test-compile, clean-pre-test">
<junit haltonfailure="true">
<classpath refid="classpath.test" />
<formatter type="brief" usefile="false" />
<batchtest>
<fileset dir="test">
<include name="**/*Test.java" />
</fileset>
</batchtest>
</junit>
</target>
<target name="compile" description="Compile" depends="test">
<compilecommon srcdir="src" destdir="bin" classpath="classpath.base" />
</target>
<target name="build" depends="compile" description="Build core library">

View File

@@ -0,0 +1,2 @@
JUnit under EPL license: https://junit.org/junit4/license.html.
Mockito under MIT license: https://github.com/mockito/mockito/blob/master/LICENSE.

Binary file not shown.

View File

@@ -1,12 +1,18 @@
# If you want to support more platforms, visit jogamp.org to get the
# natives libraries for the platform in question (i.e. Solaris).
# If you want to support more platforms, visit jogamp.org to get the
# natives libraries for the platform in question (i.e. Solaris).
name = OpenGL
name = CoreOpenJFXOpenGL
application.macosx=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-macosx-universal.jar,gluegen-rt-natives-macosx-universal.jar
application.windows32=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-windows-i586.jar,gluegen-rt-natives-windows-i586.jar
application.windows64=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-windows-amd64.jar,gluegen-rt-natives-windows-amd64.jar
application.linux32=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-linux-i586.jar,gluegen-rt-natives-linux-i586.jar
application.linux64=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-linux-amd64.jar,gluegen-rt-natives-linux-amd64.jar
application.linux-armv6hf=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-linux-armv6hf.jar,gluegen-rt-natives-linux-armv6hf.jar
application.linux-arm64=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-linux-aarch64.jar,gluegen-rt-natives-linux-aarch64.jar
application.macosx=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-macosx-universal.jar,gluegen-rt-natives-macosx-universal.jar,javafx-swt.jar,javafx.base.jar,javafx.controls.jar,javafx.fxml.jar,javafx.graphics.jar,javafx.media.jar,javafx.swing.jar,javafx.web.jar,libdecora_sse.dylib,libfxplugins.dylib,libglass.dylib,libglib-lite.dylib,libgstreamer-lite.dylib,libjavafx_font.dylib,libjavafx_iio.dylib,libjfxmedia.dylib,libjfxmedia_avf.dylib,libjfxwebkit.dylib,libprism_common.dylib,libprism_es2.dylib,libprism_sw.dylib
application.windows32=api-ms-win-core-console-l1-1-0.dll,api-ms-win-core-datetime-l1-1-0.dll,api-ms-win-core-debug-l1-1-0.dll,api-ms-win-core-errorhandling-l1-1-0.dll,api-ms-win-core-file-l1-1-0.dll,api-ms-win-core-file-l1-2-0.dll,api-ms-win-core-file-l2-1-0.dll,api-ms-win-core-handle-l1-1-0.dll,api-ms-win-core-heap-l1-1-0.dll,api-ms-win-core-interlocked-l1-1-0.dll,api-ms-win-core-libraryloader-l1-1-0.dll,api-ms-win-core-localization-l1-2-0.dll,api-ms-win-core-memory-l1-1-0.dll,api-ms-win-core-namedpipe-l1-1-0.dll,api-ms-win-core-processenvironment-l1-1-0.dll,api-ms-win-core-processthreads-l1-1-0.dll,api-ms-win-core-processthreads-l1-1-1.dll,api-ms-win-core-profile-l1-1-0.dll,api-ms-win-core-rtlsupport-l1-1-0.dll,api-ms-win-core-string-l1-1-0.dll,api-ms-win-core-synch-l1-1-0.dll,api-ms-win-core-synch-l1-2-0.dll,api-ms-win-core-sysinfo-l1-1-0.dll,api-ms-win-core-timezone-l1-1-0.dll,api-ms-win-core-util-l1-1-0.dll,api-ms-win-crt-conio-l1-1-0.dll,api-ms-win-crt-convert-l1-1-0.dll,api-ms-win-crt-environment-l1-1-0.dll,api-ms-win-crt-filesystem-l1-1-0.dll,api-ms-win-crt-heap-l1-1-0.dll,api-ms-win-crt-locale-l1-1-0.dll,api-ms-win-crt-math-l1-1-0.dll,api-ms-win-crt-multibyte-l1-1-0.dll,api-ms-win-crt-private-l1-1-0.dll,api-ms-win-crt-process-l1-1-0.dll,api-ms-win-crt-runtime-l1-1-0.dll,api-ms-win-crt-stdio-l1-1-0.dll,api-ms-win-crt-string-l1-1-0.dll,api-ms-win-crt-time-l1-1-0.dll,api-ms-win-crt-utility-l1-1-0.dll,concrt140.dll,core.jar,decora_sse.dll,fxplugins.dll,glass.dll,glib-lite.dll,gluegen-rt-natives-linux-aarch64.jar,gluegen-rt-natives-linux-amd64.jar,gluegen-rt-natives-linux-armv6hf.jar,gluegen-rt-natives-linux-i586.jar,gluegen-rt-natives-macosx-universal.jar,gluegen-rt-natives-windows-amd64.jar,gluegen-rt-natives-windows-i586.jar,gluegen-rt.jar,gstreamer-lite.dll,javafx-swt.jar,javafx.base.jar,javafx.controls.jar,javafx.fxml.jar,javafx.graphics.jar,javafx.media.jar,javafx.properties,javafx.swing.jar,javafx.web.jar,javafx_font.dll,javafx_iio.dll,jfxmedia.dll,jfxwebkit.dll,jogl-all-natives-linux-aarch64.jar,jogl-all-natives-linux-amd64.jar,jogl-all-natives-linux-armv6hf.jar,jogl-all-natives-linux-i586.jar,jogl-all-natives-macosx-universal.jar,jogl-all-natives-windows-amd64.jar,jogl-all-natives-windows-i586.jar,jogl-all.jar,msvcp140.dll,prism_common.dll,prism_d3d.dll,prism_sw.dll,ucrtbase.dll,vcruntime140.dll
application.windows64=api-ms-win-core-console-l1-1-0.dll,api-ms-win-core-datetime-l1-1-0.dll,api-ms-win-core-debug-l1-1-0.dll,api-ms-win-core-errorhandling-l1-1-0.dll,api-ms-win-core-file-l1-1-0.dll,api-ms-win-core-file-l1-2-0.dll,api-ms-win-core-file-l2-1-0.dll,api-ms-win-core-handle-l1-1-0.dll,api-ms-win-core-heap-l1-1-0.dll,api-ms-win-core-interlocked-l1-1-0.dll,api-ms-win-core-libraryloader-l1-1-0.dll,api-ms-win-core-localization-l1-2-0.dll,api-ms-win-core-memory-l1-1-0.dll,api-ms-win-core-namedpipe-l1-1-0.dll,api-ms-win-core-processenvironment-l1-1-0.dll,api-ms-win-core-processthreads-l1-1-0.dll,api-ms-win-core-processthreads-l1-1-1.dll,api-ms-win-core-profile-l1-1-0.dll,api-ms-win-core-rtlsupport-l1-1-0.dll,api-ms-win-core-string-l1-1-0.dll,api-ms-win-core-synch-l1-1-0.dll,api-ms-win-core-synch-l1-2-0.dll,api-ms-win-core-sysinfo-l1-1-0.dll,api-ms-win-core-timezone-l1-1-0.dll,api-ms-win-core-util-l1-1-0.dll,api-ms-win-crt-conio-l1-1-0.dll,api-ms-win-crt-convert-l1-1-0.dll,api-ms-win-crt-environment-l1-1-0.dll,api-ms-win-crt-filesystem-l1-1-0.dll,api-ms-win-crt-heap-l1-1-0.dll,api-ms-win-crt-locale-l1-1-0.dll,api-ms-win-crt-math-l1-1-0.dll,api-ms-win-crt-multibyte-l1-1-0.dll,api-ms-win-crt-private-l1-1-0.dll,api-ms-win-crt-process-l1-1-0.dll,api-ms-win-crt-runtime-l1-1-0.dll,api-ms-win-crt-stdio-l1-1-0.dll,api-ms-win-crt-string-l1-1-0.dll,api-ms-win-crt-time-l1-1-0.dll,api-ms-win-crt-utility-l1-1-0.dll,concrt140.dll,core.jar,decora_sse.dll,fxplugins.dll,glass.dll,glib-lite.dll,gluegen-rt-natives-linux-aarch64.jar,gluegen-rt-natives-linux-amd64.jar,gluegen-rt-natives-linux-armv6hf.jar,gluegen-rt-natives-linux-i586.jar,gluegen-rt-natives-macosx-universal.jar,gluegen-rt-natives-windows-amd64.jar,gluegen-rt-natives-windows-i586.jar,gluegen-rt.jar,gstreamer-lite.dll,javafx-swt.jar,javafx.base.jar,javafx.controls.jar,javafx.fxml.jar,javafx.graphics.jar,javafx.media.jar,javafx.properties,javafx.swing.jar,javafx.web.jar,javafx_font.dll,javafx_iio.dll,jfxmedia.dll,jfxwebkit.dll,jogl-all-natives-linux-aarch64.jar,jogl-all-natives-linux-amd64.jar,jogl-all-natives-linux-armv6hf.jar,jogl-all-natives-linux-i586.jar,jogl-all-natives-macosx-universal.jar,jogl-all-natives-windows-amd64.jar,jogl-all-natives-windows-i586.jar,jogl-all.jar,msvcp140.dll,prism_common.dll,prism_d3d.dll,prism_sw.dll,ucrtbase.dll,vcruntime140.dll
application.linux32=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-linux-i586.jar,gluegen-rt-natives-linux-i586.jar,javafx-swt.jar,javafx.base.jar,javafx.controls.jar,javafx.fxml.jar,javafx.graphics.jar,javafx.media.jar,javafx.swing.jar,javafx.web.jar,libavplugin-54.so,libavplugin-56.so,libavplugin-57.so,libavplugin-ffmpeg-56.so,libavplugin-ffmpeg-57.so,libdecora_sse.so,libfxplugins.so,libglass.so,libglassgtk2.so,libglassgtk3.so,libgstreamer-lite.so,libjavafx_font.so,libjavafx_font_freetype.so,libjavafx_font_pango.so,libjavafx_iio.so,libjfxmedia.so,libjfxwebkit.so,libprism_common.so,libprism_es2.so,libprism_sw.so
application.linux64=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-linux-amd64.jar,gluegen-rt-natives-linux-amd64.jar,javafx-swt.jar,javafx.base.jar,javafx.controls.jar,javafx.fxml.jar,javafx.graphics.jar,javafx.media.jar,javafx.swing.jar,javafx.web.jar,libavplugin-54.so,libavplugin-56.so,libavplugin-57.so,libavplugin-ffmpeg-56.so,libavplugin-ffmpeg-57.so,libdecora_sse.so,libfxplugins.so,libglass.so,libglassgtk2.so,libglassgtk3.so,libgstreamer-lite.so,libjavafx_font.so,libjavafx_font_freetype.so,libjavafx_font_pango.so,libjavafx_iio.so,libjfxmedia.so,libjfxwebkit.so,libprism_common.so,libprism_es2.so,libprism_sw.so
application.linux-armv6hf=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-linux-armv6hf.jar,gluegen-rt-natives-linux-armv6hf.jar,javafx-swt.jar,javafx.base.jar,javafx.controls.jar,javafx.fxml.jar,javafx.graphics.jar,javafx.media.jar,javafx.swing.jar,javafx.web.jar,libavplugin-54.so,libavplugin-56.so,libavplugin-57.so,libavplugin-ffmpeg-56.so,libavplugin-ffmpeg-57.so,libdecora_sse.so,libfxplugins.so,libglass.so,libglassgtk2.so,libglassgtk3.so,libgstreamer-lite.so,libjavafx_font.so,libjavafx_font_freetype.so,libjavafx_font_pango.so,libjavafx_iio.so,libjfxmedia.so,libjfxwebkit.so,libprism_common.so,libprism_es2.so,libprism_sw.so
application.linux-arm64=core.jar,jogl-all.jar,gluegen-rt.jar,jogl-all-natives-linux-aarch64.jar,gluegen-rt-natives-linux-aarch64.jar,javafx-swt.jar,javafx.base.jar,javafx.controls.jar,javafx.fxml.jar,javafx.graphics.jar,javafx.media.jar,javafx.swing.jar,javafx.web.jar,libavplugin-54.so,libavplugin-56.so,libavplugin-57.so,libavplugin-ffmpeg-56.so,libavplugin-ffmpeg-57.so,libdecora_sse.so,libfxplugins.so,libglass.so,libglassgtk2.so,libglassgtk3.so,libgstreamer-lite.so,libjavafx_font.so,libjavafx_font_freetype.so,libjavafx_font_pango.so,libjavafx_iio.so,libjfxmedia.so,libjfxwebkit.so,libprism_common.so,libprism_es2.so,libprism_sw.so

BIN
core/library/javafx-swt.jar Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More