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

refactoring cmake #17

Merged
merged 2 commits into from
Sep 3, 2024
Merged

refactoring cmake #17

merged 2 commits into from
Sep 3, 2024

Conversation

dsm
Copy link
Contributor

@dsm dsm commented Aug 24, 2024

Hi, this PR refactor cmake file to build with same flag for qucs-s and remove unnecessary checks so time consuming.

@ra3xdh
Copy link
Owner

ra3xdh commented Aug 24, 2024

Yes, I was considering to remove the check for functions. But the removing theses checks from CMake is not sufficient. The HAVE_COMPLEX_XXX definitions are used in src/math/complex.cpp and src/math/real.cpp If these macros are not defined the qucsator implies the complex funcitons are missing and emulates it by software means. Please check carefully if these macros are in use. The same concerns SIZEOF_DOUBLE etc.

It makes sense to disable software emulation of the complex functions, because it is part of C++ standard in the modern C++.

@ra3xdh ra3xdh self-requested a review August 24, 2024 16:30
@ra3xdh ra3xdh added this to the 1.0.2 milestone Aug 24, 2024
@dsm
Copy link
Contributor Author

dsm commented Aug 24, 2024

We use gcc 12 or later or clang so this checks not meaning for modern compiler, so maybe we check compiler version or we target above c++11 but yes code base needs some modernization and we should remove this macros in code.

@ra3xdh
Copy link
Owner

ra3xdh commented Aug 26, 2024

I will try to remove function wrappers in complex.cpp and real.cpp and then merge this PR.

@ra3xdh
Copy link
Owner

ra3xdh commented Sep 3, 2024

I have added #18 removing HAVE_CXX and HAVE_STD definitions usage. Now real.cpp and complex.cpp switched to C++11 implementation. Software emulation of the math functions disabled. Merging this PR become possible.

@ra3xdh ra3xdh merged commit 3ecb782 into ra3xdh:develop Sep 3, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants