-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
New helper macro + fixes for old gcc #948
Conversation
cmake/TorchPackage.cmake
Outdated
endif() | ||
ELSE() | ||
IF (BUILD_STATIC OR "$ENV{TH_ONLY_STATIC}" STREQUAL "YES") | ||
ADD_LIBRARY(${package} ${type} "") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
isn't this missing a STATIC
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm it looks like I messed something up during rebasing. Let me double check this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, it isn't missing STATIC
, it is missing source files. It was a hacky way to "disable" dynamic builds, when only static versions were required, by creating a dummy .so
file.
I am going to remove this logic and update the PR.
@soumith Removed that code segment. The current behavior is similar to the current version in master where both static and dynamic libs are built when static builds are requested. If not only dynamic libs are built. |
if you rebase, i'll merge this. |
@soumith sorry about not getting back to this, I'll clean this up tomorrow. |
ADD_TORCH_LIBRARY
makes it easier to linklibTH
from various other packages.