summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorPeter Powell <petpow@saberuk.com>2013-04-02 16:30:11 +0100
committerPeter Powell <petpow@saberuk.com>2013-04-02 16:34:28 +0100
commit448c50fa4d344fb05a6ffdfec9a21d980ea3ab99 (patch)
treece7d139c4cd49ede4a4d851bab146be1b5c41a6c /configure
parent26e7bb0b9a17a595d9935a1cae41b44504ad213e (diff)
Extract SSL generation to a tool which can be shipped by distros.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure10
1 files changed, 4 insertions, 6 deletions
diff --git a/configure b/configure
index cd5cf4258..32ac8f40f 100755
--- a/configure
+++ b/configure
@@ -47,8 +47,6 @@ use Getopt::Long;
# Utility functions for our buildsystem
use make::utilities;
use make::configure;
-use make::gnutlscert;
-use make::opensslcert;
###############################################################################################
#
@@ -102,8 +100,8 @@ GetOptions (
'list-extras' => sub { list_extras; exit 0; }, # This, --enable-extras, and --disable-extras are for non-interactive managing.
'enable-extras=s@' => \@opt_enableextras, # ^
'disable-extras=s@' => \@opt_disableextras, # ^
- 'generate-openssl-cert' => sub { make_openssl_cert(); exit(0); },
- 'generate-gnutls-cert' => sub { make_gnutls_cert(); exit(0); }
+ 'generate-openssl-cert' => sub { exec './tools/genssl openssl'; },
+ 'generate-gnutls-cert' => sub { exec './tools/genssl gnutls'; }
);
if (scalar(@opt_enableextras) + scalar(@opt_disableextras) > 0) {
@@ -692,7 +690,7 @@ if ($config{USE_GNUTLS} eq "y") {
* few times and get that HD going :) Then answer the *
* Questions which follow. If you are unsure, just hit enter *
*************************************************************\n\n";
- $failed = make_gnutls_cert();
+ $failed = system "./tools/genssl gnutls";
if ($failed) {
print "\n\e[1;32mCertificate generation failed!\e[0m\n\n";
} else {
@@ -726,7 +724,7 @@ if ($config{USE_OPENSSL} eq "y") {
* Generating the certificates may take some time, go grab a *
* coffee, or something. *
*************************************************************\n\n";
- make_openssl_cert();
+ system "./tools/genssl openssl";
print "\nCertificate generation complete, copying to config directory... ";
File::Copy::move("key.pem", "$config{CONFIG_DIR}/key.pem") or print STDERR "Could not copy key.pem!\n";
File::Copy::move("cert.pem", "$config{CONFIG_DIR}/cert.pem") or print STDERR "Could not copy cert.pem!\n";