Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use target_compile_definitions to build backend within another project #54

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

tikuma-lsuhsc
Copy link

When you include this cmake project as a "subproject" of another project, CMake complains in Windows (MSVC) that it cannot find M_PI because -D_USE_MATH_DEFINES is not defined. (Actually it does something really funky if I add #define _USE_MATH_DEFINES to the source files. The compiler complains that _USE_MATH_DEFINES has already been defined despite it's not.)

Anyway, this PR fixes this issue by using per-project target_compile_definitions cmake command instead of add_definition.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant