Makefile, configure: Add option for disabling generation of example certificates 0.9.2
authorKim Alvefur <zash@zash.se>
Sat, 30 Nov 2013 22:26:20 +0100
changeset 5933 56b1f151f4a3
parent 5930 a6a7839364aa
child 5934 4016e6efdcf6
Makefile, configure: Add option for disabling generation of example certificates
Makefile
configure
--- a/Makefile	Fri Nov 29 20:10:13 2013 +0000
+++ b/Makefile	Sat Nov 30 22:26:20 2013 +0100
@@ -17,7 +17,9 @@
 
 all: prosody.install prosodyctl.install prosody.cfg.lua.install prosody.version
 	$(MAKE) -C util-src install
-	$(MAKE) -C certs localhost.crt example.com.crt
+ifeq ($(EXCERTS),yes)
+	$(MAKE) -C certs localhost.crt example.com.crt || true
+endif
 
 install: prosody.install prosodyctl.install prosody.cfg.lua.install util/encodings.so util/encodings.so util/pposix.so util/signal.so
 	install -d $(BIN) $(CONFIG) $(MODULES) $(SOURCE)
--- a/configure	Fri Nov 29 20:10:13 2013 +0000
+++ b/configure	Sat Nov 30 22:26:20 2013 +0100
@@ -17,6 +17,7 @@
 CXX=g++
 LD=gcc
 RUNWITH=lua
+EXCERTS=yes
 
 CFLAGS="-fPIC -Wall"
 LDFLAGS="-shared"
@@ -64,6 +65,7 @@
                             Default is $LD
 --require-config            Will cause Prosody to refuse to run when
                             it fails to find a configuration file
+--no-example-certs          Disables generation of example certificates.
 EOF
 }
 
@@ -178,6 +180,9 @@
    --runwith=*)
       RUNWITH="$value"
       ;;
+    --no-example-certs)
+      EXCERTS=
+      ;;
    *)
       echo "Error: Unknown flag: $1"
       exit 1
@@ -349,6 +354,7 @@
 CXX=$CXX
 LD=$LD
 RUNWITH=$RUNWITH
+EXCERTS=$EXCERTS
 
 EOF