Project

General

Profile

Where to find info on Preprocessor Directives?

Added by Tibor Peak over 9 years ago

I can see the following preprocessor directives in the WT Examples Visual Studio projects (generated by CMake):

- WT_WITH_OLD_INTERNALPATH_API

- WT_DEPRECATED_3_0_0

  • WT_THREADED

Do I need these when I make my own applications?

Where can I find information on these directives?

Thanks in advance

Tibor


Replies (4)

RE: Where to find info on Preprocessor Directives? - Added by Vincenzo Romano over 9 years ago

Those symbols are defined/controlled by the build system.

Thus, once the library has been configured and installed, they are not needed by the programmer.

RE: Where to find info on Preprocessor Directives? - Added by Wim Dumon over 9 years ago

That is correct. In addition, all defines that have to be set in your own projects are defined in WConfig.h, so that you don't have to worry about this anymore.

Wim.

RE: Where to find info on Preprocessor Directives? - Added by Tibor Peak over 9 years ago

Ok, I see.

I'm building the 3.3.3 version of Witty with Visual Studio 2013, using CMake 3.0.1 to generate the VS projects.

I made some checks about the presence of these directives:

WT_WITH_OLD_INTERNALPATH_API and WT_THREADED is present in all the *.vcxproj files.

WT_DEPRECATED_3_0_0 is present only in the example *.vcxproj files.

Looking at the source files, WT_DEPRECATED_3_0_0 and WT_THREADED is used in several source files, but WT_WITH_OLD_INTERNALPATH_API is not.

Do I understand right that WT_DEPRECATED_3_0_0 means: the Witty build will NOT support the deprecated features?

So, the library built with VS will contain the deprecated features?

Tibor

RE: Where to find info on Preprocessor Directives? - Added by Wim Dumon over 9 years ago

We set that define in the examples to be sure that the examples don't use deprecated method calls. That define is not set while building the library to have a better backward compatibility.

Wim.

    (1-4/4)