Closed Bug 244449 Opened 20 years ago Closed 20 years ago

nsClipboard.cpp tends to include urlmon.h. However, it is not in MinGW.

Categories

(Core Graveyard :: GFX: Win32, defect)

Other Branch
x86
Windows XP
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: nivoside, Assigned: mscott)

References

Details

Attachments

(1 file, 1 obsolete file)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; ja-JP; rv:1.7) Gecko/20040518 Firefox/0.8.0+
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; ja-JP; rv:1.7) Gecko/20040518 Firefox/0.8.0+

http://webtools.mozilla.org/bonsai/cvsblame.cgi?file=mozilla/widget/src/windows/nsClipboard.cpp&rev=AVIARY_1_0_20040515_BRANCH&root=/cvsroot
It seems that build by MinGW has gone wrong since there is a problem
in the 45th line etc.

Description with a problem is quoted.
> #include <urlmon.h> // needed for CopyStgMedium


In order to avoid the problem which arises by MinGW,
there is the following description in other files.

http://lxr.mozilla.org/seamonkey/source/widget/src/windows/IENUMFE.H#42
> #ifndef __MINGW32__
> #include <urlmon.h>
> #endif


Although it is troubled that a part of functions are lost, it can build,
and I think that it is good rather than there is nothing.



A machine translates this report.
Although there may be a strange portion, it wants without caring.

Reproducible: Always
Steps to Reproduce:
Assignee: bryner → win32
Component: Build Config → GFX: Win32
Product: Firefox → Browser
QA Contact: asa → ian
Version: unspecified → Trunk
scott: please fix this before asking for review to land on trunk.
Assignee: win32 → mscott
Attached patch possible fix? (obsolete) — Splinter Review
does this fix the problem for you?
Comment on attachment 149170 [details] [diff] [review]
possible fix?

>+#ifndef __MINGW32__
> #include <urlmon.h> // needed for CopyStgMedium
>+#endif

presumably the code won't compile/link at the place where that's called....
Attachment #149170 - Flags: review-
Source was got from CVS, and the effective binary could be built, or it tested.

2004-05-16 17:50 PDT
It succeeded. The effective binary was completed.

2004-05-16 18:00 PDT
The error occurred.


http://tinderbox.mozilla.org/bonsai/cvsquery.cgi?treeid=default&module=PhoenixTinderbox&branch=AVIARY_1_0_20040515_BRANCH&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=explicit&mindate=2004-05-16+17%3A50&maxdate=2004-05-16+18%3A00&cvsroot=%2Fcvsroot
The cause by which the problem arose.
Mingw doesn't have urlmon.h nor an import lib for urlmon.dll so we need to
avoid the calls altogether.
Attachment #149170 - Attachment is obsolete: true
Status: UNCONFIRMED → NEW
Ever confirmed: true
Attachment #150829 - Flags: review?(mscott)
Comment on attachment 150829 [details] [diff] [review]
no urlmon for mingw

thanks Chris.

Note: this patch is for the aviary1.0 branch only. None of the urlmon stuff for
clipboard is in the trunk.
Attachment #150829 - Flags: review?(mscott) → review+
Comment on attachment 150829 [details] [diff] [review]
no urlmon for mingw


>@@ -955,19 +958,27 @@
> 
> NS_IMETHODIMP nsClipboardImage::SetNativeImage(void * aNativeImageData)
> {
>+#ifdef __MINGW32__
>+  return NS_ERROR_NOT_IMPLEMENTED;
>+#else
>   if(mStgMedium.hGlobal)
>     ReleaseStgMedium(&mStgMedium);
>     
>   HRESULT err = CopyStgMedium((STGMEDIUM *) aNativeImageData, &mStgMedium);
>+#endif
>   return NS_OK;

Whoops.  The #endif needs to be moved down one line for the checkin.
Attachment #150829 - Flags: review+ → review?(mscott)
Attachment #150829 - Flags: review?(mscott) → review+
Patch has been checked in.
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Thank you.
Version: Trunk → Other Branch
The source of the branch around 20:00 on June 17 (PDT) was acquired, and it
tested by MinGW (3.3.1).

An error is displayed and firefox.exe is not completed.
"ld: cannot find -lUrlmon"

When a "Static build" option is specified, this problem arises.

Isn't this bug fixed completely yet? Or is there any other bug?
Blocks: mingw
The problem which cannot perform static build was filed as Bug 250115.
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: