Problem when building with VC++2005 Express Edition

VERIFIED FIXED

Status

mozilla.org
MozillaBuild
--
major
VERIFIED FIXED
9 years ago
9 years ago

People

(Reporter: Masahiro YAMADA, Assigned: Masahiro YAMADA)

Tracking

Details

Attachments

(3 attachments, 6 obsolete attachments)

(Assignee)

Description

9 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; ja; rv:1.8.1.13) Gecko/20080311 Firefox/2.0.0.13
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; ja; rv:1.8.1.13) Gecko/20080311 Firefox/2.0.0.13

Now, Firefox Trunk uses Parental Controll API, it requires Windwos Vista SDK.
But, it does NOT contains ATL header files.
And, VC++ 2005 Express edition does not contains ATL header files too.
It causes to fail to build Fx Trunk ("atlbase.h" not found).


Reproducible: Always

Steps to Reproduce:
1.Install VC++2005 Express Edition
2.Install Windows Vista SDK.
3.Install MozillaBuild 1.2 package
4.Get sourece files
5.Configure and build.

Actual Results:  
It always fails with "atlbase.h" not found.

Expected Results:  
Build succeeded.

ATL header files is only included with:
1. VC++ 2005 other than Express Edition
2. Platform SDKs (e.g. Windows 2003 Server R2 Platform SDK)
... Windows SDKs (Windows Vista SDK, Windows 2008 Server SDK)
    does not contain ATL header files

It means , To build Fx trunk with VC++2005 Express Edtion,
1.Install VC++2005 Express Edition
2.Install Windows Vista SDK.
3.Additionally, install Windows 2003 Server R2 Platform SDK .
4.Install MozillaBuild 1.2 package
5.Get sourece files
6.Configure
7.Modify batch files
8.Build Fx Trunk.

I'll attach my fixed batch files.
(Assignee)

Comment 1

9 years ago
Created attachment 314344 [details]
Fixed guess-msvc.bat
(Assignee)

Comment 2

9 years ago
Created attachment 314345 [details]
fixed start-msvc8.bat
(Assignee)

Comment 3

9 years ago
Comment on attachment 314345 [details]
fixed start-msvc8.bat

This batchfiles Adds Platform SDK's ATL header file path to INCLUDE environment variable when using VC++ExpressEdition and WIndows VIsta SDK.
Component: Build Config → MozillaBuild
Product: Firefox → mozilla.org
QA Contact: build.config → mozillabuild
Version: unspecified → other
Attachment #314344 - Attachment mime type: application/octet-stream → text/plain
(Assignee)

Comment 4

9 years ago
I think, it is needed to fix MDC documantation too.
  http://developer.mozilla.org/en/docs/Windows_Build_Prerequisites
I filed it as Bug 427968 .
(Assignee)

Comment 5

9 years ago
According to Bug 427968 Comment #1, there is a same problem on oleacc.idl .
 (It is contained in only Platfrom SDK, not in VC++ Express and Windows Vista SDK).
(Assignee)

Comment 6

9 years ago
Created attachment 315110 [details]
new Fixed start-msvc8.bat

Oleacc.idl and midl.exe are also not contained in VC++ 2005 Express Edition and Windows Vista SDK.
Oleacc.idl : Exists in Platfrom SDK's "Include" folder.
Midl.exe   : Exists in Platfrom SDK's "Bin" folder.
Attachment #314345 - Attachment is obsolete: true
(Assignee)

Comment 7

9 years ago
Created attachment 315121 [details]
Fixed start-msvc8.bat Rev.2.1

Sorry, attachment 315110 [details] contains my private settings.
Attachment #315110 - Attachment is obsolete: true
(Assignee)

Comment 8

9 years ago
Sorry, Midl.exe is not missing in Windows Vista SDK,
 only I did not install "Win32 Development Tools".

And I found a problem around midl.exe.

Unknwn.idl in Windows Vista SDK is not compatible with midl.exe of Platform SDK for Windows Server 2003 R2.

>E:\Microsoft SDKs\Windows\v6.0\include\unknwn.idl(108) : error MIDL2025 : syntax error : expecting ] or , near "annotation"

(Assignee)

Updated

9 years ago
Attachment #314344 - Flags: review?
(Assignee)

Comment 9

9 years ago
Created attachment 315228 [details]
Fixed start-msvc8.bat Rev.2.2

I can build Fx Trunk with CVS source and follwoing configuration.

mk_add_options MOZ_CO_PROJECT=browser
ac_add_options --enable-application=browser
mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/ff-opt-static
ac_add_options --enable-optimize
ac_add_options --disable-debug
ac_add_options --enable-static
ac_add_options --disable-shared
ac_add_options --disable-libxul
ac_add_options --disable-tests
ac_add_options --disable-installer
Attachment #315121 - Attachment is obsolete: true
Attachment #315228 - Flags: review?
(Assignee)

Updated

9 years ago
Attachment #315228 - Attachment mime type: application/octet-stream → text/plain
(Assignee)

Updated

9 years ago
Keywords: dev-doc-needed
Status: UNCONFIRMED → NEW
Ever confirmed: true
Hm, I re-installed the W2K3R2 SDK and tried attachment 315228 [details] and still got errors at IA2CommonTypes.idl with an error of nsinstall: Accessible2.h: No such file or directory

Looking deeper, I found that it wasn't setting the right includes, and it hadn't referenced the PSDK. So I'm not sure that modified build file is right :(
(Assignee)

Comment 11

9 years ago
(In reply to comment #10)
Attachment 315228 [details] requires attachment 314344 [details].
Attachment 314344 [details] detects PSDK and sets its information to PSDKDIR and PSDKVER even if Windows Vista SDK is found.
Oh, I see. My mistake!

I can confirm that these new batch files work perfectly. After running them, I get:

$ set | grep include
INCLUDE='C:\Program Files\Microsoft SDKs\Windows\v6.0\\include;C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\\include\atl;C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\\include;C:\Program Files\Microsoft Visual Studio 8\VC\INCLUDE;'

And as a result, builds work, even with a totally basic .mozconfig

I have updated the MDC page on software requirements to refer to this bug, as well as the revised batch files. This should allow people to continue using the free software chain for building Mozilla on windows until we have MozillaBuild updated:

http://developer.mozilla.org/en/docs/Windows_Build_Prerequisites
Keywords: dev-doc-needed
Note that I've also filed bug 428657 and bug 428660 about using depricated headers (which is part of the cause of this problem). Are those the only ones getting us in trouble?
Attachment #315228 - Flags: review? → review?(bhearsum)
Attachment #314344 - Flags: review? → review?(bhearsum)
Attachment #315228 - Flags: review?(bhearsum) → review?(ted.mielczarek)
Attachment #314344 - Flags: review?(bhearsum) → review?(ted.mielczarek)
Masahiro: these files are in CVS here: http://lxr.mozilla.org/mozilla/source/tools/build-environment/win32/

Can you provide diffs from CVS?
(Assignee)

Comment 16

9 years ago
Created attachment 316434 [details] [diff] [review]
guess-msvc.bat patch rev.1.0
Attachment #314344 - Attachment is obsolete: true
Attachment #314344 - Flags: review?(ted.mielczarek)
(Assignee)

Comment 17

9 years ago
Created attachment 316436 [details] [diff] [review]
start-msvc8.bat patch rev.1.0

Patch for start-msvc8.bat
Attachment 315228 [details] was based on older file.
this patch is based on latest start-msvc8.bat (1.12)
Attachment #315228 - Attachment is obsolete: true
Attachment #316436 - Flags: review?(ted.mielczarek)
Attachment #315228 - Flags: review?(ted.mielczarek)
(Assignee)

Updated

9 years ago
Attachment #316434 - Attachment description: patch rev.1.0 → guess-msvc.bat patch rev.1.0
Attachment #316434 - Flags: review?(ted.mielczarek)
(Assignee)

Comment 18

9 years ago
Comment on attachment 316436 [details] [diff] [review]
start-msvc8.bat patch rev.1.0

sorry this is not correct file!!
Attachment #316436 - Attachment is obsolete: true
Attachment #316436 - Flags: review?(ted.mielczarek)
(Assignee)

Comment 19

9 years ago
Created attachment 316438 [details] [diff] [review]
start-msvc8.bat patch rev.1.1

This is based on start-msvc8.bat ver.1.12.
I checked environment variable's values but ,I can not test with clean-build.
Because my PC has a problem around CPU-fan, my PC hangs when building browser by OVERHEAT.
Please test this batch file with clean-build.
Attachment #316438 - Flags: review?(ted.mielczarek)
Attachment #316434 - Flags: review?(ted.mielczarek) → review+
Comment on attachment 316438 [details] [diff] [review]
start-msvc8.bat patch rev.1.1

Looks good, thanks for the descriptive comments in there!

On a related note, does Visual C++ 2008 Express Edition have this same problem? I assume so, since it doesn't have its own PSDK. Can we get a patch to fix start-msvc9.bat as well?
Attachment #316438 - Flags: review?(ted.mielczarek) → review+
Assignee: nobody → masa141421356
I checked these in. If VC 2008 needs the same fix we can do that in another bug.
Status: NEW → RESOLVED
Last Resolved: 9 years ago
Resolution: --- → FIXED

Comment 22

9 years ago
I've just opened bug 433483- I believe this is me experiencing this issue with VC 2008? Do I need to install the Windows Server R2 Platform SDK?
Looks like we probably need to make the same fix to start-msvc9.bat.

Comment 24

9 years ago
Should I close bug 433483 again as depending on this one or do you want to continue the start-msvc9.bat fixes in bug 433483?
Please move that other bug into the MozillaBuild component and someone can patch it there.

Comment 26

9 years ago
Smbd already moved to Build Config- I assume this is correct?
Depends on: 437748
Created attachment 324836 [details] [diff] [review]
same fix for start-msvc9.bat

I checked this in, it's the same fix for start-msvc9.bat.

Comment 28

9 years ago
The documentation at http://developer.mozilla.org/en/docs/Windows_Build_Prerequisites does not mention that the Server 2003 Platform SDK is required for Visual C++ Express 2008.
So fix it, it's a wiki.
(Assignee)

Updated

9 years ago
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.