mirror of
https://github.com/shadowfacts/jinput-arm64.git
synced 2026-02-21 15:15:15 +01:00
commit
4b66611142
|
|
@ -1,46 +0,0 @@
|
|||
<?xml version="1.0"?>
|
||||
|
||||
<project name="applet" basedir="." default="jar">
|
||||
|
||||
<target name="clean">
|
||||
<delete dir="dist" failonerror="true"/>
|
||||
</target>
|
||||
|
||||
<target name="init">
|
||||
<mkdir dir="classes"/>
|
||||
<mkdir dir="dist"/>
|
||||
</target>
|
||||
|
||||
<target name="compile" depends="init">
|
||||
<javac srcdir="src" destdir="classes" debug="true" deprecation="true" source="1.4" target="1.4">
|
||||
<classpath>
|
||||
<pathelement location="../dist/jinput.jar"/>
|
||||
<pathelement location="../dist/jinput-test.jar"/>
|
||||
</classpath>
|
||||
</javac>
|
||||
</target>
|
||||
|
||||
<target name="jar" depends="compile">
|
||||
<jar jarfile="dist/jinput-applet-test.jar" compress="true" basedir="classes">
|
||||
<include name="**/*.class"/>
|
||||
</jar>
|
||||
</target>
|
||||
|
||||
<target name="dist" depends="jar">
|
||||
<copy todir="dist">
|
||||
<fileset dir="../webstart/dist/"/>
|
||||
<fileset file="jinput.html"/>
|
||||
<fileset file="jinput-event.html"/>
|
||||
</copy>
|
||||
</target>
|
||||
|
||||
<target name="sign" depends="jar">
|
||||
<input message="Input keystore alias: " addproperty="keystoreAlias"/>
|
||||
<input message="Input keystore password: " addproperty="keystorePassword"/>
|
||||
<signjar alias="${keystoreAlias}" keystore="../webstart/myKeyStore" storepass="${keystorePassword}" verbose="true">
|
||||
<fileset dir="dist">
|
||||
<include name="**/jinput-applet-test.jar"/>
|
||||
</fileset>
|
||||
</signjar>
|
||||
</target>
|
||||
</project>
|
||||
27
applet/pom.xml
Normal file
27
applet/pom.xml
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>applet</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<name>JInput - applet</name>
|
||||
|
||||
<parent>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>jinput-parent</artifactId>
|
||||
<version>2.0.8-SNAPSHOT</version>
|
||||
<relativePath>../</relativePath>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-source-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
385
build.xml
385
build.xml
|
|
@ -1,385 +0,0 @@
|
|||
<?xml version="1.0"?>
|
||||
|
||||
<project name="Sun Games Initiative Client Technologies" basedir="." default="all" xmlns:artifact="urn:maven-artifact-ant">
|
||||
|
||||
<property name="api.version" value="2.0.8"/>
|
||||
<property name="mvn.version" value="${api.version}-SNAPSHOT"/>
|
||||
<property name="maven-repository-url" value="https://oss.sonatype.org/service/local/staging/deploy/maven2/" />
|
||||
<property name="maven-repository-id" value="sonatype-nexus-staging" />
|
||||
|
||||
<target name="init">
|
||||
<!-- If we are running in windows, set dx8 property to true -->
|
||||
<condition property="windows" >
|
||||
<os family="windows" />
|
||||
</condition>
|
||||
|
||||
<!-- If we are running in linux, set linux property to true -->
|
||||
<condition property="linux" >
|
||||
<!--<os family="unix" />-->
|
||||
<os name="linux" />
|
||||
</condition>
|
||||
|
||||
<!-- If we are running in Mac OS X, set osx property to true -->
|
||||
<condition property="osx" >
|
||||
<and>
|
||||
<os family="mac" />
|
||||
<os family="unix" />
|
||||
</and>
|
||||
</condition>
|
||||
|
||||
<delete file="lib/jutils.jar"/>
|
||||
<copy tofile="lib/jutils.jar">
|
||||
<fileset dir="lib" includes="jutils-*-SNAPSHOT.jar"></fileset>
|
||||
</copy>
|
||||
</target>
|
||||
|
||||
<target name="runtest" depends="dist">
|
||||
<java classname="${mainclass}"
|
||||
fork="true" failonerror="true" dir=".">
|
||||
<classpath>
|
||||
<pathelement location="dist/jinput.jar"/>
|
||||
<pathelement location="dist/jinput-test.jar"/>
|
||||
</classpath>
|
||||
<jvmarg value="-Djava.library.path=dist"/>
|
||||
</java>
|
||||
</target>
|
||||
|
||||
<target name="texttest">
|
||||
<antcall target="runtest">
|
||||
<param name="mainclass" value="net.java.games.input.test.ControllerTextTest"/>
|
||||
</antcall>
|
||||
</target>
|
||||
|
||||
<target name="readtest" depends="init,all" description="Try running it.">
|
||||
<antcall target="runtest">
|
||||
<param name="mainclass" value="net.java.games.input.test.ControllerReadTest"/>
|
||||
</antcall>
|
||||
</target>
|
||||
|
||||
<target name="eventtest" depends="init,all" description="Try running it.">
|
||||
<antcall target="runtest">
|
||||
<param name="mainclass" value="net.java.games.input.test.ControllerEventTest"/>
|
||||
</antcall>
|
||||
</target>
|
||||
|
||||
<target name="rumbletest" depends="init,all" description="Try running it.">
|
||||
<antcall target="runtest">
|
||||
<param name="mainclass" value="net.java.games.input.test.RumbleTest"/>
|
||||
</antcall>
|
||||
</target>
|
||||
|
||||
<target name="versiontest" depends="init,all" description="Try running it.">
|
||||
<antcall target="runtest">
|
||||
<param name="mainclass" value="net.java.games.input.test.VersionTest"/>
|
||||
</antcall>
|
||||
</target>
|
||||
|
||||
<macrodef name="iterate">
|
||||
<attribute name="target"/>
|
||||
<sequential>
|
||||
<subant target="@{target}">
|
||||
<property name="api.version" value="${api.version}"/>
|
||||
<fileset file="coreAPI/build.xml"/>
|
||||
<fileset file="plugins/linux/build.xml"/>
|
||||
<fileset file="plugins/windows/build.xml"/>
|
||||
<fileset file="plugins/wintab/build.xml"/>
|
||||
<fileset file="plugins/OSX/build.xml"/>
|
||||
<fileset file="plugins/awt/build.xml"/>
|
||||
</subant>
|
||||
</sequential>
|
||||
</macrodef>
|
||||
|
||||
<target name="clean">
|
||||
<iterate target="clean"/>
|
||||
<delete dir="dist" failonerror="no"/>
|
||||
</target>
|
||||
|
||||
<target name="all" depends="dist">
|
||||
</target>
|
||||
|
||||
<target name="javadoc" depends="init">
|
||||
<iterate target="javadoc"/>
|
||||
</target>
|
||||
|
||||
<target name="pluginTest" depends="dist" description="Build plugin version">
|
||||
<mkdir dir="dist"/>
|
||||
<mkdir dir="dist/controller"/>
|
||||
<copy todir="dist">
|
||||
<fileset file="coreAPI/bin/jinput-core.jar"/>
|
||||
<fileset file="coreAPI/bin/jinput-test.jar"/>
|
||||
<fileset file="plugins/DX8/lib/jutils.jar"/>
|
||||
</copy>
|
||||
<copy todir="dist/controller">
|
||||
<fileset dir="plugins/awt/bin"/>
|
||||
<fileset dir="plugins/linux/bin"/>
|
||||
<fileset dir="plugins/OSX/bin"/>
|
||||
<fileset dir="plugins/windows/bin"/>
|
||||
<fileset dir="plugins/wintab/bin"/>
|
||||
</copy>
|
||||
</target>
|
||||
|
||||
<target name="dist" depends="init" description="Build the distribution file for this system">
|
||||
<iterate target="all"/>
|
||||
<mkdir dir="dist"/>
|
||||
<jar jarfile="dist/jinput.jar" compress="true" duplicate="preserve">
|
||||
<fileset dir="coreAPI/classes">
|
||||
<include name="**/*.class"/>
|
||||
<exclude name="**/test/*.class"/>
|
||||
<exclude name="**/example/*.class"/>
|
||||
</fileset>
|
||||
<fileset dir="plugins/linux/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<fileset dir="plugins/OSX/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<fileset dir="plugins/awt/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<fileset dir="plugins/windows/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<fileset dir="plugins/wintab/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<zipfileset src="lib/jutils.jar" includes="**/*.class"/>
|
||||
<manifest>
|
||||
<attribute name="Sealed" value="true"/>
|
||||
</manifest>
|
||||
</jar>
|
||||
<iterate target="javadoc"/>
|
||||
<copy todir="dist">
|
||||
<fileset file="coreAPI/bin/jinput-test.jar"/>
|
||||
<fileset dir="plugins/linux/bin" includes="*so"/>
|
||||
<fileset dir="plugins/OSX/bin" includes="*jnilib"/>
|
||||
<fileset dir="plugins/windows/bin" includes="*dll"/>
|
||||
<fileset dir="plugins/wintab/bin" includes="*dll"/>
|
||||
</copy>
|
||||
</target>
|
||||
|
||||
<target name="simple_dist" depends="dist,simple_windows,simple_wintab,simple_linux,simple_osx" description="Build the simple jars for each platform"/>
|
||||
|
||||
<target name="simple_linux" depends="dist" description="Build the simple linux jar" if="linux">
|
||||
<jar jarfile="dist/jinput-linux.jar" compress="true">
|
||||
<fileset dir="coreAPI/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<fileset dir="plugins/linux/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<zipfileset src="lib/jutils.jar" includes="**/*.class"/>
|
||||
<manifest>
|
||||
<attribute name="Sealed" value="true"/>
|
||||
</manifest>
|
||||
</jar>
|
||||
<tar destfile="dist/jinput_linux.tgz" compression="gzip">
|
||||
<tarfileset dir=".">
|
||||
<include name="dist/jinput-linux.jar"/>
|
||||
</tarfileset>
|
||||
<tarfileset dir="plugins/linux/bin">
|
||||
<include name="*.so"/>
|
||||
</tarfileset>
|
||||
</tar>
|
||||
</target>
|
||||
|
||||
<target name="simple_windows" depends="dist" description="Build the simple windows jar" if="windows">
|
||||
<jar jarfile="dist/jinput-windows.jar" compress="true">
|
||||
<fileset dir="coreAPI/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<fileset dir="plugins/windows/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<zipfileset src="lib/jutils.jar" includes="**/*.class"/>
|
||||
<manifest>
|
||||
<attribute name="Sealed" value="true"/>
|
||||
</manifest>
|
||||
</jar>
|
||||
<zip destfile="dist/jinput_windows.zip">
|
||||
<zipfileset dir=".">
|
||||
<include name="dist/jinput-windows.jar"/>
|
||||
</zipfileset>
|
||||
<zipfileset dir="plugins/windows/bin">
|
||||
<include name="*.dll"/>
|
||||
</zipfileset>
|
||||
</zip>
|
||||
</target>
|
||||
|
||||
<target name="simple_wintab" depends="dist" description="Build the simple windows jar" if="windows">
|
||||
<jar jarfile="dist/jinput-wintab.jar" compress="true">
|
||||
<fileset dir="coreAPI/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<fileset dir="plugins/wintab/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<zipfileset src="lib/jutils.jar" includes="**/*.class"/>
|
||||
<manifest>
|
||||
<attribute name="Sealed" value="true"/>
|
||||
</manifest>
|
||||
</jar>
|
||||
<zip destfile="dist/jinput_wintab.zip">
|
||||
<zipfileset dir=".">
|
||||
<include name="dist/jinput-wintab.jar"/>
|
||||
</zipfileset>
|
||||
<zipfileset dir="plugins/wintab/bin">
|
||||
<include name="*.dll"/>
|
||||
</zipfileset>
|
||||
</zip>
|
||||
</target>
|
||||
|
||||
<target name="simple_osx" depends="dist" description="Build the simple osx jar" if="osx">
|
||||
<jar jarfile="dist/jinput-osx.jar" compress="true">
|
||||
<fileset dir="coreAPI/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<fileset dir="plugins/OSX/classes">
|
||||
<include name="**/*.class"/>
|
||||
</fileset>
|
||||
<zipfileset src="lib/jutils.jar" includes="**/*.class"/>
|
||||
<manifest>
|
||||
<attribute name="Sealed" value="true"/>
|
||||
</manifest>
|
||||
</jar>
|
||||
<tar destfile="dist/jinput_osx.tgz" compression="gzip">
|
||||
<tarfileset dir=".">
|
||||
<include name="dist/jinput-osx.jar"/>
|
||||
</tarfileset>
|
||||
<tarfileset dir="plugins/OSX/bin">
|
||||
<include name="*.jnilib"/>
|
||||
</tarfileset>
|
||||
</tar>
|
||||
</target>
|
||||
|
||||
<target name="install" description="Installs jinput in to local mvn repo">
|
||||
<path id="maven-ant-tasks.classpath" path="lib/maven-ant-tasks-2.1.0.jar" />
|
||||
<typedef resource="org/apache/maven/artifact/ant/antlib.xml" uri="urn:maven-artifact-ant"
|
||||
classpathref="maven-ant-tasks.classpath"/>
|
||||
|
||||
<filter token="VERSION" value="${mvn.version}"/>
|
||||
<copy tofile="dist/jinput-${mvn.version}.pom" filtering="true">
|
||||
<fileset file="jinput.pom"/>
|
||||
</copy>
|
||||
<copy tofile="dist/jinput-${mvn.version}-platform.pom" filtering="true">
|
||||
<fileset file="jinput-platform.pom"/>
|
||||
</copy>
|
||||
|
||||
<artifact:pom id="jinputpomfile" file="dist/jinput-${mvn.version}.pom" />
|
||||
<artifact:pom id="jinputplatformpomfile" file="dist/jinput-${mvn.version}-platform.pom" />
|
||||
|
||||
<delete file="dist/jinput-natives-windows.zip" failonerror="false"/>
|
||||
<zip destfile="dist/jinput-natives-windows.zip">
|
||||
<fileset dir="dist/">
|
||||
<include name="**/*.dll"/>
|
||||
</fileset>
|
||||
</zip>
|
||||
|
||||
<delete file="dist/jinput-natives-linux.zip" failonerror="false"/>
|
||||
<zip destfile="dist/jinput-natives-linux.zip">
|
||||
<fileset dir="dist/">
|
||||
<include name="**/*.so"/>
|
||||
</fileset>
|
||||
</zip>
|
||||
|
||||
<delete file="dist/jinput-natives-osx.zip" failonerror="false"/>
|
||||
<zip destfile="dist/jinput-natives-osx.zip" >
|
||||
<fileset dir="dist/">
|
||||
<include name="**/*.jnilib"/>
|
||||
</fileset>
|
||||
</zip>
|
||||
|
||||
<delete file="dist/jinput-javadoc.zip" failonerror="false"/>
|
||||
<zip destfile="dist/jinput-javadoc.zip">
|
||||
<fileset dir="coreAPI/apidocs/"/>
|
||||
</zip>
|
||||
|
||||
<delete file="dist/jinput-sources.zip" failonerror="false"/>
|
||||
<zip destfile="dist/jinput-sources.zip">
|
||||
<fileset dir=".">
|
||||
<include name="**/*.java"/>
|
||||
<include name="**/*.h"/>
|
||||
<include name="**/*.c"/>
|
||||
</fileset>
|
||||
</zip>
|
||||
|
||||
<zip destfile="dist/jinput-${mvn.version}.jar">
|
||||
<zipfileset src="dist/jinput.jar">
|
||||
<exclude name="net/java/games/util/**"/>
|
||||
</zipfileset>
|
||||
</zip>
|
||||
|
||||
<artifact:install file="dist/jinput-${mvn.version}.jar">
|
||||
<pom refid="jinputpomfile" />
|
||||
<attach file="dist/jinput-javadoc.zip" classifier="javadoc" type="jar"/>
|
||||
<attach file="dist/jinput-sources.zip" classifier="sources" type="jar"/>
|
||||
</artifact:install>
|
||||
|
||||
<artifact:install file="dist/jinput=${mvn.version}-platform.pom">
|
||||
<pom refid="jinputplatformpomfile" />
|
||||
<attach file="dist/jinput-natives-windows.zip" classifier="natives-windows" type="jar"/>
|
||||
<attach file="dist/jinput-natives-linux.zip" classifier="natives-linux" type="jar"/>
|
||||
<attach file="dist/jinput-natives-osx.zip" classifier="natives-osx" type="jar"/>
|
||||
</artifact:install>
|
||||
</target>
|
||||
|
||||
<target name="mvndeploy" depends="install" description="Installs jinput in to local mvn repo">
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-gpg-plugin:1.3:sign-and-deploy-file" />
|
||||
<arg value="-Durl=${maven-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-repository-id}" />
|
||||
<arg value="-DpomFile=dist/jinput-${mvn.version}.pom" />
|
||||
<arg value="-Dfile=dist/jinput-${mvn.version}.jar" />
|
||||
<arg value="-Pgpg" />
|
||||
</artifact:mvn>
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-gpg-plugin:1.3:sign-and-deploy-file" />
|
||||
<arg value="-Durl=${maven-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-repository-id}" />
|
||||
<arg value="-DpomFile=dist/jinput-${mvn.version}.pom" />
|
||||
<arg value="-Dfile=dist/jinput-javadoc.zip" />
|
||||
<arg value="-Dpackaging=jar"/>
|
||||
<arg value="-Dclassifier=javadoc" />
|
||||
<arg value="-Pgpg" />
|
||||
</artifact:mvn>
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-gpg-plugin:1.3:sign-and-deploy-file" />
|
||||
<arg value="-Durl=${maven-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-repository-id}" />
|
||||
<arg value="-DpomFile=dist/jinput-${mvn.version}.pom" />
|
||||
<arg value="-Dfile=dist/jinput-sources.zip" />
|
||||
<arg value="-Dpackaging=jar"/>
|
||||
<arg value="-Dclassifier=sources" />
|
||||
<arg value="-Pgpg" />
|
||||
</artifact:mvn>
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-gpg-plugin:1.3:sign-and-deploy-file" />
|
||||
<arg value="-Durl=${maven-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-repository-id}" />
|
||||
<arg value="-DpomFile=dist/jinput-${mvn.version}-platform.pom" />
|
||||
<arg value="-Dfile=dist/jinput-natives-windows.zip" />
|
||||
<arg value="-Dpackaging=jar"/>
|
||||
<arg value="-Dclassifier=natives-windows" />
|
||||
<arg value="-Pgpg" />
|
||||
</artifact:mvn>
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-gpg-plugin:1.3:sign-and-deploy-file" />
|
||||
<arg value="-Durl=${maven-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-repository-id}" />
|
||||
<arg value="-DpomFile=dist/jinput-${mvn.version}-platform.pom" />
|
||||
<arg value="-Dfile=dist/jinput-natives-linux.zip" />
|
||||
<arg value="-Dpackaging=jar"/>
|
||||
<arg value="-Dclassifier=natives-linux" />
|
||||
<arg value="-Pgpg" />
|
||||
</artifact:mvn>
|
||||
<artifact:mvn>
|
||||
<arg value="org.apache.maven.plugins:maven-gpg-plugin:1.3:sign-and-deploy-file" />
|
||||
<arg value="-Durl=${maven-repository-url}" />
|
||||
<arg value="-DrepositoryId=${maven-repository-id}" />
|
||||
<arg value="-DpomFile=dist/jinput-${mvn.version}-platform.pom" />
|
||||
<arg value="-Dfile=dist/jinput-natives-osx.zip" />
|
||||
<arg value="-Dpackaging=jar"/>
|
||||
<arg value="-Dclassifier=natives-osx" />
|
||||
<arg value="-Pgpg" />
|
||||
</artifact:mvn>
|
||||
</target>
|
||||
</project>
|
||||
1
coreAPI/.gitignore
vendored
1
coreAPI/.gitignore
vendored
|
|
@ -1 +0,0 @@
|
|||
/build.number
|
||||
|
|
@ -1,54 +0,0 @@
|
|||
This file modified last on 06/06/2003 by Jeff Kesselman
|
||||
|
||||
This is the source tree for the core input API.
|
||||
|
||||
Directory Organization:
|
||||
|
||||
The root contains a master ANT build.xml.
|
||||
After a successful build of the project you will have the following sub directories:
|
||||
-- apidocs Where the javadocs get built to
|
||||
-- lib Where dependant libraries are kept.
|
||||
-- bin Where the actual API is built to
|
||||
-- src The source files.
|
||||
-- src/test Execution directories and data for tests.
|
||||
|
||||
Build instructions:
|
||||
|
||||
To clean: ant clean
|
||||
To build: ant all (or just ant)
|
||||
To build docs: ant javadoc
|
||||
To test:
|
||||
Textest: A simple discovery test that dumps
|
||||
the data about the discovered controllers to stdout
|
||||
To run: ant textest
|
||||
Readtest: A test that creates a window for each discovered
|
||||
controller (or sub-controller) which displays the
|
||||
current state of all the controller's axiis.
|
||||
(Note: The windows currrently all open at the same
|
||||
place on the screen so yo uwill have to move them to
|
||||
see them all.)
|
||||
To run: ant readtest
|
||||
|
||||
|
||||
Release Info:
|
||||
Initial Release: This release contains an implementation of the input
|
||||
API designed by Mike Martak of Sun and Thomas (?) of Sony CEA for
|
||||
the WIn32 platform. All the code in src/input is cross platform. The
|
||||
Win32 code is segregated to the DirectX plugin (src/DXplugin) which
|
||||
depends on DirectInput from DX7 (or later).
|
||||
|
||||
05/09/2003: A number of bugs and problems with the DXPlugin are fixed in this
|
||||
release. This release also brings the code up to date using the DI8
|
||||
interface. This thus is the first release that requries Peter Puck's
|
||||
DX8 bindings to compile with MinGW.
|
||||
|
||||
05/09/2003 (second update):
|
||||
This version adds a new standard value type to the API.
|
||||
Axis.POV holds standard definitions for values for POV (hat) switches
|
||||
-- Axis.POV.CENTER and Axis.POV.OFF are synonmous and are
|
||||
the center position.
|
||||
-- Axis.POV.UP, Axis.POV.DOWN, Axis.POV.LEFT and Axis.POV.RIGHT
|
||||
should be self explainatory.
|
||||
Any hat that claims to be "normalized" will return these values. (It is
|
||||
recommended that all hats be normalized by the systemn specific plugins.)
|
||||
|
||||
|
|
@ -1,68 +0,0 @@
|
|||
<?xml version="1.0"?>
|
||||
|
||||
<project name="Game Input API" basedir="." default="all">
|
||||
<target name="init">
|
||||
<property name="utils" location="../lib/jutils.jar"/>
|
||||
<mkdir dir="apidocs"/>
|
||||
<mkdir dir="classes"/>
|
||||
<mkdir dir="bin"/>
|
||||
<mkdir dir="build"/>
|
||||
</target>
|
||||
|
||||
<target name="compile" depends="init">
|
||||
<javac srcdir="src/java" destdir="classes" debug="true" deprecation="true" source="1.4" target="1.4">
|
||||
<include name="net/**"/>
|
||||
<exclude name="**/Version.java"/>
|
||||
<!-- To add something to the classpath: -->
|
||||
<classpath>
|
||||
<pathelement location="${utils}"/>
|
||||
</classpath>
|
||||
</javac>
|
||||
<buildnumber/>
|
||||
<copy file="src/java/net/java/games/input/Version.java"
|
||||
todir="build/src/java/net/java/games/input/" overwrite="true">
|
||||
<filterset>
|
||||
<filter token="BUILD_NUMBER" value="${build.number}"/>
|
||||
<filter token="API_VERSION" value="${api.version}"/>
|
||||
</filterset>
|
||||
</copy>
|
||||
<javac srcdir="build/src/java" destdir="classes" debug="true" deprecation="true" source="1.4" target="1.4">
|
||||
<include name="net/**" />
|
||||
</javac>
|
||||
<echo message="Build version class for ${api.version} build ${build.number}"/>
|
||||
</target>
|
||||
|
||||
<target name="jar" depends="init,compile">
|
||||
<jar jarfile="bin/jinput-core.jar" compress="true" basedir="classes">
|
||||
<include name="net/java/games/input/*class"/>
|
||||
</jar>
|
||||
<jar jarfile="bin/jinput-test.jar" compress="true" basedir="classes">
|
||||
<include name="net/java/games/input/test/*class"/>
|
||||
</jar>
|
||||
</target>
|
||||
|
||||
<target name="javadoc" depends="init" description="Javadoc for my API.">
|
||||
<javadoc packagenames="net.java.games.input.*"
|
||||
destdir="apidocs"
|
||||
additionalparam="-source 1.4"
|
||||
excludepackagenames="net.java.games.input.example.*,net.java.games.input.test.*">
|
||||
<sourcepath>
|
||||
<pathelement location="src/java"/>
|
||||
</sourcepath>
|
||||
<classpath>
|
||||
<pathelement location="${utils}"/>
|
||||
</classpath>
|
||||
</javadoc>
|
||||
</target>
|
||||
|
||||
<target name="clean" depends="init" description="Clean all build products.">
|
||||
<delete dir="classes"/>
|
||||
<delete dir="bin"/>
|
||||
<delete dir="apidocs"/>
|
||||
<delete dir="build"/>
|
||||
</target>
|
||||
|
||||
<target name="all" depends="init,jar" description="Build everything.">
|
||||
<echo message="JInput has been built and jinput.jar is located in the bin directory."/>
|
||||
</target>
|
||||
</project>
|
||||
31
coreAPI/pom.xml
Normal file
31
coreAPI/pom.xml
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>coreapi</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<name>JInput - core API</name>
|
||||
|
||||
<parent>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>jinput-parent</artifactId>
|
||||
<version>2.0.8-SNAPSHOT</version>
|
||||
<relativePath>../</relativePath>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.java.jutils</groupId>
|
||||
<artifactId>jutils</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-source-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
|
|
@ -33,9 +33,14 @@
|
|||
|
||||
package net.java.games.input;
|
||||
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.util.Properties;
|
||||
|
||||
/**
|
||||
* The version and build number of this implementation.
|
||||
* Version numbers for a release are of the form: w.x.y[-a]-z, where:
|
||||
* Version numbers for a release are of the form: w.x.y, where:
|
||||
* <ul>
|
||||
* <li>
|
||||
* w - the major version number of the release. This number should
|
||||
|
|
@ -53,27 +58,13 @@ package net.java.games.input;
|
|||
* bump in the minor-minor version number signifies that new bug
|
||||
* fixes have been added to the build.
|
||||
* </li>
|
||||
* <li>
|
||||
* a - an optional build designator followed by a digit. Valid build
|
||||
* designators are:
|
||||
* <ul>
|
||||
* <li>alpha</li>
|
||||
* <li>beta</li>
|
||||
* </ul>
|
||||
* </li>
|
||||
* <li>
|
||||
* z - build number. This is used to specify the build number of the
|
||||
* release. This is usually only important to people that use
|
||||
* the daily build of a project. The format is the lower-case
|
||||
* letter 'b' followed by a two digit number.
|
||||
* </li>
|
||||
* </ul>
|
||||
*
|
||||
* For example, the following are all valid version strings:
|
||||
* <ul>
|
||||
* <li>1.1.2-b02</li>
|
||||
* <li>1.3.5-alpha1-b19</li>
|
||||
* <li>4.7.1-beta3-b20</li>
|
||||
* <li>1.1.2</li>
|
||||
* <li>1.3.5-SNAPSHOT</li>
|
||||
* <li>4.7.1-M2</li>
|
||||
* </ul>
|
||||
*
|
||||
*/
|
||||
|
|
@ -86,33 +77,26 @@ public final class Version {
|
|||
private Version() {
|
||||
}
|
||||
|
||||
/**
|
||||
* Version string of this build.
|
||||
*/
|
||||
private static final String apiVersion = "@API_VERSION@";
|
||||
private static final String buildNumber = "@BUILD_NUMBER@";
|
||||
|
||||
/*
|
||||
* Split so that ant does not replace the token;
|
||||
*/
|
||||
private static final String antBuildNumberToken = "@BUILD_" + "NUMBER@";
|
||||
private static final String antAPIVersionToken = "@API_" + "VERSION@";
|
||||
|
||||
/**
|
||||
* Returns the verison string and build number of
|
||||
* this implementation. See the class descritpion
|
||||
* for the version string format.
|
||||
* for the version string format.
|
||||
*
|
||||
* @return The version string of this implementation.
|
||||
*/
|
||||
public static String getVersion() {
|
||||
String version = "Unversioned";
|
||||
if(!antAPIVersionToken.equals(apiVersion)) {
|
||||
version = apiVersion;
|
||||
}
|
||||
if(!antBuildNumberToken.equals(buildNumber)) {
|
||||
version += "-b" + buildNumber;
|
||||
}
|
||||
return version;
|
||||
String version = "Unversioned";
|
||||
try {
|
||||
Properties p = new Properties();
|
||||
InputStream is = Version.class.getResourceAsStream("/META-INF/maven/net.java.jinput/coreapi/pom.properties");
|
||||
if(is != null) {
|
||||
p.load(is);
|
||||
version = p.getProperty("version", "");
|
||||
}
|
||||
} catch(IOException e) {
|
||||
// ignore
|
||||
}
|
||||
|
||||
return version;
|
||||
}
|
||||
}
|
||||
170
examples/pom.xml
Normal file
170
examples/pom.xml
Normal file
|
|
@ -0,0 +1,170 @@
|
|||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>examples</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<name>JInput - examples</name>
|
||||
|
||||
<parent>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>jinput-parent</artifactId>
|
||||
<version>2.0.8-SNAPSHOT</version>
|
||||
<relativePath>../</relativePath>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>coreapi</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<!--
|
||||
<dependency>
|
||||
<groupId>${project.groupId}</groupId>
|
||||
<artifactId>windows-plugin</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<classifier>natives-windows</classifier>
|
||||
</dependency>
|
||||
-->
|
||||
<!--
|
||||
<dependency>
|
||||
<groupId>${project.groupId}</groupId>
|
||||
<artifactId>osx-plugin</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<classifier>natives-osx</classifier>
|
||||
</dependency>
|
||||
-->
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-source-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>com.googlecode.mavennatives</groupId>
|
||||
<artifactId>maven-nativedependencies-plugin</artifactId>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
<profiles>
|
||||
<profile>
|
||||
<id>linux</id>
|
||||
<activation>
|
||||
<os>
|
||||
<family>linux</family>
|
||||
</os>
|
||||
</activation>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>${project.groupId}</groupId>
|
||||
<artifactId>linux-plugin</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<classifier>natives-linux</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>${project.groupId}</groupId>
|
||||
<artifactId>linux-plugin</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>osx</id>
|
||||
<activation>
|
||||
<os>
|
||||
<family>mac</family>
|
||||
</os>
|
||||
</activation>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>${project.groupId}</groupId>
|
||||
<artifactId>osx-plugin</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<classifier>natives-osx</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>${project.groupId}</groupId>
|
||||
<artifactId>osx-plugin</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>windows</id>
|
||||
<activation>
|
||||
<os>
|
||||
<family>windows</family>
|
||||
</os>
|
||||
</activation>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>${project.groupId}</groupId>
|
||||
<artifactId>windows-plugin</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<classifier>natives-windows</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>${project.groupId}</groupId>
|
||||
<artifactId>windows-plugin</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>wintab</id>
|
||||
<activation>
|
||||
<os>
|
||||
<family>windows</family>
|
||||
</os>
|
||||
<property>
|
||||
<name>env.WINTABSDKDIR</name>
|
||||
</property>
|
||||
</activation>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>${project.groupId}</groupId>
|
||||
<artifactId>wintab-plugin</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<classifier>natives-wintab</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>${project.groupId}</groupId>
|
||||
<artifactId>wintab-plugin</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>ReadAllEvents</id>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.codehaus.mojo</groupId>
|
||||
<artifactId>exec-maven-plugin</artifactId>
|
||||
<version>1.6.0</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<goals>
|
||||
<goal>exec</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
<configuration>
|
||||
<executable>java</executable>
|
||||
<arguments>
|
||||
<argument>-classpath</argument>
|
||||
<classpath/>
|
||||
<argument>-Djava.library.path=${project.build.directory}/natives</argument>
|
||||
<argument>net.java.games.input.example.ReadAllEvents</argument>
|
||||
</arguments>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</profile>
|
||||
</profiles>
|
||||
</project>
|
||||
|
|
@ -3,7 +3,6 @@ package net.java.games.input.example;
|
|||
import net.java.games.input.Component;
|
||||
import net.java.games.input.Controller;
|
||||
import net.java.games.input.ControllerEnvironment;
|
||||
import net.java.games.input.test.ControllerTextTest;
|
||||
|
||||
/**
|
||||
* This class shows how to read the values in a polling loop for the first mouse
|
||||
|
|
@ -1,27 +0,0 @@
|
|||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>jinput-platform</artifactId>
|
||||
<packaging>pom</packaging>
|
||||
<name>JInput natives</name>
|
||||
<version>@VERSION@</version>
|
||||
<description>Library for access to input devices.</description>
|
||||
<url>https://github.com/jinput/jinput</url>
|
||||
<licenses>
|
||||
<license>
|
||||
<name>BSD</name>
|
||||
<url>http://www.opensource.org/licenses/bsd-license.php</url>
|
||||
<distribution>repo</distribution>
|
||||
</license>
|
||||
</licenses>
|
||||
<developers>
|
||||
<developer>
|
||||
<id>Members</id>
|
||||
<url>https://github.com/jinput/jinput/graphs/contributors</url>
|
||||
</developer>
|
||||
</developers>
|
||||
<scm>
|
||||
<url>https://github.com/jinput/jinput</url>
|
||||
<connection>scm:git:git@github.com:jinput/jinput.git</connection>
|
||||
</scm>
|
||||
</project>
|
||||
55
jinput.pom
55
jinput.pom
|
|
@ -1,55 +0,0 @@
|
|||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>jinput</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<name>JInput</name>
|
||||
<version>@VERSION@</version>
|
||||
<description>Library for access to input devices.</description>
|
||||
<url>https://github.com/jinput/jinput</url>
|
||||
<licenses>
|
||||
<license>
|
||||
<name>BSD</name>
|
||||
<url>http://www.opensource.org/licenses/bsd-license.php</url>
|
||||
<distribution>repo</distribution>
|
||||
</license>
|
||||
</licenses>
|
||||
<developers>
|
||||
<developer>
|
||||
<id>Members</id>
|
||||
<url>https://github.com/jinput/jinput/graphs/contributors</url>
|
||||
</developer>
|
||||
</developers>
|
||||
<scm>
|
||||
<url>https://github.com/jinput/jinput</url>
|
||||
<connection>https://github.com/jinput/jinput</connection>
|
||||
</scm>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.java.jutils</groupId>
|
||||
<artifactId>jutils</artifactId>
|
||||
<version>1.0.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>jinput-platform</artifactId>
|
||||
<version>@VERSION@</version>
|
||||
<classifier>natives-linux</classifier>
|
||||
<scope>runtime</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>jinput-platform</artifactId>
|
||||
<version>@VERSION@</version>
|
||||
<classifier>natives-windows</classifier>
|
||||
<scope>runtime</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>jinput-platform</artifactId>
|
||||
<version>@VERSION@</version>
|
||||
<classifier>natives-osx</classifier>
|
||||
<scope>runtime</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
2
lib/.gitignore
vendored
2
lib/.gitignore
vendored
|
|
@ -1,2 +0,0 @@
|
|||
/jutils-1.0.1-SNAPSHOT.jar
|
||||
/jutils.jar
|
||||
Binary file not shown.
|
|
@ -1,80 +1,52 @@
|
|||
<?xml version="1.0" ?>
|
||||
<project basedir="." default="all" name="OSX Plugin">
|
||||
<description>OSX JInput Plugin</description>
|
||||
<property name="src" location="src" />
|
||||
<property name="build" location="classes"/>
|
||||
<property name="bin" location="bin" />
|
||||
<property name="plugins" location="plugins" />
|
||||
|
||||
<target name="init">
|
||||
<mkdir dir="${build}"/>
|
||||
<mkdir dir="${bin}"/>
|
||||
<condition property="macosx">
|
||||
<and>
|
||||
<os family="mac" />
|
||||
<os family="unix" />
|
||||
</and>
|
||||
</condition>
|
||||
</target>
|
||||
<project name="OS X Plugin, Native code" basedir="." default="compileNativeJinputLib">
|
||||
<description>OSX JInput Native Plugin</description>
|
||||
|
||||
<target depends="init" name="compile">
|
||||
<javac debug="true" deprecation="true" destdir="${build}" source="1.4" srcdir="src/java">
|
||||
<classpath>
|
||||
<pathelement location="../../coreAPI/bin/jinput-core.jar"/>
|
||||
<pathelement location="../../lib/jutils.jar"/>
|
||||
</classpath>
|
||||
</javac>
|
||||
</target>
|
||||
|
||||
<target depends="init,compile" name="jar">
|
||||
<jar jarfile="${bin}/HIDWrapper.jar" compress="true" basedir="${build}">
|
||||
<include name="**/*.class"/>
|
||||
</jar>
|
||||
</target>
|
||||
|
||||
<target depends="compileNativeJinputLib,jar" description="Build everything." name="all">
|
||||
</target>
|
||||
|
||||
<target name="javadoc" depends="init" description="Javadoc for OS X plugin for JInput.">
|
||||
<mkdir dir="apidocs"/>
|
||||
<javadoc packagenames="net.java.games.input.*"
|
||||
destdir="apidocs"
|
||||
additionalparam="-source 1.4"
|
||||
link="../../../coreAPI/apidocs">
|
||||
<sourcepath>
|
||||
<pathelement location="src/java"/>
|
||||
</sourcepath>
|
||||
<classpath>
|
||||
<pathelement location="../../coreAPI/bin/jinput-core.jar"/>
|
||||
<pathelement location="../../lib/jutils.jar"/>
|
||||
</classpath>
|
||||
</javadoc>
|
||||
</target>
|
||||
|
||||
<target description="Clean all build products." name="clean">
|
||||
<delete dir="classes" failonerror="no"/>
|
||||
<delete dir="bin" failonerror="no"/>
|
||||
<delete dir="apidocs" failonerror="no"/>
|
||||
<ant inheritAll="false" antfile="src/native/build.xml" target="clean"/>
|
||||
</target>
|
||||
|
||||
<target depends="init,compile" name="createJNIHeaders">
|
||||
<javah destdir="src/native">
|
||||
<classpath>
|
||||
<pathelement path="${build}"/>
|
||||
<pathelement location="../../coreAPI/classes"/>
|
||||
</classpath>
|
||||
<class name="net.java.games.input.OSXHIDDeviceIterator"/>
|
||||
<class name="net.java.games.input.OSXHIDDevice"/>
|
||||
<class name="net.java.games.input.OSXHIDQueue"/>
|
||||
</javah>
|
||||
</target>
|
||||
<target name="init">
|
||||
<mkdir dir="target/natives/x86_64"/>
|
||||
</target>
|
||||
|
||||
<target name="compile">
|
||||
<apply dir="${dstdir}" executable="${compiler}" os="Mac OS X" skipemptyfilesets="true" failonerror="true" dest="${dstdir}">
|
||||
<arg line="${cflags} -O2 -Wall -c -fPIC -I${sdkroot}/System/Library/Frameworks/JavaVM.framework/Versions/A/Headers -I../../../../common/src/native -I../../generated-sources/natives/"/>
|
||||
<mapper type="glob" from="*.c" to="*.o"/>
|
||||
<fileset dir="src/main/native" includes="*.c"/>
|
||||
<fileset dir="../common/src/native" includes="*.c"/>
|
||||
</apply>
|
||||
</target>
|
||||
|
||||
<target name="compileNativeJinputLib" depends="init,createJNIHeaders" if="macosx">
|
||||
<ant dir="src/native" target="compileNativeJinputLib"/>
|
||||
<copy todir="${bin}">
|
||||
<fileset dir="src/native" includes="*.jnilib"/>
|
||||
</copy>
|
||||
</target>
|
||||
<target name="link">
|
||||
<apply dir="${objdir}" parallel="true" executable="${linker}" os="Mac OS X" failonerror="true" skipemptyfilesets="true">
|
||||
<arg line="${linkerflags} -dynamiclib -o ${libname} -framework JavaVM -framework CoreFoundation -framework IOKit -framework CoreServices"/>
|
||||
<fileset dir="${objdir}" includes="*.o"/>
|
||||
</apply>
|
||||
<apply dir="${objdir}" executable="strip" os="Mac OS X" failonerror="true">
|
||||
<arg line="-S -X"/>
|
||||
<fileset dir="." includes="${libname}"/>
|
||||
</apply>
|
||||
</target>
|
||||
|
||||
<target name="compileNativeJinputLib" depends="init">
|
||||
<property name="x86_64_sdkroot" location="/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk"/>
|
||||
<property name="x86_64_flags" value="-isysroot ${x86_64_sdkroot} -arch x86_64 -mmacosx-version-min=10.5"/>
|
||||
<antcall target="compile">
|
||||
<param name="dstdir" location="target/natives/x86_64"/>
|
||||
<param name="compiler" value="gcc"/>
|
||||
<param name="sdkroot" location="${x86_64_sdkroot}"/>
|
||||
<param name="cflags" value="${x86_64_flags}"/>
|
||||
</antcall>
|
||||
<antcall target="link">
|
||||
<param name="objdir" location="target/natives/x86_64"/>
|
||||
<param name="libname" value="libjinput-osx-x86_64.jnilib"/>
|
||||
<param name="linker" value="gcc"/>
|
||||
<param name="linkerflags" value="${x86_64_flags}"/>
|
||||
</antcall>
|
||||
<apply dir="target/natives" parallel="true" executable="lipo" os="Mac OS X" failonerror="true" skipemptyfilesets="true" >
|
||||
<arg value="-create"/>
|
||||
<srcfile/>
|
||||
<arg value="-output"/>
|
||||
<arg path="target/natives/libjinput-osx.jnilib"/>
|
||||
<fileset file="target/natives/x86_64/libjinput-osx-x86_64.jnilib"/>
|
||||
</apply>
|
||||
</target>
|
||||
</project>
|
||||
|
|
|
|||
75
plugins/OSX/pom.xml
Normal file
75
plugins/OSX/pom.xml
Normal file
|
|
@ -0,0 +1,75 @@
|
|||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>osx-plugin</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<name>JInput - OSX Plugin</name>
|
||||
|
||||
<parent>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>plugins</artifactId>
|
||||
<version>2.0.8-SNAPSHOT</version>
|
||||
<relativePath>../</relativePath>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>coreapi</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-source-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<configuration>
|
||||
<compilerArgs>
|
||||
<arg>-h</arg>
|
||||
<arg>${project.build.directory}/generated-sources/natives</arg>
|
||||
</compilerArgs>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-antrun-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<phase>compile</phase>
|
||||
<configuration>
|
||||
<target>
|
||||
<ant dir="." target="compileNativeJinputLib"/>
|
||||
</target>
|
||||
</configuration>
|
||||
<goals>
|
||||
<goal>run</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-jar-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<phase>package</phase>
|
||||
<goals>
|
||||
<goal>jar</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<classesDirectory>${project.build.directory}/natives</classesDirectory>
|
||||
<classifier>natives-osx</classifier>
|
||||
<includes>
|
||||
<include>*.jnilib</include>
|
||||
</includes>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
3
plugins/OSX/src/native/.gitignore
vendored
3
plugins/OSX/src/native/.gitignore
vendored
|
|
@ -1,3 +0,0 @@
|
|||
/net_java_games_input_OSXHIDDevice.h
|
||||
/net_java_games_input_OSXHIDDeviceIterator.h
|
||||
/net_java_games_input_OSXHIDQueue.h
|
||||
|
|
@ -1,93 +0,0 @@
|
|||
<?xml version="1.0" ?>
|
||||
<project name="OS X Plugin, Native code" basedir="." default="compileNativeJinputLib">
|
||||
<description>OSX JInput Native Plugin</description>
|
||||
|
||||
<target name="init">
|
||||
<mkdir dir="ppc"/>
|
||||
<mkdir dir="i386"/>
|
||||
<mkdir dir="x86_64"/>
|
||||
</target>
|
||||
|
||||
<target name="clean">
|
||||
<delete failonerror="false">
|
||||
<fileset dir="i386"/>
|
||||
<fileset dir="x86_64"/>
|
||||
<fileset dir="ppc"/>
|
||||
<fileset file="libjinput-osx.jnilib"/>
|
||||
</delete>
|
||||
</target>
|
||||
|
||||
<target name="compile">
|
||||
<apply dir="${dstdir}" executable="${compiler}" os="Mac OS X" skipemptyfilesets="true" failonerror="true" dest="${dstdir}">
|
||||
<arg line="${cflags} -O2 -Wall -c -fPIC -I${sdkroot}/System/Library/Frameworks/JavaVM.framework/Versions/A/Headers -I../../../../common/src/native -I.."/>
|
||||
<mapper type="glob" from="*.c" to="*.o"/>
|
||||
<fileset dir="." includes="*.c"/>
|
||||
<fileset dir="../../../common/src/native" includes="*.c"/>
|
||||
</apply>
|
||||
</target>
|
||||
|
||||
<target name="link">
|
||||
<apply dir="${objdir}" parallel="true" executable="${linker}" os="Mac OS X" failonerror="true" skipemptyfilesets="true">
|
||||
<arg line="${linkerflags} -dynamiclib -o ${libname} -framework JavaVM -framework CoreFoundation -framework IOKit -framework CoreServices"/>
|
||||
<fileset dir="${objdir}" includes="*.o"/>
|
||||
</apply>
|
||||
<apply dir="${objdir}" executable="strip" os="Mac OS X" failonerror="true">
|
||||
<arg line="-S -X"/>
|
||||
<fileset dir="." includes="${libname}"/>
|
||||
</apply>
|
||||
</target>
|
||||
|
||||
<target name="compileNativeJinputLib" depends="init">
|
||||
<property name="ppc_sdkroot" location="/Developer/SDKs/MacOSX10.3.9.sdk"/>
|
||||
<property name="universal_sdkroot" location="/Developer/SDKs/MacOSX10.4u.sdk"/>
|
||||
<property name="x86_64_sdkroot" location="/Developer/SDKs/MacOSX10.5.sdk"/>
|
||||
<property name="ppc_flags" value="-isysroot ${universal_sdkroot} -arch ppc -mmacosx-version-min=10.3"/>
|
||||
<property name="universal_flags" value="-isysroot ${universal_sdkroot} -arch i386 -mmacosx-version-min=10.4"/>
|
||||
<property name="x86_64_flags" value="-isysroot ${x86_64_sdkroot} -arch x86_64 -mmacosx-version-min=10.5"/>
|
||||
<antcall target="compile">
|
||||
<param name="dstdir" location="ppc"/>
|
||||
<param name="compiler" value="gcc-4.0"/>
|
||||
<param name="sdkroot" location="${universal_sdkroot}"/>
|
||||
<param name="cflags" value="${ppc_flags}"/>
|
||||
</antcall>
|
||||
<antcall target="link">
|
||||
<param name="objdir" location="ppc"/>
|
||||
<param name="libname" value="libjinput-osx-ppc.jnilib"/>
|
||||
<param name="linker" value="gcc-4.0"/>
|
||||
<param name="linkerflags" value="${ppc_flags}"/>
|
||||
</antcall>
|
||||
<antcall target="compile">
|
||||
<param name="dstdir" location="i386"/>
|
||||
<param name="compiler" value="gcc-4.0"/>
|
||||
<param name="sdkroot" location="${universal_sdkroot}"/>
|
||||
<param name="cflags" value="${universal_flags}"/>
|
||||
</antcall>
|
||||
<antcall target="link">
|
||||
<param name="objdir" location="i386"/>
|
||||
<param name="libname" value="libjinput-osx-i386.jnilib"/>
|
||||
<param name="linker" value="gcc-4.0"/>
|
||||
<param name="linkerflags" value="${universal_flags}"/>
|
||||
</antcall>
|
||||
<antcall target="compile">
|
||||
<param name="dstdir" location="x86_64"/>
|
||||
<param name="compiler" value="gcc-4.0"/>
|
||||
<param name="sdkroot" location="${x86_64_sdkroot}"/>
|
||||
<param name="cflags" value="${x86_64_flags}"/>
|
||||
</antcall>
|
||||
<antcall target="link">
|
||||
<param name="objdir" location="x86_64"/>
|
||||
<param name="libname" value="libjinput-osx-x86_64.jnilib"/>
|
||||
<param name="linker" value="gcc-4.0"/>
|
||||
<param name="linkerflags" value="${x86_64_flags}"/>
|
||||
</antcall>
|
||||
<apply dir="." parallel="true" executable="lipo" os="Mac OS X" failonerror="true" skipemptyfilesets="true" >
|
||||
<arg value="-create"/>
|
||||
<srcfile/>
|
||||
<arg value="-output"/>
|
||||
<arg path="libjinput-osx.jnilib"/>
|
||||
<fileset file="ppc/libjinput-osx-ppc.jnilib"/>
|
||||
<fileset file="i386/libjinput-osx-i386.jnilib"/>
|
||||
<fileset file="x86_64/libjinput-osx-x86_64.jnilib"/>
|
||||
</apply>
|
||||
</target>
|
||||
</project>
|
||||
32
plugins/awt/pom.xml
Normal file
32
plugins/awt/pom.xml
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>awt-plugin</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<name>JInput - AWT Plugin</name>
|
||||
|
||||
<parent>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>plugins</artifactId>
|
||||
<version>2.0.8-SNAPSHOT</version>
|
||||
<relativePath>../</relativePath>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>coreapi</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-source-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
|
|
@ -1,72 +1,45 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project basedir="." default="all" name="Linux Plugin">
|
||||
<project basedir="." default="compileNativeJinputLib" name="Linux Plugin">
|
||||
<property name="libname64" value="libjinput-linux64.so"/>
|
||||
<property name="libname32" value="libjinput-linux.so"/>
|
||||
|
||||
<target name="init">
|
||||
<mkdir dir="classes"/>
|
||||
<mkdir dir="bin"/>
|
||||
<condition property="linux" >
|
||||
<!--<os family="unix" />-->
|
||||
<os name="Linux" />
|
||||
<mkdir dir="target/natives"/>
|
||||
</target>
|
||||
|
||||
<target name="createNativeDefinitions.java">
|
||||
<exec dir="src/main/native" executable="gawk" os="Linux" output="../java/net/java/games/input/NativeDefinitions.java">
|
||||
<arg line="-f"/>
|
||||
<arg line="getDefinitions"/>
|
||||
<arg line="/usr/include/linux/input.h"/>
|
||||
</exec>
|
||||
</target>
|
||||
|
||||
<target depends="init" name="compileNativeJinputLib">
|
||||
<exec executable="uname" outputproperty="hwplatform">
|
||||
<arg value="-m"/>
|
||||
</exec>
|
||||
<condition property="libname" value="${libname64}" else="${libname32}">
|
||||
<equals arg1="${hwplatform}" arg2="x86_64"/>
|
||||
</condition>
|
||||
|
||||
</target>
|
||||
|
||||
<target depends="init" name="compile">
|
||||
<!-- <ant dir="src/native" target="createNativeDefinitions.java"/>-->
|
||||
<javac debug="true" deprecation="true" destdir="classes" source="1.4" target="1.4" srcdir="src/java">
|
||||
<classpath>
|
||||
<pathelement location="../../coreAPI/bin/jinput-core.jar"/>
|
||||
<pathelement location="../../lib/jutils.jar"/>
|
||||
</classpath>
|
||||
</javac>
|
||||
</target>
|
||||
|
||||
<target depends="init,compile" name="jar">
|
||||
<jar jarfile="bin/linux.jar" compress="true" basedir="classes">
|
||||
<include name="**/*.class"/>
|
||||
</jar>
|
||||
</target>
|
||||
|
||||
<target depends="jar,compileNativeJinputLib" description="Build everything." name="all">
|
||||
</target>
|
||||
|
||||
<target name="javadoc" depends="init" description="Javadoc for Linux plugin for JInput.">
|
||||
<mkdir dir="apidocs"/>
|
||||
<javadoc packagenames="net.java.games.input.*"
|
||||
destdir="apidocs"
|
||||
additionalparam="-source 1.4"
|
||||
link="../../../coreAPI/apidocs">
|
||||
<sourcepath>
|
||||
<pathelement location="src/java"/>
|
||||
</sourcepath>
|
||||
<classpath>
|
||||
<pathelement location="../../coreAPI/bin/jinput-core.jar"/>
|
||||
<pathelement location="../../coreAPI/lib/jutils.jar"/>
|
||||
</classpath>
|
||||
</javadoc>
|
||||
</target>
|
||||
|
||||
<target description="Clean all build products." name="clean">
|
||||
<delete dir="classes" failonerror="no"/>
|
||||
<delete dir="bin" failonerror="no"/>
|
||||
<delete dir="apidocs" failonerror="no"/>
|
||||
<ant inheritAll="false" antfile="src/native/build.xml" target="clean"/>
|
||||
</target>
|
||||
|
||||
<target depends="init,compile" name="createJNIHeaders">
|
||||
<javah destdir="src/native">
|
||||
<classpath>
|
||||
<pathelement location="classes"/>
|
||||
<pathelement location="../../coreAPI/bin/jinput-core.jar"/>
|
||||
</classpath>
|
||||
<class name="net.java.games.input.LinuxEventDevice"/>
|
||||
<class name="net.java.games.input.LinuxJoystickDevice"/>
|
||||
</javah>
|
||||
</target>
|
||||
|
||||
<target depends="init,createJNIHeaders" name="compileNativeJinputLib" if="linux">
|
||||
<ant dir="src/native" target="compileNativeJinputLib"/>
|
||||
<copy todir="bin">
|
||||
<fileset dir="src/native" includes="libjinput-linux*.so"/>
|
||||
</copy>
|
||||
<apply dir="target/natives" executable="cc" os="Linux" dest="target/natives" skipemptyfilesets="true" failonerror="true">
|
||||
<arg line="-O2 -Wall -c -fPIC"/>
|
||||
<arg value="-I${java.home}/include"/>
|
||||
<arg value="-I${java.home}/include/linux"/>
|
||||
<arg value="-I${java.home}/../include"/>
|
||||
<arg value="-I${java.home}/../include/linux"/>
|
||||
<arg value="-I../../../common/src/native"/>
|
||||
<arg value="-I../generated-sources/natives"/>
|
||||
<mapper type="glob" from="*.c" to="*.o"/>
|
||||
<fileset dir="src/main/native" includes="*.c"/>
|
||||
<fileset dir="../common/src/native" includes="*.c"/>
|
||||
</apply>
|
||||
<apply dir="target/natives" parallel="true" executable="cc" os="Linux" failonerror="true">
|
||||
<arg line="-shared -O2 -Wall -o ${libname}"/>
|
||||
<fileset dir="target/natives" includes="*.o"/>
|
||||
</apply>
|
||||
<apply dir="target/natives" parallel="true" executable="strip" os="Linux" failonerror="true">
|
||||
<fileset file="target/natives/${libname}"/>
|
||||
</apply>
|
||||
</target>
|
||||
</project>
|
||||
|
|
|
|||
75
plugins/linux/pom.xml
Normal file
75
plugins/linux/pom.xml
Normal file
|
|
@ -0,0 +1,75 @@
|
|||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>linux-plugin</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<name>JInput - Linux Plugin</name>
|
||||
|
||||
<parent>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>plugins</artifactId>
|
||||
<version>2.0.8-SNAPSHOT</version>
|
||||
<relativePath>../</relativePath>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>coreapi</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-source-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<configuration>
|
||||
<compilerArgs>
|
||||
<arg>-h</arg>
|
||||
<arg>${project.build.directory}/generated-sources/natives</arg>
|
||||
</compilerArgs>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-antrun-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<phase>compile</phase>
|
||||
<configuration>
|
||||
<target>
|
||||
<ant dir="." target="compileNativeJinputLib"/>
|
||||
</target>
|
||||
</configuration>
|
||||
<goals>
|
||||
<goal>run</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-jar-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<phase>package</phase>
|
||||
<goals>
|
||||
<goal>jar</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<classesDirectory>${project.build.directory}/natives</classesDirectory>
|
||||
<classifier>natives-linux</classifier>
|
||||
<includes>
|
||||
<include>*.so</include>
|
||||
</includes>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
6
plugins/linux/src/native/.gitignore
vendored
6
plugins/linux/src/native/.gitignore
vendored
|
|
@ -1,6 +0,0 @@
|
|||
/net_java_games_input_LinuxEventDevice.h
|
||||
/net_java_games_input_LinuxJoystickDevice.h
|
||||
/libjinput-linux64.so
|
||||
/net_java_games_input_LinuxEventDevice.o
|
||||
/net_java_games_input_LinuxJoystickDevice.o
|
||||
/util.o
|
||||
|
|
@ -1,54 +0,0 @@
|
|||
<?xml version="1.0"?>
|
||||
|
||||
<!-- Written to assume that classpath is rooted in the current directory. -->
|
||||
<!-- So this should be OK if you make this script in the root of a filesystem. -->
|
||||
<!-- If not, you may prefer to adjust the basedir, or move some directories around. -->
|
||||
<!-- The idea is that both Ant and NetBeans have to know what the package root is -->
|
||||
<!-- for the classes in your application. -->
|
||||
<project name="JInput Linux port, Native code" basedir="." default="compileNativeJinputLib">
|
||||
<property name="libname64" value="libjinput-linux64.so"/>
|
||||
<property name="libname32" value="libjinput-linux.so"/>
|
||||
|
||||
<target name="createNativeDefinitions.java">
|
||||
<exec dir="." executable="gawk" os="Linux" output="../java/net/java/games/input/NativeDefinitions.java">
|
||||
<arg line="-f"/>
|
||||
<arg line="getDefinitions"/>
|
||||
<arg line="/usr/include/linux/input.h"/>
|
||||
</exec>
|
||||
</target>
|
||||
|
||||
<target name="clean">
|
||||
<delete>
|
||||
<fileset dir="." includes="*.o"/>
|
||||
<fileset dir="." includes="*.so"/>
|
||||
</delete>
|
||||
</target>
|
||||
|
||||
<target name="compileNativeJinputLib">
|
||||
<exec executable="uname" outputproperty="hwplatform">
|
||||
<arg value="-m"/>
|
||||
</exec>
|
||||
<condition property="libname" value="${libname64}" else="${libname32}">
|
||||
<equals arg1="${hwplatform}" arg2="x86_64"/>
|
||||
</condition>
|
||||
<apply dir="." executable="cc" os="Linux" dest="." skipemptyfilesets="true" failonerror="true">
|
||||
<arg line="-O2 -Wall -c -fPIC"/>
|
||||
<arg value="-I${java.home}/include"/>
|
||||
<arg value="-I${java.home}/include/linux"/>
|
||||
<arg value="-I${java.home}/../include"/>
|
||||
<arg value="-I${java.home}/../include/linux"/>
|
||||
<arg value="-I../../../common/src/native"/>
|
||||
<mapper type="glob" from="*.c" to="*.o"/>
|
||||
<fileset dir="." includes="*.c"/>
|
||||
<fileset dir="../../../common/src/native" includes="*.c"/>
|
||||
</apply>
|
||||
<apply dir="." parallel="true" executable="cc" os="Linux" failonerror="true">
|
||||
<arg line="-shared -O2 -Wall -o ${libname}"/>
|
||||
<fileset dir="." includes="*.o"/>
|
||||
</apply>
|
||||
<apply dir="." parallel="true" executable="strip" os="Linux" failonerror="true">
|
||||
<fileset file="${libname}"/>
|
||||
</apply>
|
||||
</target>
|
||||
</project>
|
||||
|
||||
67
plugins/pom.xml
Normal file
67
plugins/pom.xml
Normal file
|
|
@ -0,0 +1,67 @@
|
|||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<artifactId>plugins</artifactId>
|
||||
<packaging>pom</packaging>
|
||||
<name>JInput - plugins</name>
|
||||
|
||||
<parent>
|
||||
<groupId>net.java.jinput</groupId>
|
||||
<artifactId>jinput-parent</artifactId>
|
||||
<version>2.0.8-SNAPSHOT</version>
|
||||
<relativePath>../</relativePath>
|
||||
</parent>
|
||||
|
||||
<modules>
|
||||
<module>awt</module>
|
||||
</modules>
|
||||
|
||||
<profiles>
|
||||
<profile>
|
||||
<id>Linux</id>
|
||||
<activation>
|
||||
<os>
|
||||
<name>linux</name>
|
||||
</os>
|
||||
</activation>
|
||||
<modules>
|
||||
<module>linux</module>
|
||||
</modules>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>Windows</id>
|
||||
<activation>
|
||||
<os>
|
||||
<family>windows</family>
|
||||
</os>
|
||||
</activation>
|
||||
<modules>
|
||||
<module>windows</module>
|
||||
</modules>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>OSX</id>
|
||||
<activation>
|
||||
<os>
|
||||
<family>mac</family>
|
||||
</os>
|
||||
</activation>
|
||||
<modules>
|
||||
<module>OSX</module>
|
||||
</modules>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>wintab</id>
|
||||
<activation>
|
||||
<os>
|
||||
<family>windows</family>
|
||||
</os>
|
||||
<property>
|
||||
<name>env.WINTABSDKDIR</name>
|
||||
</property>
|
||||
</activation>
|
||||
<modules>
|
||||
<module>wintab</module>
|
||||
</modules>
|
||||
</profile>
|
||||
</profiles>
|
||||
</project>
|
||||
|
|
@ -1,86 +0,0 @@
|
|||
<?xml version="1.0"?>
|
||||
<project name="Direct Input Plugin" basedir="." default="all">
|
||||
<target name="init">
|
||||
<mkdir dir="classes"/>
|
||||
<mkdir dir="bin"/>
|
||||
<condition property="dx8" >
|
||||
<os family="Windows" />
|
||||
</condition>
|
||||
</target>
|
||||
|
||||
<target name="compile" depends="init">
|
||||
<javac srcdir="src/java" destdir="classes" debug="true" deprecation="true" source="1.4" target="1.4">
|
||||
<!-- To add something to the classpath: -->
|
||||
<classpath>
|
||||
<pathelement location="../../coreAPI/bin/jinput-core.jar"/>
|
||||
<pathelement location="../../lib/jutils.jar"/>
|
||||
</classpath>
|
||||
</javac>
|
||||
</target>
|
||||
|
||||
<target depends="init,compile" name="create_jniheaders">
|
||||
<javah destdir="src/native/dx8">
|
||||
<classpath>
|
||||
<pathelement path="classes"/>
|
||||
<pathelement location="../../coreAPI/classes"/>
|
||||
</classpath>
|
||||
<class name="net.java.games.input.IDirectInput"/>
|
||||
<class name="net.java.games.input.IDirectInputDevice"/>
|
||||
<class name="net.java.games.input.IDirectInputEffect"/>
|
||||
</javah>
|
||||
<javah destdir="src/native">
|
||||
<classpath>
|
||||
<pathelement path="classes"/>
|
||||
<pathelement location="../../coreAPI/classes"/>
|
||||
</classpath>
|
||||
<class name="net.java.games.input.DummyWindow"/>
|
||||
</javah>
|
||||
<javah destdir="src/native/raw">
|
||||
<classpath>
|
||||
<pathelement path="classes"/>
|
||||
<pathelement location="../../coreAPI/bin/jinput-core.jar"/>
|
||||
</classpath>
|
||||
<class name="net.java.games.input.RawInputEnvironmentPlugin"/>
|
||||
<class name="net.java.games.input.RawInputEventQueue"/>
|
||||
<class name="net.java.games.input.RawDevice"/>
|
||||
</javah>
|
||||
</target>
|
||||
|
||||
<target name="compile_native" depends="init,create_jniheaders" if="dx8">
|
||||
<ant dir="src/native" target="compile"/>
|
||||
<copy todir="bin">
|
||||
<fileset dir="src/native" includes="*.dll"/>
|
||||
</copy>
|
||||
</target>
|
||||
|
||||
<target name="jar" depends="init,compile">
|
||||
<jar jarfile="bin/dxinput.jar" compress="true" basedir="classes">
|
||||
<include name="**/*.class"/>
|
||||
</jar>
|
||||
</target>
|
||||
|
||||
<target name="all" depends="compile,compile_native,jar" description="Build everything.">
|
||||
</target>
|
||||
|
||||
<target name="javadoc" depends="init" description="Javadoc for my API.">
|
||||
<mkdir dir="apidocs"/>
|
||||
<javadoc packagenames="net.*"
|
||||
destdir="apidocs"
|
||||
additionalparam="-source 1.4">
|
||||
<sourcepath>
|
||||
<pathelement location="src/java"/>
|
||||
</sourcepath>
|
||||
<classpath>
|
||||
<pathelement location="../../bin/jinput-core.jar"/>
|
||||
<pathelement location="../../lib/jutils.jar"/>
|
||||
</classpath>
|
||||
</javadoc>
|
||||
</target>
|
||||
|
||||
<target name="clean" depends="init" description="Clean all build products.">
|
||||
<delete dir="classes" failonerror="no"/>
|
||||
<delete dir="bin" failonerror="no"/>
|
||||
<delete dir="apidocs" failonerror="no"/>
|
||||
<ant inheritAll="false" antfile="src/native/build.xml" target="clean"/>
|
||||
</target>
|
||||
</project>
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue