Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

can i use multiple PCH files in 1 project?

Tags:

c++

build

pch

I want to use the PCH file to speed up the build, so i store the PCH file in a separate folder and reuse it when build the project later.

but I have some #import *.dll in my stdafx.h. so if something changed in the *.dll, the PCH file need be recreated.

my question is whether I can use multiple PCH files in 1 project, so that i can put the import *.dll to another PCH and only recreate this one if something changed in *.dll.

thanks in advance :)

like image 665
fresky Avatar asked Mar 30 '10 02:03

fresky


1 Answers

No, you can only include one pch file per cl.exe invocation.

It's a bummer but that's the way it is.

like image 121
Zain Rizvi Avatar answered Sep 29 '22 01:09

Zain Rizvi