[cmake-developers] [CMake 0012909]: rc.exe cannot find generated type library, Visual Studio 10 builder

Mantis Bug Tracker mantis at public.kitware.com
Mon Jan 23 14:48:41 EST 2012


The following issue has been SUBMITTED. 
====================================================================== 
http://public.kitware.com/Bug/view.php?id=12909 
====================================================================== 
Reported By:                James Mansion
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   12909
Category:                   CMake
Reproducibility:            always
Severity:                   major
Priority:                   high
Status:                     new
====================================================================== 
Date Submitted:             2012-01-23 14:48 EST
Last Modified:              2012-01-23 14:48 EST
====================================================================== 
Summary:                    rc.exe cannot find generated type library, Visual
Studio 10 builder
Description: 
I have an IDL file that generates a type library, and an RC file that wants to
embed it.

The .tlb is emitted here:

C:\build\easyrtd.vs10\EasyRTD\easyrtd.dir\Debug>dir *.tlb
 Volume in drive C has no label.
 Volume Serial Number is 5AB0-0B44

 Directory of C:\build\easyrtd.vs10\EasyRTD\easyrtd.dir\Debug

23/01/2012  18:52             2,612 EasyRTD.tlb
               1 File(s)          2,612 bytes
               0 Dir(s)  171,651,473,408 bytes free

there is no obvious sign of the rc file (easyrtd.rc) in the working build
directory, but if I insert a #error statement I get:

1>C:\src\easyrtd\EasyRTD\easyrtd.src\EasyRTD.rc(21): error RC2188:
C:\build\easyrtd.vs10\EasyRTD\EasyRTD.dir\Debug\RCa03492(25) : fatal error
RC1116: RC terminating after preprocessor errors
1>

which suggests that the file was copied over, if temporarily.

Unfortunately I cannot say:

2 TYPELIB "EasyRTD.tlb"

since rc.exe fails to find the file.

I can say:

2 TYPELIB "c:\build\easyrtd.vs10\EasyRTD\easyrtd.dir\Debug\EasyRTD.tlb"

or, I can say:

2 TYPELIB "EasyRTD.tlb"

if I also (don't laugh!) say in CMakeLists.txt:

include_directories(. c:/build/easyrtd.vs10/EasyRTD/easyrtd.dir/Debug)

before the source definition.




Steps to Reproduce: 
Simple project that defines a type library and tries to embed it should do.

Additional Information: 
Its concerning also that there isn't a failure from include scanning I guess.

Is this construct (generate and import a type library) supported at all at the
moment?

Is there a preferred recipe?
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2012-01-23 14:48 James Mansion  New Issue                                    
======================================================================




More information about the cmake-developers mailing list