From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f678f,1d40255a9f8bfd71 X-Google-Attributes: gidf678f,public X-Google-ArrivalTime: 1993-09-10 14:24:42 PST Path: gmd.de!newsserver.jvnc.net!howland.reston.ans.net!sol.ctr.columbia.edu!news.kei.com!bloom-beacon.mit.edu!paperboy.osf.org!bubba.osf.org!jec From: jec@bubba.osf.org (Jonathan Chinitz) Newsgroups: comp.unix.osf.misc Subject: Re: Problem in compiling an IDL file Date: 10 Sep 1993 20:23:58 GMT Organization: IntelliSoft Corp. Message-ID: <26qnou$3mf@paperboy.osf.org> References: NNTP-Posting-Host: bubba.osf.org In article rwessman@rwessman.us.oracle.com (Rick Wessman) writes: >I'm having difficulty compiling an IDL file when including DCE include files. >The IDL file (simplified) looks like this: > >#include >#include > >. >. >. >interface foobarif >{ > void foobar([out, ref] sec_id_pac_t *pac); >} > >When I run idl, I get: > >idl -v -cc_cmd "gcc -c -g" -keep all -I. -I/opt/dcelocal/share/include -I/usr/xpg2include foobar.idl >Running C preprocessor /lib/cpp foobar.idl -I. -I. -I/opt/dcelocal/share/include -I/usr/xpg2include -I/usr/include >Importing IDL file /opt/dcelocal/share/include/dce/nbase.idl >Running C preprocessor /lib/cpp /opt/dcelocal/share/include/dce/nbase.idl -I. -I. -I/opt/dcelocal/share/include -I/usr/xpg2include -I/usr/include >Warning: Semantic checking prevented by other reported errors >idl: File /opt/dcelocal/share/include/dce/idlbase.h, line 160: typedef struct >idl: Syntax error near "typedef" > >Compilation aborted > >Has anyone ever seen this before? > If you want to include other .idl files in your .idl file, the proper syntax is to use the "import" command. So, replace the #include with the following interface foo { import "dce/nbase.idl"; import ..... .... } Also, the nbase idl file is automatically included in the stub files that are generated. Poke around the stub files and header file and you will see that a lot of header files are included for you. Jonathan -- ------------------------------------------------------------------------------- Jonathan Chinitz E-mail: jec@isoft.com IntelliSoft Corp. Distributed Computing Solutions P.O. Box 2645 Tel.: 508-635-9070 Acton, MA 01720 Fax: 508-635-9210