[FELIX-1969] include Windows 7 and 2003 in OS name handling
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@896891 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/framework/src/main/java/org/apache/felix/framework/util/manifestparser/R4LibraryClause.java b/framework/src/main/java/org/apache/felix/framework/util/manifestparser/R4LibraryClause.java
index 1457979..3aec1f5 100644
--- a/framework/src/main/java/org/apache/felix/framework/util/manifestparser/R4LibraryClause.java
+++ b/framework/src/main/java/org/apache/felix/framework/util/manifestparser/R4LibraryClause.java
@@ -136,12 +136,14 @@
{
boolean win32 = currentOSName.startsWith("win") &&
(currentOSName.equals("windows95") ||
- currentOSName.equals("windows98") ||
- currentOSName.equals("windowsnt") ||
- currentOSName.equals("windows2000") ||
- currentOSName.equals("windowsxp") ||
- currentOSName.equals("windowsce") ||
- currentOSName.equals("windowsvista"));
+ currentOSName.equals("windows98") ||
+ currentOSName.equals("windowsnt") ||
+ currentOSName.equals("windows2000") ||
+ currentOSName.equals("windows2003") ||
+ currentOSName.equals("windowsxp") ||
+ currentOSName.equals("windowsce") ||
+ currentOSName.equals("windowsvista") ||
+ currentOSName.equals("windows7"));
for (int i = 0; (osnames != null) && (i < osnames.length); i++)
{
@@ -372,6 +374,10 @@
{
os = "windows2000";
}
+ else if (value.indexOf("2003") >= 0)
+ {
+ os = "windows2003";
+ }
else if (value.indexOf("xp") >= 0)
{
os = "windowsxp";
@@ -384,6 +390,11 @@
{
os = "windowsvista";
}
+ // will need better test here if any future Windows version has a 7 in it!
+ else if (value.indexOf("7") >= 0)
+ {
+ os = "windows7";
+ }
return os;
}
else if (value.startsWith("linux"))