| Summary: | Bundle-NativeCode can't work on Windows Server 2008/Windows 7 | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] Equinox | Reporter: | Meng Xin Zhu <zhumx> | ||||||
| Component: | Framework | Assignee: | Thomas Watson <tjwatson> | ||||||
| Status: | RESOLVED FIXED | QA Contact: | |||||||
| Severity: | normal | ||||||||
| Priority: | P3 | CC: | haoxy, hargrave, kane.mx, raji, roba, swtnov, tjwatson | ||||||
| Version: | 3.4.2 | Flags: | hargrave:
review+
|
||||||
| Target Milestone: | 3.5.1 | ||||||||
| Hardware: | PC | ||||||||
| OS: | Windows 7 | ||||||||
| Whiteboard: | |||||||||
| Attachments: |
|
||||||||
|
Description
Meng Xin Zhu
(In reply to comment #0) > Why not Equinox simply match all OS to alias 'win32' whose name starts with > 'Windows' What about Windows CE then? It seems a very bad idea to assume that all OS names which start with Windows are win32 api compatible. (In reply to comment #1) > What about Windows CE then? It seems a very bad idea to assume that all OS > names which start with Windows are win32 api compatible. > I agree with BJ. On Windows Server 2008/Windows 7 can you tell us what the os.name java property is? Can you start Eclipse in Windows 7? If so then open the about dialog and get the configuration information. On 3.5 you can bring this up by going to Help > About Eclipse SDK and clicking the "Installation Detais" and going to the "Configuration" tab. We currently have the os.name aliases hard coded in the framework. We should consider an option to pass in an external alias table to allow new OS'es to be configured in. As a work around you can specify multiple osname attributes on your Bundle-NativeCode clause to include "Windows 7" (depending on what the os.name system property is). We should consider updating the built in os name alias table for 3.5.1. (In reply to comment #2) > (In reply to comment #1) > > What about Windows CE then? It seems a very bad idea to assume that all OS > > names which start with Windows are win32 api compatible. > > > > I agree with BJ. On Windows Server 2008/Windows 7 can you tell us what the > os.name java property is? Can you start Eclipse in Windows 7? If so then open > the about dialog and get the configuration information. On 3.5 you can bring > this up by going to Help > About Eclipse SDK and clicking the "Installation > Detais" and going to the "Configuration" tab. > I just tried to get the os.name java property on Windows Server 2008. The value of os.name java property is 'Windows Server 2008'. > We currently have the os.name aliases hard coded in the framework. We should > consider an option to pass in an external alias table to allow new OS'es to be > configured in. > > As a work around you can specify multiple osname attributes on your > Bundle-NativeCode clause to include "Windows 7" (depending on what the os.name > system property is). > Do you mean that I can use below way as a work around without adding 'Windows Server 2008' into osname.aliases file, Bundle-NativeCode: /lib/win32/officebean.dll; osname=win32; processor=x86, /lib/win32/officebean.dll; osname=Windows Server 2008; processor=x86, * (In reply to comment #4) > Do you mean that I can use below way as a work around without adding 'Windows > Server 2008' into osname.aliases file, > Bundle-NativeCode: /lib/win32/officebean.dll; osname=win32; processor=x86, > /lib/win32/officebean.dll; osname=Windows Server 2008; > processor=x86, * > You should quote the value with spaces. You can also specify the osname multiple times for the same native code element: Bundle-NativeCode: /lib/win32/officebean.dll; osname=win32; osname="Windows Server 2008"; processor=x86, * This means the path /lib/win32/officebean.dll can work on win32 and Windows Server 2008 OS's. (In reply to comment #5) > You should quote the value with spaces. You can also specify the osname > multiple times for the same native code element: > > Bundle-NativeCode: /lib/win32/officebean.dll; > osname=win32; > osname="Windows Server 2008"; > processor=x86, > * > > This means the path /lib/win32/officebean.dll can work on win32 and Windows > Server 2008 OS's. > Got it. BTW: It seems that quoting the value with spaces is not necessary. The library is successfully load by defining like below, Bundle-NativeCode: /lib/win32/officebean.dll; osname=win32; osname=windows server 2008; processor=x86, * (In reply to comment #6) > Got it. > BTW: It seems that quoting the value with spaces is not necessary. The library > is successfully load by defining like below, > Bundle-NativeCode: /lib/win32/officebean.dll; > osname=win32; > osname=windows server 2008; > processor=x86, > * > The Equinox manifest parser is a bit forgiving when it comes to strict header syntax. But according to the specification attribute values containing quotes should be quoted. (In reply to comment #7) > But according to the specification attribute values containing quotes > should be quoted. > I meant to type: But according to the specification attribute values containing SPACES should be quoted. Meng, what build of Windows 7 did you use? What VM and version did you use. I am in the process of getting a machine setup with Windows7. I somehow doubt the os.name will remain Windows Server 2008 for the final release of Windows 7. I am thinking we will need an alias list like this for Windows7: Windows7 "Windows Server 2008" "Windows 7" Win32 (In reply to comment #9) > Meng, what build of Windows 7 did you use? What VM and version did you use. I > am in the process of getting a machine setup with Windows7. I somehow doubt > the os.name will remain Windows Server 2008 for the final release of Windows 7. > I am thinking we will need an alias list like this for Windows7: I never have Windows 7. I just guessed there is same problem on Windows 7 via reading the source code(osname.alias). > Windows7 "Windows Server 2008" "Windows 7" Win32 I tried to search the os.name of Windows 7 in google, the value seems to be "Windows 7". It should not remain using "Windows Server 2008" as its name. Created attachment 143081 [details]
osname alias patch
We need to support both Windows Server 2008 and Windows 7. Here is a patch that adds aliases for both.
I released the patch to HEAD. Still need to do some testing on Windows 7 and Windows Server 2008. I just tried this on Windows 7: - IBM 1.6 VM and the VM reports os.name as "Windows Vista". - Sun 1.6.0 update 14 reports os.name as "Windows 7" I think the IBM VM currently has a bug reporting os.name as Windows Vista. BJ can you review the new aliases for 3.5.1. Note that I already opened an OSGi bug to get these aliases added to the spec reference page. I did note there is no "Win7" short alias like the other Windows variants. (In reply to comment #15) > I did note there is no "Win7" short alias like the other Windows variants. > I had noticed this before and fixed in in HEAD already, I forgot to attach a new patch here. I released the new osname.aliases with "Win7" included to 3.5.1. Created attachment 185748 [details]
11
This is still an issue with Windows Server 2008 R2. The jave os.name returns "Windows Server 2008 R2" on and R2 system. The osname.aliases file needs to have the following line added to it Windows2008R2 "Windows 2008 R2" "Windows Server 2008 R2" Win2008R2 Win32 # Microsoft Can someone reopen this bug or should a new bug be created? please open a new bug. Hi Thomas, I had same issue with Windows Server 2008 R2. I am kind of in urgent to solve this issue. Is there a workaround before this bug is opened and fixed? Thanks, Rocky (In reply to comment #19) > please open a new bug. Rocky, There is a workaround: just add osname="windows server 2008 r2"; after osname=win32; in your Bundle-NativeCode entry. New bug opened for the R2 problem: https://bugs.eclipse.org/bugs/show_bug.cgi?id=335191 |