Re: Determining PCH use

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

 



On Wed, Apr 17, 2013 at 6:51 AM, Miguel Guedes
<miguel.a.guedes@xxxxxxxxx> wrote:
>
> I'm successfully generating a PCH but am not sure if it is being used as
> the project is built out of source. The generated `pch.hxx.gch' is
> created in the same directory as the `pch.hxx' header but everything else
> - objects, libraries, binaries, dependencies - are created out of
> source.
>
> Have tried passing the -H switch but I can't see the actual `pch.hxx.gch'
> PCH being used; only `pch.hxx' shows up in the long list of include
> files.
>
> Should the -H switch be showing the `pch.hxx.gch' PCH? If not, is there
> any other way of determining if the PCH is being used? Probably
> irrelevant but have also used `-Winvalid-pch' and no warnings are output.
In the past I used the following [hack]  in pch.hxx to verify use of
precompiled headers:

    #pragma message("Including precompiled header file.")

If it shows up once, then you are using precompiled headers. If it
shows up multiple times, you are not.

Jeff




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux