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

Compilation with CLFFT_APPLE (in ocl mode) fails #276

Closed
myurkin opened this issue Oct 12, 2020 · 1 comment
Closed

Compilation with CLFFT_APPLE (in ocl mode) fails #276

myurkin opened this issue Oct 12, 2020 · 1 comment
Assignees
Labels
bug Incorrect code behavior comp-Scripts Related to Makefiles, wrappers, developer and testing scripts OpenCL Running on GPUs and similar devices pri-Medium Worth assigning to a milestone
Milestone

Comments

@myurkin
Copy link
Member

myurkin commented Oct 12, 2020

Describe the bug

The problem is due to the fact that cpp/fft_execute.cpp includes function.h (for ATT_UNUSED), which in turn includes const.h (for some simple macro). And the latter header tests for C99 compliance, which naturally fails in C++ compilation mode.

To reproduce

make ocl OPTIONS=CLFFT_APPLE

Expected behavior

Normal compilation

Output

...
g++ -c -O3 -ffast-math -funroll-loops -w  -MD ../cpp/fft_execute.cpp
In file included from ../cpp/../function.h:20:0,
                 from ../cpp/fft_execute.cpp:50:
../cpp/../const.h:29:5: error: #error "Support for C99 standard (at least many of its parts) is strongly recommended for compilation. Otherwise         the compilation will may failor produce wrong results. If you still want to try, you may enable an override in       the Makefile."
...

Technical information

@myurkin myurkin added bug Incorrect code behavior comp-Scripts Related to Makefiles, wrappers, developer and testing scripts pri-Medium Worth assigning to a milestone OpenCL Running on GPUs and similar devices labels Oct 12, 2020
@myurkin myurkin added this to the 1.4 milestone Oct 12, 2020
@myurkin myurkin self-assigned this Oct 12, 2020
@myurkin
Copy link
Member Author

myurkin commented Oct 12, 2020

Fixed by be0830d

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Incorrect code behavior comp-Scripts Related to Makefiles, wrappers, developer and testing scripts OpenCL Running on GPUs and similar devices pri-Medium Worth assigning to a milestone
Projects
None yet
Development

No branches or pull requests

1 participant