From: John B. <joh...@ho...> - 2004-02-07 00:07:22
|
>... It seems that under IIS, we are obliged to use COM components. >How can we use mingw to generate such DLL?. Can you send me some source >code and hints. See the CAUTOEX sample at ftp://ftp.microsoft.com/softlib/mslfiles/cautoex.exe. The self extracting archive contains a sample OLE automation object and a sample controller written in C. _________________________________________________________________ Plan your next US getaway to one of the super destinations here. http://special.msn.com/local/hotdestinations.armx |
From: John B. <joh...@ho...> - 2004-02-10 01:22:22
|
>I believed COM has to deal with objects, so 1995 source code was far from >that. OLE is from that date (win95), COM went after. I am not sure about terminology, but as far as I am concerned, anything that can be called in the following way, as you might use the object in an Active Server Page script: dim myApp as Object set myApp = CreatObject("MyObject") x = myApp.Method1(p1, p2) myApp.Property1 = value1 etc. is an "object" of the type that you require. >Does it compile under mingw?. Unfortunately, the sample cannot be compiled using mingw alone, because it needs the mktyplib utility to generate a type library. However, this utility is distributed with the Microsoft Platform SDK, which is a free (but massive) download. Apart from that, you only need to correct the WinMain prototype in the main.c files. >I'm looking for mingw instructions to generate such code too.. The makefile is for MS Visual C++, of course. The following commands should work. You don't need any special flags. This object lives in an EXE and not a DLL. I don't really know of any specific resource other than MSDN, (the sample source should help you to make sense of it), but I'm sure someone else will be able to suggest a tutorial that is easier to digest. cauto.exe (the object) gcc -c comp.c gcc -c error.c gcc -c main.c windres -o mainres.o main.rc gcc -o *.o -mwindows -lole32 -loleaut32 -luuid mktyplib /h icauto.h /nocpp /tlb cauto.tlb cauto.odl Edit cauto.reg so that it refers to the directory that contains cauto.exe and cauto.tlb and then mergeit with your registry. cautocon.exe (the controller) gcc -c cntl.c gcc -c error.c gcc -c main.c windres -o mainres.o main.rc gcc -o *.o -mwindows -lole32 -loleaut32 -luuid >It seems that's a rather old code (1995)!. That may be, but I just compiled it with gcc version 3.2.3 (mingw special 20030504-1) (plus mktyplib.exe from the Platform SDK, as mentioned previously) and it works on Windows Server 2003. _________________________________________________________________ Find great local high-speed Internet access value at the MSN High-Speed Marketplace. http://click.atdmt.com/AVE/go/onm00200360ave/direct/01/ |
From: LALOT D. <la...@un...> - 2004-02-10 07:41:16
|
Thanks John, May be I'll have a try with MS products. It looks rather difficult!.. Dom John Brown a =E9crit : >> I believed COM has to deal with objects, so 1995 source code was far=20 >> from that. OLE is from that date (win95), COM went after. > > > I am not sure about terminology, but as far as I am concerned,=20 > anything that can be called in the following way, as you might use the=20 > object in an Active Server Page script: > > dim myApp as Object > > set myApp =3D CreatObject("MyObject") > x =3D myApp.Method1(p1, p2) > myApp.Property1 =3D value1 > > etc. > > is an "object" of the type that you require. > >> Does it compile under mingw?. > > > Unfortunately, the sample cannot be compiled using mingw alone,=20 > because it needs the mktyplib utility to generate a type library.=20 > However, this utility is distributed with the Microsoft Platform SDK,=20 > which is a free (but massive) download. Apart from that, you only need=20 > to correct the WinMain prototype in the main.c files. > >> I'm looking for mingw instructions to generate such code too.. > > The makefile is for MS Visual C++, of course. The following commands=20 > should work. You don't need any special flags. This object lives in an=20 > EXE and not a DLL. I don't really know of any specific resource other=20 > than MSDN, (the sample source should help you to make sense of it),=20 > but I'm sure someone else will be able to suggest a tutorial that is=20 > easier to digest. > > cauto.exe (the object) > > gcc -c comp.c > gcc -c error.c > gcc -c main.c > windres -o mainres.o main.rc > gcc -o *.o -mwindows -lole32 -loleaut32 -luuid > mktyplib /h icauto.h /nocpp /tlb cauto.tlb cauto.odl > > Edit cauto.reg so that it refers to the directory that contains=20 > cauto.exe and cauto.tlb and then mergeit with your registry. > > cautocon.exe (the controller) > > gcc -c cntl.c > gcc -c error.c > gcc -c main.c > windres -o mainres.o main.rc > gcc -o *.o -mwindows -lole32 -loleaut32 -luuid > > >> It seems that's a rather old code (1995)!. > > > That may be, but I just compiled it with gcc version 3.2.3 (mingw=20 > special 20030504-1) (plus mktyplib.exe from the Platform SDK, as=20 > mentioned previously) and it works on Windows Server 2003. > > _________________________________________________________________ > Find great local high-speed Internet access value at the MSN=20 > High-Speed Marketplace.=20 > http://click.atdmt.com/AVE/go/onm00200360ave/direct/01/ > > > > ------------------------------------------------------- > The SF.Net email is sponsored by EclipseCon 2004 > Premiere Conference on Open Tools Development and Integration > See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. > http://www.eclipsecon.org/osdn > _______________________________________________ > MinGW-users mailing list > Min...@li... > > You may change your MinGW Account Options or unsubscribe at: > https://lists.sourceforge.net/lists/listinfo/mingw-users > > --=20 Dominique LALOT=20 Ing=E9nieur Syst=E8me R=E9seau CISCAM Pole R=E9seau Universit=E9 de la M=E9diterran=E9e http://annuaire.univ-mrs.fr/showuser?= uid=3Dlalot |
From: David F. <da...@sj...> - 2004-02-10 08:01:55
|
LALOT Dominique wrote: > Thanks John, > > May be I'll have a try with MS products. It looks rather difficult!.. > > Dom Hi John Might look difficult but be careful that if you use a lot of the MS=20 macros it can actually make your life more difficult in the wrong run.=20 Depending on exactly what you're wanting to do, of course... David > > John Brown a =E9crit : > >>> I believed COM has to deal with objects, so 1995 source code was=20 >>> far from that. OLE is from that date (win95), COM went after. >> >> >> >> I am not sure about terminology, but as far as I am concerned,=20 >> anything that can be called in the following way, as you might use=20 >> the object in an Active Server Page script: >> >> dim myApp as Object >> >> set myApp =3D CreatObject("MyObject") >> x =3D myApp.Method1(p1, p2) >> myApp.Property1 =3D value1 >> >> etc. >> >> is an "object" of the type that you require. >> >>> Does it compile under mingw?. >> >> >> >> Unfortunately, the sample cannot be compiled using mingw alone,=20 >> because it needs the mktyplib utility to generate a type library.=20 >> However, this utility is distributed with the Microsoft Platform SDK,=20 >> which is a free (but massive) download. Apart from that, you only=20 >> need to correct the WinMain prototype in the main.c files. >> >>> I'm looking for mingw instructions to generate such code too.. >> >> >> The makefile is for MS Visual C++, of course. The following commands=20 >> should work. You don't need any special flags. This object lives in=20 >> an EXE and not a DLL. I don't really know of any specific resource=20 >> other than MSDN, (the sample source should help you to make sense of=20 >> it), but I'm sure someone else will be able to suggest a tutorial=20 >> that is easier to digest. >> >> cauto.exe (the object) >> >> gcc -c comp.c >> gcc -c error.c >> gcc -c main.c >> windres -o mainres.o main.rc >> gcc -o *.o -mwindows -lole32 -loleaut32 -luuid >> mktyplib /h icauto.h /nocpp /tlb cauto.tlb cauto.odl >> >> Edit cauto.reg so that it refers to the directory that contains=20 >> cauto.exe and cauto.tlb and then mergeit with your registry. >> >> cautocon.exe (the controller) >> >> gcc -c cntl.c >> gcc -c error.c >> gcc -c main.c >> windres -o mainres.o main.rc >> gcc -o *.o -mwindows -lole32 -loleaut32 -luuid >> >> >>> It seems that's a rather old code (1995)!. >> >> >> >> That may be, but I just compiled it with gcc version 3.2.3 (mingw=20 >> special 20030504-1) (plus mktyplib.exe from the Platform SDK, as=20 >> mentioned previously) and it works on Windows Server 2003. >> >> _________________________________________________________________ >> Find great local high-speed Internet access value at the MSN=20 >> High-Speed Marketplace.=20 >> http://click.atdmt.com/AVE/go/onm00200360ave/direct/01/ >> >> >> >> ------------------------------------------------------- >> The SF.Net email is sponsored by EclipseCon 2004 >> Premiere Conference on Open Tools Development and Integration >> See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. >> http://www.eclipsecon.org/osdn >> _______________________________________________ >> MinGW-users mailing list >> Min...@li... >> >> You may change your MinGW Account Options or unsubscribe at: >> https://lists.sourceforge.net/lists/listinfo/mingw-users >> >> > |
From: LALOT D. <la...@un...> - 2004-02-09 09:57:28
|
Does it compile under mingw?. I'm looking for mingw instructions to generate such code too.. It seems that's a rather old code (1995)!. I believed COM has to deal with objects, so 1995 source code was far=20 from that. OLE is from that date (win95), COM went after. Thanks Dominique John Brown a =E9crit : >> ... It seems that under IIS, we are obliged to use COM components. >> How can we use mingw to generate such DLL?. Can you send me some=20 >> source code and hints. > > > See the CAUTOEX sample at=20 > ftp://ftp.microsoft.com/softlib/mslfiles/cautoex.exe. The self=20 > extracting archive contains a sample OLE automation object and a=20 > sample controller written in C. > > _________________________________________________________________ > Plan your next US getaway to one of the super destinations here.=20 > http://special.msn.com/local/hotdestinations.armx > > > > ------------------------------------------------------- > The SF.Net email is sponsored by EclipseCon 2004 > Premiere Conference on Open Tools Development and Integration > See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. > http://www.eclipsecon.org/osdn > _______________________________________________ > MinGW-users mailing list > Min...@li... > > You may change your MinGW Account Options or unsubscribe at: > https://lists.sourceforge.net/lists/listinfo/mingw-users > > --=20 Dominique LALOT=20 Ing=E9nieur Syst=E8me R=E9seau CISCAM Pole R=E9seau Universit=E9 de la M=E9diterran=E9e http://annuaire.univ-mrs.fr/showuser?= uid=3Dlalot |