[packages/apache-mod_log_gelf: 2/2] update buildsystem to build

glen glen at pld-linux.org
Mon Jan 29 10:27:35 CET 2018


commit 59b3a41f12e24eaeeaa6baacf2a78f1ddcea8585
Author: Elan Ruusamäe <glen at pld-linux.org>
Date:   Mon Jan 29 11:26:44 2018 +0200

    update buildsystem to build
    
    https://github.com/graylog-labs/apache-mod_log_gelf/pull/12

 apache-mod_log_gelf.spec |  2 ++
 build.patch              | 69 ++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 71 insertions(+)
---
diff --git a/apache-mod_log_gelf.spec b/apache-mod_log_gelf.spec
index 1bb11f3..00b3c2d 100644
--- a/apache-mod_log_gelf.spec
+++ b/apache-mod_log_gelf.spec
@@ -9,6 +9,7 @@ Group:		Networking/Daemons/HTTP
 Source0:	https://github.com/graylog-labs/apache-mod_log_gelf/archive/%{version}/%{name}-%{version}.tar.gz
 # Source0-md5:	4aba4fd0f8e1175c39d4ac236282df10
 Source1:	apache.conf
+Patch0:		build.patch
 URL:		https://github.com/graylog-labs/apache-mod_log_gelf
 BuildRequires:	%{apxs}
 BuildRequires:	apache-devel >= 2.2
@@ -24,6 +25,7 @@ Apache2 module for writing access logs to Graylog.
 
 %prep
 %setup -q -n apache-mod_log_gelf-%{version}
+%patch0 -p1
 
 %build
 %{__make} -C src
diff --git a/build.patch b/build.patch
new file mode 100644
index 0000000..b20bb26
--- /dev/null
+++ b/build.patch
@@ -0,0 +1,69 @@
+From 747fe36fc7ef34b8dfe2196ebda5d189bbdbbe6e Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Elan=20Ruusam=C3=A4e?= <glen at pld-linux.org>
+Date: Mon, 29 Jan 2018 11:18:52 +0200
+Subject: [PATCH 1/2] use apxs to query apache install paths
+
+---
+ src/Makefile | 21 +++++++--------------
+ 1 file changed, 7 insertions(+), 14 deletions(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index 09b4871..0df88fb 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -1,15 +1,12 @@
+ builddir=.
+ 
+-ifneq (,$(wildcard /usr/share/apache2/build/special.mk))
+-  top_srcdir=/usr/share/apache2
+-  top_builddir=/usr/share/apache2
+-  include /usr/share/apache2/build/special.mk
+-endif
+-ifneq (,$(wildcard /usr/lib64/httpd/build/special.mk))
+-  top_srcdir=/etc/httpd
+-  top_builddir=/usr/lib64/httpd
+-  include /usr/lib64/httpd/build/special.mk
+-endif
++#   the used tools
++APXS=apxs
++APACHECTL=apachectl
++
++top_builddir=$(shell $(APXS) -q exp_libexecdir)
++include $(top_builddir)/build/special.mk
++
+ ifneq (,$(wildcard /etc/debian_version))
+   DISTRIBUTION := $(shell lsb_release -i | cut -f2)
+   ifeq ($(DISTRIBUTION),Debian)
+@@ -17,10 +14,6 @@ ifneq (,$(wildcard /etc/debian_version))
+   endif
+ endif
+ 
+-#   the used tools
+-APXS=apxs
+-APACHECTL=apachectl
+-
+ #   additional defines, includes and libraries
+ LIBS=-ljson-c -lz
+ 
+
+From b53dc3cc7530de656525ed2dfcd4a9fad1a131f4 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Elan=20Ruusam=C3=A4e?= <glen at pld-linux.org>
+Date: Mon, 29 Jan 2018 11:24:06 +0200
+Subject: [PATCH 2/2] assign top_srcdir for make install
+
+---
+ src/Makefile | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/Makefile b/src/Makefile
+index 0df88fb..63e130b 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -5,6 +5,7 @@ APXS=apxs
+ APACHECTL=apachectl
+ 
+ top_builddir=$(shell $(APXS) -q exp_libexecdir)
++top_srcdir=$(top_builddir)
+ include $(top_builddir)/build/special.mk
+ 
+ ifneq (,$(wildcard /etc/debian_version))
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/apache-mod_log_gelf.git/commitdiff/59b3a41f12e24eaeeaa6baacf2a78f1ddcea8585



More information about the pld-cvs-commit mailing list