]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blame - lfs/apache2
suricata: Change midstream policy to "pass-flow"
[people/pmueller/ipfire-2.x.git] / lfs / apache2
CommitLineData
7b6b8153 1###############################################################################
7b6b8153 2# #
70df8302 3# IPFire.org - A linux based firewall #
ca92e035 4# Copyright (C) 2007-2023 IPFire Team <info@ipfire.org> #
70df8302
MT
5# #
6# This program is free software: you can redistribute it and/or modify #
7b6b8153 7# it under the terms of the GNU General Public License as published by #
70df8302 8# the Free Software Foundation, either version 3 of the License, or #
7b6b8153
MT
9# (at your option) any later version. #
10# #
70df8302 11# This program is distributed in the hope that it will be useful, #
7b6b8153
MT
12# but WITHOUT ANY WARRANTY; without even the implied warranty of #
13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
14# GNU General Public License for more details. #
15# #
16# You should have received a copy of the GNU General Public License #
70df8302 17# along with this program. If not, see <http://www.gnu.org/licenses/>. #
7b6b8153
MT
18# #
19###############################################################################
20
70df8302 21
7b6b8153
MT
22###############################################################################
23# Definitions
24###############################################################################
25
26include Config
27
5049433d 28VER = 2.4.58
7b6b8153
MT
29
30THISAPP = httpd-$(VER)
31DL_FILE = $(THISAPP).tar.bz2
05188498 32DL_FROM = $(URL_IPFIRE)
d41fe99f 33
7b6b8153 34DIR_APP = $(DIR_SRC)/$(THISAPP)
afdf1483
MT
35
36TARGET = $(DIR_INFO)/$(THISAPP)
7b6b8153 37
2dc2a278 38DEPS = aprutil pcre
d41fe99f 39
7b6b8153
MT
40###############################################################################
41# Top-level Rules
42###############################################################################
43
b9863c88 44objects = $(DL_FILE)
7b6b8153
MT
45
46$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
7b6b8153 47
5049433d 48$(DL_FILE)_BLAKE2 = 2105b8fada99f1dda55201ed89ed5326f0edb078d352cbff44f02cde80d129b65b63e07366a9a744ba474be5687fa8d3d2d8ddc64ac914b47166607f3f4a9de2
7b6b8153
MT
49
50install : $(TARGET)
51
52check : $(patsubst %,$(DIR_CHK)/%,$(objects))
53
54download :$(patsubst %,$(DIR_DL)/%,$(objects))
55
9a7e4d85 56b2 : $(subst %,%_BLAKE2,$(objects))
7b6b8153 57
7b6b8153 58###############################################################################
9a7e4d85 59# Downloading, checking, b2sum
7b6b8153
MT
60###############################################################################
61
62$(patsubst %,$(DIR_CHK)/%,$(objects)) :
63 @$(CHECK)
64
65$(patsubst %,$(DIR_DL)/%,$(objects)) :
66 @$(LOAD)
67
9a7e4d85
PM
68$(subst %,%_BLAKE2,$(objects)) :
69 @$(B2SUM)
7b6b8153
MT
70
71###############################################################################
72# Installation Details
73###############################################################################
74
75$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
76 @$(PREBUILD)
77 @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar jxf $(DIR_DL)/$(DL_FILE)
4fc6f9cb 78 cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/apache-2.4.58_mod_xml2enc_remove_dependency_on_xmlstring_header.patch
a6b08d93
MT
79 ### Add IPFire's layout, too
80 echo "# IPFire layout" >> $(DIR_APP)/config.layout
81 echo "<Layout IPFire>" >> $(DIR_APP)/config.layout
82 echo " prefix: /usr" >> $(DIR_APP)/config.layout
83 echo " exec_prefix: /usr" >> $(DIR_APP)/config.layout
84 echo " bindir: /usr/bin" >> $(DIR_APP)/config.layout
85 echo " sbindir: /usr/sbin" >> $(DIR_APP)/config.layout
86 echo " libdir: /usr/lib" >> $(DIR_APP)/config.layout
87 echo " libexecdir: /usr/lib/apache" >> $(DIR_APP)/config.layout
88 echo " mandir: /usr/share/man" >> $(DIR_APP)/config.layout
89 echo " sysconfdir: /etc/httpd/conf" >> $(DIR_APP)/config.layout
d733119b 90 echo " datadir: /srv/web/ipfire" >> $(DIR_APP)/config.layout
a6b08d93 91 echo " installbuilddir: /usr/lib/apache/build" >> $(DIR_APP)/config.layout
d733119b
MT
92 echo " errordir: /srv/web/ipfire/error" >> $(DIR_APP)/config.layout
93 echo " iconsdir: /srv/web/ipfire/icons" >> $(DIR_APP)/config.layout
94 echo " htdocsdir: /srv/web/ipfire/htdocs" >> $(DIR_APP)/config.layout
95 echo " manualdir: /srv/web/ipfire/manual" >> $(DIR_APP)/config.layout
96 echo " cgidir: /srv/web/ipfire/cgi-bin" >> $(DIR_APP)/config.layout
a6b08d93 97 echo " includedir: /usr/include/apache" >> $(DIR_APP)/config.layout
d733119b 98 echo " localstatedir: /srv/web/ipfire" >> $(DIR_APP)/config.layout
a6b08d93
MT
99 echo " runtimedir: /var/run" >> $(DIR_APP)/config.layout
100 echo " logfiledir: /var/log/httpd" >> $(DIR_APP)/config.layout
101 echo " proxycachedir: /var/cache/apache/proxy" >> $(DIR_APP)/config.layout
102 echo "</Layout>" >> $(DIR_APP)/config.layout
103
104 cd $(DIR_APP) && ./configure --enable-layout=IPFire \
33f7d610 105 --enable-ssl --enable-mods-shared=all --enable-proxy --with-mpm=event --disable-lua --disable-md
c8ead4a5 106 cd $(DIR_APP) && make $(MAKETUNING)
7b6b8153
MT
107 cd $(DIR_APP) && make install
108 chown -v root:root /usr/lib/apache/httpd.exp \
d41fe99f
WA
109 /usr/bin/{apxs,dbmmanage} \
110 /usr/sbin/apachectl \
111 /usr/share/man/man1/{ab,apxs,dbmmanage,ht{dbm,digest,passwd,txt2dbm},logresolve}.1 \
112 /usr/share/man/man8/{apachectl,htcacheclean,httpd}.8 \
113 /usr/share/man/man8/{rotatelogs,suexec}.8
afdf1483
MT
114
115 # Install apache config
116 cp -rf $(DIR_CONF)/httpd/* /etc/httpd/conf
6723afef 117 touch /etc/httpd/conf/hostname.conf
afdf1483 118
22ce4c3a
MT
119 # Create captive logging directory
120 -mkdir -pv /var/log/httpd/captive
1fc9a430 121
7b6b8153
MT
122 @rm -rf $(DIR_APP)
123 @$(POSTBUILD)