-
-
Notifications
You must be signed in to change notification settings - Fork 55
CMake: fix ENABLE_SYSTEM_GMIC #172
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
It is no longer possible to build without "-Dgmic_core", so we enable it unconditionally.
Closed
amyspark
added a commit
to amyspark/gmic
that referenced
this pull request
Feb 20, 2023
PR c-koi/gmic-qt#172 is correct in that it is no longer possible to build without -Dgmic_core, due to G'MIC-Qt relying in now-private implementation details of G'MIC; namely, the extensions made in gmic.cpp to CImg. However, the solution chosen has significant shortcomings: 1. It blindly assumes that the consumed library has been built by a GCC-compatible compiler. This is easily inferred from the lack of symbol exports in {CImg,gmic}.{h,cpp}. 2. It makes no provision for the exported library type; G'MIC can be built statically or dynamically. 3. In Windows, when built with MSVC, the kind of symbol export that gmic_core implies is only available with a static libgmic. To fix this, this commit augments G'MIC-Qt's `ENABLE_DYNAMIC_LINKING` handling with target detection code for the above described cases. In the case where a compatible library is not found, a fallback is specified that will build libgmic as a separate target, then make G'MIC-Qt link against it in order to mimic the requirements. If a suitable system library is found, we augment it with the gmic.cpp plugin to make the symbols visible at compile time.
amyspark
added a commit
to amyspark/gmic
that referenced
this pull request
Feb 20, 2023
PR c-koi/gmic-qt#172 is correct in that it is no longer possible to build without -Dgmic_core, due to G'MIC-Qt relying in now-private implementation details of G'MIC; namely, the extensions made in gmic.cpp to CImg. However, the solution chosen has significant shortcomings: 1. It blindly assumes that the consumed library has been built by a GCC-compatible compiler. This is easily inferred from the lack of symbol exports in {CImg,gmic}.{h,cpp}. 2. It makes no provision for the exported library type; G'MIC can be built statically or dynamically. 3. In Windows, when built with MSVC, the kind of symbol export that gmic_core implies is only available with a static libgmic. To fix this, this commit augments G'MIC-Qt's `ENABLE_DYNAMIC_LINKING` handling with target detection code for the above described cases. In the case where a compatible library is not found, a fallback is specified that will build libgmic as a separate target, then make G'MIC-Qt link against it in order to mimic the requirements. If a suitable system library is found, we augment it with the gmic.cpp plugin to make the symbols visible at compile time.
amyspark
added a commit
to amyspark/gmic-2
that referenced
this pull request
Feb 20, 2023
PR c-koi#172 is correct in that it is no longer possible to build without -Dgmic_core, due to G'MIC-Qt relying in now-private implementation details of G'MIC; namely, the extensions made in gmic.cpp to CImg. However, the solution chosen has significant shortcomings: 1. It blindly assumes that the consumed library has been built by a GCC-compatible compiler. This is easily inferred from the lack of symbol exports in {CImg,gmic}.{h,cpp}. 2. It makes no provision for the exported library type; G'MIC can be built statically or dynamically. 3. In Windows, when built with MSVC, the kind of symbol export that gmic_core implies is only available with a static libgmic. To fix this, this commit augments G'MIC-Qt's `ENABLE_DYNAMIC_LINKING` handling with target detection code for the above described cases. In the case where a compatible library is not found, a fallback is specified that will build libgmic as a separate target, then make G'MIC-Qt link against it in order to mimic the requirements. If a suitable system library is found, we augment it with the gmic.cpp plugin to make the symbols visible at compile time.
amyspark
added a commit
to amyspark/gmic
that referenced
this pull request
Feb 23, 2023
PR c-koi/gmic-qt#172 is correct in that it is no longer possible to build without -Dgmic_core, due to G'MIC-Qt relying in now-private implementation details of G'MIC; namely, the extensions made in gmic.cpp to CImg. However, the solution chosen has significant shortcomings: 1. It blindly assumes that the consumed library has been built by a GCC-compatible compiler. This is easily inferred from the lack of symbol exports in {CImg,gmic}.{h,cpp}. 2. It makes no provision for the exported library type; G'MIC can be built statically or dynamically. 3. In Windows, when built with MSVC, the kind of symbol export that gmic_core implies is only available with a static libgmic. To fix this, this commit augments G'MIC-Qt's `ENABLE_DYNAMIC_LINKING` handling with target detection code for the above described cases. In the case where a compatible library is not found, a fallback is specified that will build libgmic as a separate target, then make G'MIC-Qt link against it in order to mimic the requirements. If a suitable system library is found, we augment it with the gmic.cpp plugin to make the symbols visible at compile time.
amyspark
added a commit
to amyspark/gmic
that referenced
this pull request
Feb 23, 2023
PR c-koi/gmic-qt#172 is correct in that it is no longer possible to build without -Dgmic_core, due to G'MIC-Qt relying in now-private implementation details of G'MIC; namely, the extensions made in gmic.cpp to CImg. However, the solution chosen has significant shortcomings: 1. It blindly assumes that the consumed library has been built by a GCC-compatible compiler. This is easily inferred from the lack of symbol exports in {CImg,gmic}.{h,cpp}. 2. It makes no provision for the exported library type; G'MIC can be built statically or dynamically. 3. In Windows, when built with MSVC, the kind of symbol export that gmic_core implies is only available with a static libgmic. To fix this, this commit augments G'MIC-Qt's `ENABLE_DYNAMIC_LINKING` handling with target detection code for the above described cases. In the case where a compatible library is not found, a fallback is specified that will build libgmic as a separate target, then make G'MIC-Qt link against it in order to mimic the requirements. If a suitable system library is found, we augment it with the gmic.cpp plugin to make the symbols visible at compile time.
amyspark
added a commit
to amyspark/gmic
that referenced
this pull request
Feb 23, 2023
PR c-koi/gmic-qt#172 is correct in that it is no longer possible to build without -Dgmic_core, due to G'MIC-Qt relying in now-private implementation details of G'MIC; namely, the extensions made in gmic.cpp to CImg. However, the solution chosen has significant shortcomings: 1. It blindly assumes that the consumed library has been built by a GCC-compatible compiler. This is easily inferred from the lack of symbol exports in {CImg,gmic}.{h,cpp}. 2. It makes no provision for the exported library type; G'MIC can be built statically or dynamically. 3. In Windows, when built with MSVC, the kind of symbol export that gmic_core implies is only available with a static libgmic. To fix this, this commit augments G'MIC-Qt's `ENABLE_DYNAMIC_LINKING` handling with target detection code for the above described cases. In the case where a compatible library is not found, a fallback is specified that will build libgmic as a separate target, then make G'MIC-Qt link against it in order to mimic the requirements. If a suitable system library is found, we augment it with the gmic.cpp plugin to make the symbols visible at compile time.
amyspark
added a commit
to amyspark/gmic
that referenced
this pull request
Feb 23, 2023
PR c-koi/gmic-qt#172 is correct in that it is no longer possible to build without -Dgmic_core, due to G'MIC-Qt relying in now-private implementation details of G'MIC; namely, the extensions made in gmic.cpp to CImg. However, the solution chosen has significant shortcomings: 1. It blindly assumes that the consumed library has been built by a GCC-compatible compiler. This is easily inferred from the lack of symbol exports in {CImg,gmic}.{h,cpp}. 2. It makes no provision for the exported library type; G'MIC can be built statically or dynamically. 3. In Windows, when built with MSVC, the kind of symbol export that gmic_core implies is only available with a static libgmic. To fix this, this commit augments G'MIC-Qt's `ENABLE_DYNAMIC_LINKING` handling with target detection code for the above described cases. In the case where a compatible library is not found, a fallback is specified that will build libgmic as a separate target, then make G'MIC-Qt link against it in order to mimic the requirements. If a suitable system library is found, we augment it with the gmic.cpp plugin to make the symbols visible at compile time.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
It is no longer possible to build without "-Dgmic_core", so we enable it unconditionally.
Fixes #171