Open
Conversation
655b473 to
e01726b
Compare
sbc100
commented
Dec 11, 2025
|
|
||
| set(CMAKE_CROSSCOMPILING TRUE) | ||
| set_property(GLOBAL PROPERTY TARGET_SUPPORTS_SHARED_LIBS FALSE) | ||
| set_property(GLOBAL PROPERTY TARGET_SUPPORTS_SHARED_LIBS TRUE) |
Collaborator
Author
There was a problem hiding this comment.
@bradking should I just delete line instead? (i.e. does this default to true?)
There was a problem hiding this comment.
Yes, the CMakeGenericSystem module initializes the property to TRUE. It doesn't need to be set here.
e01726b to
6e4f78f
Compare
This means that `-shared` will now produce a dynamic library by default. If you want the old behaviour you now need `-sFAKE_DYLIBS`.
6e4f78f to
3b0addc
Compare
kripken
reviewed
Dec 11, 2025
| to behave like :ref:`SIDE_MODULE` and produce and dynamically linked | ||
| library. | ||
| This setting changes the behaviour of the ``-shared`` flag. When set to true | ||
| you get the old emscripten behaivour where the ``-shared`` flag actually |
Member
There was a problem hiding this comment.
Suggested change
| you get the old emscripten behaivour where the ``-shared`` flag actually | |
| you get the old emscripten behaviour where the ``-shared`` flag actually |
| cmd.append(stub) | ||
|
|
||
| if not settings.FAKE_DYLIBS: | ||
| cmd.append('-Bdynamic') |
Member
There was a problem hiding this comment.
Before this was just for main module - why is it different?
Collaborator
Author
There was a problem hiding this comment.
Hmm.. yes I guess this part of the change would be removing the need for -sMAIN_MODULE (i.e. implicitly building a main module when dynamic libraries are present). Maybe that should be left for a followup.
dschuff
reviewed
Dec 13, 2025
|
|
||
| # Verify that building with -sSIDE_MODULE is essentailly the same as building with `-shared -fPIC -sFAKE_DYLIBS=0`. | ||
| flags = ['-shared', '-fPIC', '-sFAKE_DYLIBS=0'] | ||
| # Verify that building with -sSIDE_MODULE is essentailly the same as building with `-shared -fPIC` |
Member
There was a problem hiding this comment.
Suggested change
| # Verify that building with -sSIDE_MODULE is essentailly the same as building with `-shared -fPIC` | |
| # Verify that building with -sSIDE_MODULE is essentially the same as building with `-shared -fPIC` |
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
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.
This means that
-sharedwill now produce a dynamic library by default.If you want the old behaviour you now need
-sFAKE_DYLIBS.