Closed Bug 744566 Opened 13 years ago Closed 12 years ago

Generate our own PRI files as part of the build process

Categories

(Core :: Widget: Win32, defect)

x86_64
Windows 8.1
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: bbondy, Assigned: bbondy)

References

Details

(Whiteboard: completed-elm)

Attachments

(1 file, 1 obsolete file)

We should generate our own PRI files as part of the build process. There isn't much info other than the tool's command line output, but here are some basic commands: To see what's in a generated PRI: "C:\Program Files\Windows Kits\8.0\bin\x64\makepri.exe" dump /if c:\Users\Brian\Desktop\resources.pri /of C:\users\brian\Desktop\resources.pri.xml To create a new config file: "C:\Program Files\Windows Kits\8.0\bin\x64\makepri.exe" createconfig /cf C:\users\brian\desktop\priconfig.xml /dq en-US /o To create a PRI file: "C:\Program Files\Windows Kits\8.0\bin\x64\makepri.exe" new /pr C:\users\brian\desktop\projectroot /cf C:\users\brian\desktop\priconfig.xml /mn c:\users\brian\desktop\AppManifest.xml /of c:\users\brian\desktop\resources.pri /o
This needs to be incorporated into the build process still but we have PRI files figured out and working now. Attached is an example PRI file and the needed config files to generate it.
Documentation and details on PRI file generation from Microsoft would still be helpful to have, but it is neither urgent nor required anymore.
Attached patch Patch v1.Splinter Review
- Removed IE PRI file. - Generate our own PRI file as part of the build process.
Attachment #614804 - Attachment is obsolete: true
I'm seeing an error while building in mobile/xul - makepri.exe new /pr /T/Mozilla/elm/mobile/xul/metro/tileresources /cf /T/Mozilla/elm/mobile/xul/metro/priconfig.xml /mn /T/Mozilla/elm/mobile/xul/metro/AppManifest.xml /of ../../../dist/bin/resources.pri /o Microsoft (R) MakePRI Tool version 6.2.8229.0 Copyright (C) 2012 Microsoft. All rights reserved. MakePri: error 0x80070057: Unknown option specified - 'C:/mozilla-build/msys/pr' I don't see where it's getting this from though.
I can build fine, maybe it's related to an env variable or something?
(In reply to Brian R. Bondy [:bbondy] from comment #5) > I can build fine, maybe it's related to an env variable or something? I can reproduce it, but only when building from within obj/mobile/mobile/xul. Probably not a big deal since we'll be moving this all around soon.
> I can reproduce it, but only when building from within obj/mobile/mobile/xul. You mean obj/mobile/xul right? I tried building from within obj/mobile/xul and also in obj/mobile/xul/metro and it works for me.
Hmm, still not getting this to work. make succeeds but the actual call to makepri fails. A couple things I've figured out in moving this down to browser - the /opt command params get expanded out in weird ways when run through the shell. for example: makepri new /pr /F/Mozilla/firefox/elm/browser/metro/shell/tileresources /cf /F/Mozilla/firefox/elm/browser/metro/shell/priconfig.xml /mn /F/Mozilla/firefox/elm/browser/metro/shell/AppManifest.xml /of ../../../dist/bin/resources.pri /o results in: Microsoft (R) MakePRI Tool version 6.2.8229.0 Copyright (C) 2012 Microsoft. All rights reserved. MakePri: error 0x80070057: Unknown option specified - 'F:/mozilla-build/msys/pr' but if you switch the /opt for -opt, things get picked up properly - makepri new -v -pr /F/Mozilla/firefox/elm/browser/metro/shell/tileresources -cf /F/Mozilla/firefox/elm/browser/metro/shell/priconfig.xml -mn /F/Mozilla/firefox/elm/browser/metro/shell/AppManifest.xml -of ../../../dist/bin/resources.pri -o Option Verbose specified Option ProjectRoot specified Option Configxml specified Option Manifest specified Option OutputFile specified Option Overwrite specified Microsoft (R) MakePRI Tool version 6.2.8229.0 Copyright (C) 2012 Microsoft. All rights reserved. MakePri: error 0x80040154: AppXPackaging.dll cannot be found. 'The manifest cannot be read on this machine. Please specify a /in parameter' Unfortunately this still doesn't succeed. I had to add an '-in somestring' param to get it to finish. Although I'm doubtful this will actually work when I get it running. Side note - we were checking for makepri but I missed an export which I just landed. So now instead of hardcoding the makepri.exe in the makefile, we can use $(MAKEPRI) - $(RM) $(DIST)/bin/resources.pri $(MAKEPRI) new -v -in metrofirefox -pr $(srcdir)/tileresources -cf $(srcdir)/priconfig.xml -mn $(srcdir)/AppManifest.xml -of $(DIST)/bin/resources.pri -o this resulted in: rm -f ../../../dist/bin/resources.pri makepri new -v -in metrofirefox -pr /F/Mozilla/firefox/elm/browser/metro/shell/tileresources -cf /F/Mozilla/firefox/elm/browser/metro/shell/priconfig.xml -mn /F/Mozilla/firefox/elm/browser/metro/shell/AppManifest.xml -of ../. ./../dist/bin/resources.pri -o Option Verbose specified Option IndexName specified Option ProjectRoot specified Option Configxml specified Option Manifest specified Option OutputFile specified Option Overwrite specified Index Pass Completed: layout.resfiles Scale Qualifiers: 100, 140, 180, 80 Contrast Qualifiers: BLACK, WHITE Index Pass Completed: resources.resfiles Scale Qualifiers: 100, 140, 180, 80 Contrast Qualifiers: BLACK, WHITE Index Pass Completed: pri.resfiles Scale Qualifiers: 100, 140, 180, 80 Contrast Qualifiers: BLACK, WHITE Finished building Version: 1.0 Resource Map Name: metrofirefox Named Resources: 8 Resource Candidates: 48 Output File at ../../../dist/bin/resources.pri Successfully Completed
Hmm, so AFAICT, the problem is this dll - MakePri: error 0x80040154: AppXPackaging.dll cannot be found. 'The manifest cannot be read on this machine. Please specify a /in parameter' which only seems to be available on win8 in the system32 dir. Looks like we might have to generate the pri locally and check the result into the repo.
Could we distribute it as part of mozilla-build?
(In reply to Brian R. Bondy [:bbondy] from comment #10) > Could we distribute it as part of mozilla-build? Don't think so since it appears to be part of the os. Plus according to depends it has a number of missing imports on win7.
I'm wondering how you can build with VS2010 and the Windows 8 SDK in that case in general for WRL apps on Windows 7.
I guess we'll see that in a separate bug, ya I guess we'll have to commit the pri directly :(
Whiteboard: completed-elm
elm -> m-c
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
OS: Windows 8 Metro → Windows 8.1
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: