public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Question Converting nmake cl Makefiles to make gcc
@ 1997-04-06  9:02 Mikey
  1997-04-07 12:38 ` OLE 2.0 and G++ Eric Britten
  0 siblings, 1 reply; 2+ messages in thread
From: Mikey @ 1997-04-06  9:02 UTC (permalink / raw)
  To: cygnus

Does anyone know of any automatic tools (shell scripts using sed maybe) for
converting Makefiles used by VC++ to something that make and gcc can use?

-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

^ permalink raw reply	[flat|nested] 2+ messages in thread

* OLE 2.0 and G++
  1997-04-06  9:02 Question Converting nmake cl Makefiles to make gcc Mikey
@ 1997-04-07 12:38 ` Eric Britten
  0 siblings, 0 replies; 2+ messages in thread
From: Eric Britten @ 1997-04-07 12:38 UTC (permalink / raw)
  To: cygnus

I was trying to compile a shell extension example from microsoft and ran
into a few problems.  I recieved errors and warnings that I did not like.
I am using the headers provided by the Platform SDK from Microsoft.

The shell extensions used C++ classes, not the C structures.

The warnings that bothered me came from the virtual member functions of
all the Interfaces in the ole 2.0 headers.

For example, an interface:

class IFoo
{
public:
  void __stdcall Bar() = 0;		//4
  void * __stdcall BarPtr() = 0;  	//5
};

On line 4 I would receive a warning like:

file.cpp:4: warning:  attribute directive ignored

I know that __stdcall expands to __attribute__((stdcall)).  All OLE
functions and interfaces use the __stdcall convention.  I am worried that
since the attribute directive is ignored that the __stdcall convention
will be ignored, and the __cdecl convention will be used instead.  I doubt
that the two conventions are compatible.  Can Class member functions be
__stdcall.  I determined that the fact that the function is pure virtual
is not relavent.

The errors that I received were something like
file.cpp:5: syntax error before __attribute__.  Using trial and error I
found that if the pointer '*' is placed after the __stdcall then there is
no error.  Why would it make a difference if the function had:

void * __stdcall
-or-
void __stdcall *
?

There is a chance that I have this reversed, I can't check right now.
 
And lastly is it possible to export a C++ class, its member data, or its
member functions from a dll?  It it possible to export a function that is
in a c++ module that is not 'extern "C"'?


Eric Britten
------------------------------------------------------
------------------------------------------------------

-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1997-04-07 12:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-04-06  9:02 Question Converting nmake cl Makefiles to make gcc Mikey
1997-04-07 12:38 ` OLE 2.0 and G++ Eric Britten

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).