www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 4295] New: IID_IUnknown symbol undefined in phobos.lib

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295

           Summary: IID_IUnknown symbol undefined in phobos.lib
           Product: D
           Version: 2.041
          Platform: Other
        OS/Version: Windows
            Status: NEW
          Keywords: link-failure, rejects-valid
          Severity: normal
          Priority: P2
         Component: Phobos
        AssignedTo: nobody puremagic.com
        ReportedBy: mrmocool gmx.de


--- Comment #0 from Trass3r <mrmocool gmx.de> 2010-06-08 10:24:18 PDT ---
std.c.windows.windows defines extern IID IID_IUnknown (and later uses it in
ComObject)
but the linker complains that the symbol is undefined.

Replacing it with

IID IID_IUnknown = {0x00000000, 0x0000, 0x0000, [0xC0, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x46]};

makes it work, but I'm not sure if this is the correct GUID.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jun 08 2010
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295


Rainer Schuetze <r.sagitario gmx.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |r.sagitario gmx.de


--- Comment #1 from Rainer Schuetze <r.sagitario gmx.de> 2010-06-08 11:04:02
PDT ---
You need to link against uuid.lib to resolve the symbol. 

I don't think it is possible to add a pragma(lib,"uuid") upon usage, so this
should be mentioned somewhere (maybe
http://www.digitalmars.com/d/2.0/COM.html).

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jun 08 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295


Trass3r <mrmocool gmx.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |spec


--- Comment #2 from Trass3r <mrmocool gmx.de> 2010-06-08 11:28:05 PDT ---
Ah thanks. Then it should be fixed in the docs.
Also at http://digitalmars.com/d/2.0/dll.html#com

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jun 08 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295



--- Comment #3 from Trass3r <mrmocool gmx.de> 2010-06-08 11:30:20 PDT ---
Just found out that pragma(lib, "uuid") is actually present in
std.windows.iunknown!

But this one is more or less obsolete.
std.c.windows.com contains more functionality and also the ComObject class that
is mentioned in the docs IIRC.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jun 08 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295


Walter Bright <bugzilla digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bugzilla digitalmars.com


--- Comment #4 from Walter Bright <bugzilla digitalmars.com> 2010-09-27
19:53:52 PDT ---
#pragma(lib, "uuid") is already present in std.c.windows.com.

So, I need an example of code where the link is failing due to not linking
against uuid.lib.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Sep 27 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295



--- Comment #5 from Rainer Schuetze <r.sagitario gmx.de> 2010-09-27 23:05:55
PDT ---
The pragma was added by Andrei in the meantime, so you might consider it fixed.

Please consider deprecating/removing std.windows.iunknown, because it only
duplicates part of the code in std.c.windows.com which can lead to confusion.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Sep 27 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295


Andrej Mitrovic <andrej.mitrovich gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |andrej.mitrovich gmail.com
         Resolution|                            |FIXED


--- Comment #6 from Andrej Mitrovic <andrej.mitrovich gmail.com> 2011-05-24
21:01:55 PDT ---
If it's fixed, we shall close it. :)

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 24 2011
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295



--- Comment #7 from Trass3r <mrmocool gmx.de> 2011-05-25 06:29:08 PDT ---
It isn't fixed, std.windows.iunknown is still present.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 25 2011
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295


Andrej Mitrovic <andrej.mitrovich gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|FIXED                       |


--- Comment #8 from Andrej Mitrovic <andrej.mitrovich gmail.com> 2011-05-25
07:23:16 PDT ---
Okie no more monkey-business from me.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 25 2011
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295



--- Comment #9 from github-bugzilla puremagic.com 2012-01-23 18:05:47 PST ---
Commit pushed to https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/5ad3dafd10002983fe92907c14ff5e8322c22d86
fix Issue 4295 - IID_IUnknown symbol undefined in phobos.lib

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jan 23 2012
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4295


Walter Bright <bugzilla digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |FIXED


-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jan 23 2012