You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
--with-ssl=/nonexistent/path ignores specified path and builds against another SSL implementation #2580
I'm pretty sure this happens because the test for the ssl library still works because it finds a system one installed and uses that (in one of the default paths). So while a check for the dir existing would catch your specific case if you truly point to a missing directory, it would still work like this if you point to an empty directory...
@p You're not alone - we had a spelling error in the path; we ended up building against a very dated openssl. It took us a while to figure out where it went wrong.
I can't think of any easy ways to detect this. The linker has a default path that might make it find another library if the given path isn't working. To detect that, we have to add some custom logic that verifies the given path to make sure it actually contains a (working) openssl installation and that does feel very error-prone.
Or do you have any ideas on how this process could be improved?
Well, do we need to know it is a working installation in the specified directory? Wouldn't it be enough that we find at least the "entry header file" in the directory? If the user points to a broken installation, that'll likely become obvious at a later stage when it doesn't compile or otherwise breaks.
Other than that, I can only think of of documenting the possible pitfall.
Activity
bagder commentedon May 17, 2018
I'm pretty sure this happens because the test for the ssl library still works because it finds a system one installed and uses that (in one of the default paths). So while a check for the dir existing would catch your specific case if you truly point to a missing directory, it would still work like this if you point to an empty directory...
PerMalmberg commentedon May 23, 2018
@p You're not alone - we had a spelling error in the path; we ended up building against a very dated openssl. It took us a while to figure out where it went wrong.
bagder commentedon May 23, 2018
I can't think of any easy ways to detect this. The linker has a default path that might make it find another library if the given path isn't working. To detect that, we have to add some custom logic that verifies the given path to make sure it actually contains a (working) openssl installation and that does feel very error-prone.
Or do you have any ideas on how this process could be improved?
PerMalmberg commentedon May 23, 2018
Well, do we need to know it is a working installation in the specified directory? Wouldn't it be enough that we find at least the "entry header file" in the directory? If the user points to a broken installation, that'll likely become obvious at a later stage when it doesn't compile or otherwise breaks.
Other than that, I can only think of of documenting the possible pitfall.
bagder commentedon May 23, 2018
I like that. Simple and easy. Basically logic like this:
I'll put together a PR for it...
configure: add basic test of --with-ssl prefix
PerMalmberg commentedon May 23, 2018
That'll work splendidly, @bagder
p commentedon May 23, 2018
Seems reasonable, thanks!
bagder commentedon May 23, 2018
Thanks both of you!