cons-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: QuickScan and exported files....


From: Eric Brown
Subject: RE: QuickScan and exported files....
Date: Tue, 5 Jun 2001 11:03:38 -0700

Actually, I've tried it both ways (with quotes and angle brackets), with no
observable difference in behavior.  This also occurs in Cons 2.3.0, as well.

> -----Original Message-----
> From: Greg Spencer [mailto:address@hidden
> Sent: Tuesday, June 05, 2001 8:46 AM
> To: 'Eric Brown'; address@hidden
> Subject: RE: QuickScan and exported files....
> 
> 
> Eric, try removing the "<" and ">" around Ecm_err.h and replacing them
> with '"'s.
> 
> Cons (and the compiler) treat these differently, and that may make all
> the difference for you.
> 
>                       -Greg.
> 
> -----Original Message-----
> From: address@hidden 
> [mailto:address@hidden On
> Behalf Of Eric Brown
> Sent: Tuesday, May 29, 2001 2:18 PM
> To: 'address@hidden'
> Subject: QuickScan and exported files....
> 
> 
> I'm running into a problem using Cons to build IDL files that include
> files
> outside the current directory.  In particular, the header file isn't
> getting
> copied to the export directory before the IDL compiler is getting
> called.
> 
> The details are as follows:
> 
> I have a top level Inc directory that contains a file Ecm_err.h.
> 
> In another directory, I have a file ECMWrapperS3.idl that has the
> following:
> // This file will be processed by the MIDL tool to
> // produce the type library (ECMWrapperS3.tlb) and marshalling code.
> #include <Ecm_err.h>
> 
> import "oaidl.idl";
> import "ocidl.idl";
> 
> <lots of IDL follows>
> 
> My IDL generator function contains the following call to QuickScan:
> 
>     $env->QuickScan(
>               sub { my(@includes); 
>                       do {
>                               push (@includes, $3 ) 
>                                       if
> /^\s*(#include|import)\s+(\")(.+)(\")/ && $3 
>                       } 
>                       while <SCAN> ;
>                       @includes 
>               } ,
>               "$args{IDL}",
>               "$env->{CPPPATH}" 
>     );
> 
> $env->{CPPPATH} is
> "build\debug\ECMWra~1\ECMWrapperS3\res;#export/debug/include;#
> export/deb
> ug/i
> nclude".
> 
> Inc/Conscript has
> 
> # Put Headers Here
> @HDRS = qw(
>       Ecm_err.h
>       Ecm_all.h
>       Ecm.h
>       Add.h
>       Add_err.h
>       );
> 
> Install $CONS $INCLUDE, @HDRS;
> 
> If I print @includes in the QuickScan call, I get "Ecm_err.h oaidl.idl
> ocidl.idl"
> So, as you can see, everything *looks* like it ought to be copying
> Inc/Ecm_err.h to #export/debug/include, where the IDL 
> compiler can find
> it.
> Instead, all I get is this:
> D:\tropics\Ver1.0>cons
> midl.exe /Ibuild\debug\ECMWra~1\ECMWrapperS3\res 
> /Iexport/debug/include
> /Iexport/debug/include /char unsigned /h "ECMWrapperS3.h" /iid
> "ECMWrapperS3_i.c" /tlb "ECMWrapperS3.tlb" /out
> build\debug\ECMWra~1\ECMWrapperS3 /Oicf
> build\debug\ECMWra~1\ECMWrapperS3\ECMWrapperS3.idl
> Microsoft (R) MIDL Compiler Version 5.01.0164
> Copyright (c) Microsoft Corp 1991-1997. All rights reserved.
> Processing build\debug\ECMWra~1\ECMWrapperS3\ECMWrapperS3.idl
> ECMWrapperS3.idl
> build\debug\ECMWra~1\ECMWrapperS3\ECMWrapperS3.idl(8) : fatal error
> C1083:
> Cannot open include file: 'Ecm_err.h': No such file or directory
> midl : command line error MIDL1003 : error returned by the C
> preprocessor
> (2)
> cons.bat build_error: ***
> [build\debug\ECMWra~1\ECMWrapperS3\ECMWrapperS3.h]
> Error 60160
> cons.bat build_error: errors constructing
> build\debug\ECMWra~1\ECMWrapperS3\ECMWrapperS3.tlb
> 
> I can hack it into working (by manually including the inc directory),
> but I
> don't think I should have to do this.
> 
> Any suggestions?  (I'm running Tony Kolarik's modified version of Cons
> 1.8.)
> 
> _______________________________________________
> address@hidden
> http://mail.gnu.org/mailman/listinfo/cons-discuss
> Cons URL: http://www.dsmit.com/cons/
> 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]