From 28f163f97afcff3bc28f13c70d9fee60139aeb68 Mon Sep 17 00:00:00 2001 From: Lorenz Stechauner Date: Mon, 3 May 2021 20:48:16 +0200 Subject: [PATCH] Added DEBIAN_OPTS --- Makefile | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index b623961..f6e8654 100644 --- a/Makefile +++ b/Makefile @@ -3,6 +3,8 @@ CFLAGS=-std=c11 -Wall INCLUDE=-lssl -lcrypto -lmagic -lz -lmaxminddb LIBS=src/lib/*.c +DEBIAN_OPTS=-D MAGIC_FILE="\"/usr/share/file/magic.mgc\"" -D PHP_FPM_SOCKET="\"/var/run/php/php7.3-fpm.sock\"" + packages: @echo "Installing packages..." sudo apt install gcc php-fpm libmagic-dev libssl-dev libmaxminddb-dev @@ -15,14 +17,12 @@ compile: @mkdir -p bin gcc $(LIBS) -o bin/libnecronda-server.so --shared -fPIC $(CFLAGS) $(INCLUDE) gcc src/necronda-server.c -o bin/necronda-server $(CFLAGS) $(INCLUDE) \ - -Lbin -lnecronda-server \ - -Wl,-rpath=$(shell pwd)/bin + -Lbin -lnecronda-server -Wl,-rpath=$(shell pwd)/bin compile-debian: @mkdir -p bin - gcc $(LIBS) -o bin/libnecronda-server.so --shared -fPIC $(CFLAGS) $(INCLUDE) + gcc $(LIBS) -o bin/libnecronda-server.so --shared -fPIC $(CFLAGS) $(INCLUDE) \ + $(DEBIAN_OPTS) gcc src/necronda-server.c -o bin/necronda-server $(CFLAGS) $(INCLUDE) \ - -Lbin -lnecronda-server \ - -Wl,-rpath=$(shell pwd)/bin \ - -D MAGIC_FILE="\"/usr/share/file/magic.mgc\"" \ - -D PHP_FPM_SOCKET="\"/var/run/php/php7.3-fpm.sock\"" + -Lbin -lnecronda-server -Wl,-rpath=$(shell pwd)/bin \ + $(DEBIAN_OPTS)