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

Add option for position-independent code #18

Open
adepierre opened this issue Mar 4, 2021 · 0 comments
Open

Add option for position-independent code #18

adepierre opened this issue Mar 4, 2021 · 0 comments

Comments

@adepierre
Copy link

adepierre commented Mar 4, 2021

When we want to link a static library to a dynamic one, the static lib has to be compiled with -fPIC on non-windows platforms.

It would be great if this option was available. With cmake it's just a simple line for both ssl and crypto:

set_property(TARGET ssl PROPERTY POSITION_INDEPENDENT_CODE ON)

set_property(TARGET crypto PROPERTY POSITION_INDEPENDENT_CODE ON)

Would you like me to make a PR for this?

Edit : for people having the same problem, I ended up adding -DCMAKE_POSITION_INDEPENDENT_CODE=ON to the command line to set it without modifying the project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant