{"action":"closed","issue":{"url":"https://api.github.com/repos/libressl-portable/portable/issues/160","labels_url":"https://api.github.com/repos/libressl-portable/portable/issues/160/labels{/name}","comments_url":"https://api.github.com/repos/libressl-portable/portable/issues/160/comments","events_url":"https://api.github.com/repos/libressl-portable/portable/issues/160/events","html_url":"https://github.com/libressl-portable/portable/issues/160","id":115558069,"number":160,"title":"libtls: override _PATH_SSL_CA_FILE at compile time","user":{"login":"equalsraf","id":715238,"avatar_url":"https://avatars.githubusercontent.com/u/715238?v=3","gravatar_id":"","url":"https://api.github.com/users/equalsraf","html_url":"https://github.com/equalsraf","followers_url":"https://api.github.com/users/equalsraf/followers","following_url":"https://api.github.com/users/equalsraf/following{/other_user}","gists_url":"https://api.github.com/users/equalsraf/gists{/gist_id}","starred_url":"https://api.github.com/users/equalsraf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/equalsraf/subscriptions","organizations_url":"https://api.github.com/users/equalsraf/orgs","repos_url":"https://api.github.com/users/equalsraf/repos","events_url":"https://api.github.com/users/equalsraf/events{/privacy}","received_events_url":"https://api.github.com/users/equalsraf/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-06T18:10:38Z","updated_at":"2015-12-07T02:58:04Z","closed_at":"2015-12-07T02:58:04Z","body":"Cheers, I'm using libtls in systems where the CA certificate bundle is not installed in /etc/ssl/cert.pem (Linux-SuSe, Windows), the default value is defined in tls_internal.h as _PATH_SSL_CA_FILE.\r\n\r\nAny chance we can get a way to override this default at compile time? Right now we can't even override it using CFLAGS because the #define is unguarded, a small patch\r\n\r\n```diff\r\ndiff --git a/src/lib/libtls/tls_internal.h b/src/lib/libtls/tls_internal.h\r\nindex e21989c..2ce92f3 100644\r\n--- a/src/lib/libtls/tls_internal.h\r\n+++ b/src/lib/libtls/tls_internal.h\r\n@@ -24,7 +24,9 @@\r\n \r\n #include <openssl/ssl.h>\r\n \r\n-#define _PATH_SSL_CA_FILE \"/etc/ssl/cert.pem\"\r\n+#ifndef _PATH_SSL_CA_FILE\r\n+# define _PATH_SSL_CA_FILE \"/etc/ssl/cert.pem\"\r\n+#endif\r\n```\r\n\r\nwould enable the use of `make CFLAGS='-D_PATH_SSL_CA_FILE=\\\"/etc/ssl/ca-bundle.pem\\\"'`.\r\n\r\nAlso shouldn't the default value use OPENSSLDIR?"}}