[jira] [Commented] (FELIX-5574) When detecting an unknow Windows OS name, provides a suitable default value for org.osgi.framework.os.name

2017-04-27 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/FELIX-5574?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15986573#comment-15986573
 ] 

ASF GitHub Bot commented on FELIX-5574:
---

Github user asfgit closed the pull request at:

https://github.com/apache/felix/pull/95


> When detecting an unknow Windows OS name, provides a suitable default value 
> for org.osgi.framework.os.name
> --
>
> Key: FELIX-5574
> URL: https://issues.apache.org/jira/browse/FELIX-5574
> Project: Felix
>  Issue Type: Improvement
>  Components: Framework
>Reporter: Xavier Fournet
>Assignee: Karl Pauls
>Priority: Minor
> Fix For: framework-5.6.4
>
>
> When the system property os.name return a Windows OS name that is not 
> recognized by 
> org.apache.felix.framework.util.manifestparser.NativeLibraryClause#normalizeOSName
>  then it return "win" as a fallback value.
> However this "win" value is not something valid for the 
> org.osgi.framework.os.name property name (cf 
> https://www.osgi.org/developer/specifications/reference/)
> Changing the fallback value to "win32" would be better so it would allow most 
> of the JNI library to be loaded.
> This would allow smooth support of future windows platform, for example for 
> Windows Server 2016 with JDK9 (or JDK8 when 
> https://bugs.openjdk.java.net/browse/JDK-8159948 will be fix on it)



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (FELIX-5574) When detecting an unknow Windows OS name, provides a suitable default value for org.osgi.framework.os.name

2017-04-21 Thread Xavier Fournet (JIRA)

[ 
https://issues.apache.org/jira/browse/FELIX-5574?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15978876#comment-15978876
 ] 

Xavier Fournet commented on FELIX-5574:
---

As expected, the latest JDK8 version now recognize correctly Windows Server 
2016 leading Felix to fall again this trap.

Repro case on Windows Server 2016 + Felix 5.6.2

With JDK 1.8.0_121 it's working correctly
{noformat}
C:\work\felix-framework-5.6.2>..\jdk-1.8.0_121\bin\java.exe -version
java version "1.8.0_121"
Java(TM) SE Runtime Environment (build 1.8.0_121-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.121-b13, mixed mode)

C:\work\felix-framework-5.6.2>..\jdk-1.8.0_121\bin\java.exe -jar bin\felix.jar

Welcome to Apache Felix Gogo

g! context:getProperty os.name
Windows NT (unknown)

g! context:getProperty org.osgi.framework.os.name
windowsnt

g! install 
http://central.maven.org/maven2/org/xerial/snappy/snappy-java/1.1.2.6/snappy-java-1.1.2.6.jar
Bundle ID: 7

g! start 7

g! lb
START LEVEL 1
   ID|State  |Level|Name
0|Active |0|System Bundle (5.6.2)|5.6.2
1|Active |1|jansi (1.14.0)|1.14.0
2|Active |1|JLine (3.0.1)|3.0.1
3|Active |1|Apache Felix Bundle Repository (2.0.8)|2.0.8
4|Active |1|Apache Felix Gogo Command (1.0.2)|1.0.2
5|Active |1|Apache Felix Gogo JLine Shell (1.0.2)|1.0.2
6|Active |1|Apache Felix Gogo Runtime (1.0.2)|1.0.2
7|Active |1|snappy-java: A fast compression/decompression library 
(1.1.2.6)|1.1.2.6
{noformat}



With JDK 1.8.0_131 it's fail to install the snappy bundle because of the 
invalid value (win) for org.osgi.framework.os.name property
{noformat}
C:\work\felix-framework-5.6.2>..\jdk-1.8.0_131\bin\java.exe -version
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)

C:\work\felix-framework-5.6.2>..\jdk-1.8.0_131\bin\java.exe -jar bin\felix.jar

Welcome to Apache Felix Gogo

g! context:getProperty os.name
Windows Server 2016

g! context:getProperty org.osgi.framework.os.name
win

g! install 
http://central.maven.org/maven2/org/xerial/snappy/snappy-java/1.1.2.6/snappy-java-1.1.2.6.jar
Bundle ID: 7

g! start 7
org.osgi.framework.BundleException: Unable to resolve 
org.xerial.snappy.snappy-java [7](R 7.0): missing requirement 
[org.xerial.snappy.snappy-java [7](R 7.0)] osgi.native; 
(|(&(osgi.native.osname~=win32)(osgi.native.processor~=x86-64))(&(osgi.native.osname~=win32)(osgi.native.processor~=x64))(&(osgi.native.osname~=win32)(osgi.native.processor~=amd64))(&(osgi.native.osname~=win32)(osgi.native.processor~=x86))(&(osgi.native.osname~=macosx)(osgi.native.processor~=x86))(&(osgi.native.osname~=macosx)(osgi.native.processor~=x86-64))(&(osgi.native.osname~=linux)(osgi.native.processor~=x86-64))(&(osgi.native.osname~=linux)(osgi.native.processor~=x64))(&(osgi.native.osname~=linux)(osgi.native.processor~=amd64))(&(osgi.native.osname~=linux)(osgi.native.processor~=x86))(&(osgi.native.osname~=linux)(osgi.native.processor~=aarch64))(&(osgi.native.osname~=linux)(osgi.native.processor~=arm))(&(osgi.native.osname~=linux)(osgi.native.processor~=ppc64))(&(osgi.native.osname~=linux)(osgi.native.processor~=ppc64le))(&(osgi.native.osname~=linux)(osgi.native.processor~=s390x))(&(osgi.native.osname~=aix)(osgi.native.processor~=ppc))(&(osgi.native.osname~=aix)(osgi.native.processor~=ppc64))(&(osgi.native.osname~=sunos)(osgi.native.processor~=x86))(&(osgi.native.osname~=sunos)(osgi.native.processor~=x86-64))(&(osgi.native.osname~=sunos)(osgi.native.processor~=sparc)))
 Unresolved requirements: [[org.xerial.snappy.snappy-java [7](R 7.0)] 
osgi.native; 

[jira] [Commented] (FELIX-5574) When detecting an unknow Windows OS name, provides a suitable default value for org.osgi.framework.os.name

2017-03-01 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/FELIX-5574?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15890403#comment-15890403
 ] 

ASF GitHub Bot commented on FELIX-5574:
---

GitHub user xfournet opened a pull request:

https://github.com/apache/felix/pull/95

FELIX-5574 change Windows default os name from win to win32



You can merge this pull request into a Git repository by running:

$ git pull https://github.com/xfournet/felix FELIX-5574

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/felix/pull/95.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #95


commit fe9bfcbdb7c01980a2949051b67d412f0ce4fb6a
Author: xfournet 
Date:   2017-03-01T15:37:36Z

FELIX-5574 Windows default os name from win to win32




> When detecting an unknow Windows OS name, provides a suitable default value 
> for org.osgi.framework.os.name
> --
>
> Key: FELIX-5574
> URL: https://issues.apache.org/jira/browse/FELIX-5574
> Project: Felix
>  Issue Type: Improvement
>  Components: Framework
>Reporter: Xavier Fournet
>Priority: Minor
> Fix For: framework-5.6.4
>
>
> When the system property os.name return a Windows OS name that is not 
> recognized by 
> org.apache.felix.framework.util.manifestparser.NativeLibraryClause#normalizeOSName
>  then it return "win" as a fallback value.
> However this "win" value is not something valid for the 
> org.osgi.framework.os.name property name (cf 
> https://www.osgi.org/developer/specifications/reference/)
> Changing the fallback value to "win32" would be better so it would allow most 
> of the JNI library to be loaded.
> This would allow smooth support of future windows platform, for example for 
> Windows Server 2016 with JDK9 (or JDK8 when 
> https://bugs.openjdk.java.net/browse/JDK-8159948 will be fix on it)



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)