You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by mt...@apache.org on 2011/04/15 10:29:43 UTC
svn commit: r1092626 - in /commons/sandbox/runtime/trunk/src/main:
java/org/apache/commons/runtime/
java/org/apache/commons/runtime/platform/unix/ native/include/acr/
native/os/unix/
Author: mturk
Date: Fri Apr 15 08:29:43 2011
New Revision: 1092626
URL: http://svn.apache.org/viewvc?rev=1092626&view=rev
Log:
Just like with windows move a PosixNN to a separate package
Added:
commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/
commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Default.properties (with props)
commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Posix.java
- copied, changed from r1092592, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/Posix.java
commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphore.java
- copied, changed from r1092439, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphore.java
commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphoreImpl.java
- copied, changed from r1092439, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphoreImpl.java
commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphoreImplFactory.java
- copied, changed from r1092439, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphoreImplFactory.java
Removed:
commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/Posix.java
commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphore.java
commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphoreImpl.java
commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphoreImplFactory.java
Modified:
commons/sandbox/runtime/trunk/src/main/native/include/acr/jnidefs.h
commons/sandbox/runtime/trunk/src/main/native/os/unix/semaphore.c
Added: commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Default.properties
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Default.properties?rev=1092626&view=auto
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Default.properties (added)
+++ commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Default.properties Fri Apr 15 08:29:43 2011
@@ -0,0 +1,23 @@
+# -----------------------------------------------------------------------------
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+# -----------------------------------------------------------------------------
+# DefaultProperties.properties
+#
+# OS Apache Commons Runtime properties file.
+# Those properties override main DefaultProperties
+#
+# -----------------------------------------------------------------------------
Propchange: commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Default.properties
------------------------------------------------------------------------------
svn:eol-style = native
Copied: commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Posix.java (from r1092592, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/Posix.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Posix.java?p2=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Posix.java&p1=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/Posix.java&r1=1092592&r2=1092626&rev=1092626&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/Posix.java (original)
+++ commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/Posix.java Fri Apr 15 08:29:43 2011
@@ -13,8 +13,9 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.apache.commons.runtime;
+package org.apache.commons.runtime.platform.unix;
+import org.apache.commons.runtime.Status;
import org.apache.commons.runtime.exception.AlreadyExistsException;
import org.apache.commons.runtime.exception.NoSuchObjectException;
import org.apache.commons.runtime.exception.ClosedDescriptorException;
Copied: commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphore.java (from r1092439, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphore.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphore.java?p2=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphore.java&p1=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphore.java&r1=1092439&r2=1092626&rev=1092626&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphore.java (original)
+++ commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphore.java Fri Apr 15 08:29:43 2011
@@ -13,8 +13,11 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.apache.commons.runtime;
+package org.apache.commons.runtime.platform.unix;
+import org.apache.commons.runtime.Semaphore;
+import org.apache.commons.runtime.SemaphoreImpl;
+import org.apache.commons.runtime.Status;
import org.apache.commons.runtime.exception.AlreadyExistsException;
import org.apache.commons.runtime.exception.NoSuchObjectException;
import org.apache.commons.runtime.exception.ClosedDescriptorException;
Copied: commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphoreImpl.java (from r1092439, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphoreImpl.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphoreImpl.java?p2=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphoreImpl.java&p1=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphoreImpl.java&r1=1092439&r2=1092626&rev=1092626&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphoreImpl.java (original)
+++ commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphoreImpl.java Fri Apr 15 08:29:43 2011
@@ -13,8 +13,10 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.apache.commons.runtime;
+package org.apache.commons.runtime.platform.unix;
+import org.apache.commons.runtime.Semaphore;
+import org.apache.commons.runtime.SemaphoreImpl;
import org.apache.commons.runtime.exception.AlreadyExistsException;
import org.apache.commons.runtime.exception.NoSuchObjectException;
import org.apache.commons.runtime.exception.SystemException;
Copied: commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphoreImplFactory.java (from r1092439, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphoreImplFactory.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphoreImplFactory.java?p2=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphoreImplFactory.java&p1=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphoreImplFactory.java&r1=1092439&r2=1092626&rev=1092626&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/PosixSemaphoreImplFactory.java (original)
+++ commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/platform/unix/PosixSemaphoreImplFactory.java Fri Apr 15 08:29:43 2011
@@ -13,9 +13,10 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.apache.commons.runtime;
+package org.apache.commons.runtime.platform.unix;
-import java.io.IOException;
+import org.apache.commons.runtime.SemaphoreImpl;
+import org.apache.commons.runtime.SemaphoreImplFactory;
/**
* PosixSemaphoreImplFactory class.
Modified: commons/sandbox/runtime/trunk/src/main/native/include/acr/jnidefs.h
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/include/acr/jnidefs.h?rev=1092626&r1=1092625&r2=1092626&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/native/include/acr/jnidefs.h (original)
+++ commons/sandbox/runtime/trunk/src/main/native/include/acr/jnidefs.h Fri Apr 15 08:29:43 2011
@@ -29,6 +29,7 @@
#define ACR_IO_CP ACR_CLASS_PATH "io/"
#define ACR_NET_CP ACR_CLASS_PATH "net/"
#define ACR_UTIL_CP ACR_CLASS_PATH "util/"
+#define ACR_UNX_CP ACR_CLASS_PATH "platform/unix/"
#define ACR_WIN_CP ACR_CLASS_PATH "platform/windows/"
#define ACR_JNI_EXPORT(RT, CL, MN) \
@@ -37,6 +38,8 @@
ACR_JNIEXPORT RT JNICALL Java_org_apache_commons_runtime_##CP##_##CL##_##MN
#define ACR_OS_EXPORT(RT, CP, CL, MN) \
ACR_JNIEXPORT RT JNICALL Java_org_apache_commons_runtime_platform_##CP##_##CL##_##MN
+#define ACR_UNX_EXPORT(RT, CL, MN) \
+ ACR_JNIEXPORT RT JNICALL Java_org_apache_commons_runtime_platform_unix_##CL##_##MN
#define ACR_WIN_EXPORT(RT, CL, MN) \
ACR_JNIEXPORT RT JNICALL Java_org_apache_commons_runtime_platform_windows_##CL##_##MN
#define ACR_IO_EXPORT(RT, CL, MN) \
Modified: commons/sandbox/runtime/trunk/src/main/native/os/unix/semaphore.c
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/os/unix/semaphore.c?rev=1092626&r1=1092625&r2=1092626&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/native/os/unix/semaphore.c (original)
+++ commons/sandbox/runtime/trunk/src/main/native/os/unix/semaphore.c Fri Apr 15 08:29:43 2011
@@ -38,7 +38,7 @@ J_DECLARE_CLAZZ = {
0,
0,
0,
- ACR_CLASS_PATH "PosixSemaphoreImplFactory"
+ ACR_UNX_CP "PosixSemaphoreImplFactory"
};
J_DECLARE_M_ID(0000) = {
@@ -87,7 +87,7 @@ ACR_JNI_EXPORT(jboolean, Semaphore, unli
return rc;
}
-ACR_JNI_EXPORT(jint, PosixSemaphore, unlink0)(JNI_STDARGS, jstring name)
+ACR_UNX_EXPORT(jint, PosixSemaphore, unlink0)(JNI_STDARGS, jstring name)
{
int rc = 0;
WITH_CSTR(name) {
@@ -97,7 +97,7 @@ ACR_JNI_EXPORT(jint, PosixSemaphore, unl
return rc;
}
-ACR_JNI_EXPORT(jlong, PosixSemaphore, create0)(JNI_STDARGS,
+ACR_UNX_EXPORT(jlong, PosixSemaphore, create0)(JNI_STDARGS,
jstring name, jint value)
{
sem_t *sp = 0;
@@ -123,7 +123,7 @@ ACR_JNI_EXPORT(jlong, PosixSemaphore, cr
return P2J(sp);
}
-ACR_JNI_EXPORT(jlong, PosixSemaphore, open0)(JNI_STDARGS,
+ACR_UNX_EXPORT(jlong, PosixSemaphore, open0)(JNI_STDARGS,
jstring name)
{
sem_t *sp = 0;
@@ -149,7 +149,7 @@ ACR_JNI_EXPORT(jlong, PosixSemaphore, op
return P2J(sp);
}
-ACR_JNI_EXPORT(jint, PosixSemaphore, close0)(JNI_STDARGS, jlong sem)
+ACR_UNX_EXPORT(jint, PosixSemaphore, close0)(JNI_STDARGS, jlong sem)
{
sem_t *sp = J2P(sem, sem_t *);
@@ -159,7 +159,7 @@ ACR_JNI_EXPORT(jint, PosixSemaphore, clo
return 0;
}
-ACR_JNI_EXPORT(jint, PosixSemaphore, wait0)(JNI_STDARGS, jlong sem)
+ACR_UNX_EXPORT(jint, PosixSemaphore, wait0)(JNI_STDARGS, jlong sem)
{
int rc;
sem_t *sp = J2P(sem, sem_t *);
@@ -173,7 +173,7 @@ ACR_JNI_EXPORT(jint, PosixSemaphore, wai
return 0;
}
-ACR_JNI_EXPORT(jint, PosixSemaphore, try0)(JNI_STDARGS, jlong sem)
+ACR_UNX_EXPORT(jint, PosixSemaphore, try0)(JNI_STDARGS, jlong sem)
{
int rc;
sem_t *sp = J2P(sem, sem_t *);
@@ -190,7 +190,7 @@ ACR_JNI_EXPORT(jint, PosixSemaphore, try
return 0;
}
-ACR_JNI_EXPORT(jint, PosixSemaphore, release0)(JNI_STDARGS, jlong sem)
+ACR_UNX_EXPORT(jint, PosixSemaphore, release0)(JNI_STDARGS, jlong sem)
{
int rc;
sem_t *sp = J2P(sem, sem_t *);