]> git.ipfire.org Git - ipfire-2.x.git/blame - lfs/freeradius
Revert "client175: Convert python2 modules in source tarball to python3"
[ipfire-2.x.git] / lfs / freeradius
CommitLineData
71f578bb
MT
1###############################################################################
2# #
3# IPFire.org - A linux based firewall #
aafdd71b 4# Copyright (C) 2007-2021 IPFire Team <info@ipfire.org> #
71f578bb
MT
5# #
6# This program is free software: you can redistribute it and/or modify #
7# it under the terms of the GNU General Public License as published by #
8# the Free Software Foundation, either version 3 of the License, or #
9# (at your option) any later version. #
10# #
11# This program is distributed in the hope that it will be useful, #
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 #
17# along with this program. If not, see <http://www.gnu.org/licenses/>. #
18# #
19###############################################################################
20
21###############################################################################
22# Definitions
23###############################################################################
24
25include Config
26
22a6277f 27VER = 3.0.21
71f578bb
MT
28
29THISAPP = freeradius-server-$(VER)
22a6277f 30DL_FILE = $(THISAPP).tar.bz2
71f578bb
MT
31DL_FROM = $(URL_IPFIRE)
32DIR_APP = $(DIR_SRC)/$(THISAPP)
33TARGET = $(DIR_INFO)/$(THISAPP)
34PROG = freeradius
2cb220fd 35PAK_VER = 13
71f578bb 36
2cb220fd 37DEPS = libtalloc samba
71f578bb
MT
38
39###############################################################################
40# Top-level Rules
41###############################################################################
42
43objects = $(DL_FILE)
44
45$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
46
22a6277f 47$(DL_FILE)_MD5 = 8b7f794f2ac0d686d9aecfa083a63614
71f578bb
MT
48
49install : $(TARGET)
50
51check : $(patsubst %,$(DIR_CHK)/%,$(objects))
52
53download :$(patsubst %,$(DIR_DL)/%,$(objects))
54
55md5 : $(subst %,%_MD5,$(objects))
56
57dist:
58 @$(PAK)
59
60###############################################################################
61# Downloading, checking, md5sum
62###############################################################################
63
64$(patsubst %,$(DIR_CHK)/%,$(objects)) :
65 @$(CHECK)
66
67$(patsubst %,$(DIR_DL)/%,$(objects)) :
68 @$(LOAD)
69
70$(subst %,%_MD5,$(objects)) :
71 @$(MD5)
72
73###############################################################################
74# Installation Details
75###############################################################################
76
77$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
78 @$(PREBUILD)
e301592f 79 @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
6580bdeb 80 cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/freeradius-no-buildtime-cert-gen.patch
3850e662 81 $(UPDATE_AUTOMAKE)
71f578bb
MT
82 cd $(DIR_APP) && \
83 ./configure \
84 --prefix=/usr \
85 --sysconfdir=/etc \
86 --libdir=/usr/lib/freeradius \
87 --localstatedir=/var \
88 --with-system-libtool \
89 --with-threads \
90 --with-thread-pool \
91 --disable-ltdl-install \
cf572f20 92 --disable-openssl-version-check \
71f578bb
MT
93 --without-rlm_eap_ikev2 \
94 --without-rlm_sql_iodbc \
95 --without-rlm_sql_firebird \
96 --without-rlm_sql_db2 \
97 --without-rlm_sql_oracle \
98 --without-rlm_sql_sqlite \
94f89b82
MT
99 --without-rlm_sql_mysql \
100 LDFLAGS="$(LDFLAGS)"
101
71f578bb
MT
102 cd $(DIR_APP) && make $(MAKETUNING)
103 cd $(DIR_APP) && make install
104
105 sed -i /etc/raddb/radiusd.conf \
106 -e "s/^#user =.*$$/user = nobody/" \
107 -e "s/^#group =.*$$/group = nobody/"
108
109 rm -rvf \
110 /root/.rnd \
111 /var/run/radiusd \
112 /etc/raddb/certs/*.crt \
113 /etc/raddb/certs/*.csr \
114 /etc/raddb/certs/*.der \
115 /etc/raddb/certs/*.key \
116 /etc/raddb/certs/*.pem \
117 /etc/raddb/certs/*.p12 \
118 /etc/raddb/certs/index.* \
119 /etc/raddb/certs/serial* \
120 /etc/raddb/certs/dh \
121 /etc/raddb/certs/random \
122 /usr/sbin/rc.radiusd \
123 /usr/bin/rbmonkey \
124 /etc/raddb/mods-config/sql/main/mssql \
125 /etc/raddb/mods-config/sql/ippool/oracle \
126 /etc/raddb/mods-config/sql/ippool-dhcp/oracle \
127 /etc/raddb/mods-config/sql/main/oracle \
128 /etc/raddb/mods-available/unbound \
129 /etc/raddb/mods-config/unbound/default.conf \
130 /etc/raddb/mods-available/couchbase \
131 /etc/raddb/mods-available/abfab* \
132 /etc/raddb/policy.d/abfab* \
133 /etc/raddb/sites-available/abfab* \
134 /usr/lib/freeradius/rlm_test.so \
135 /etc/raddb/experimental.conf
136
137 install -v -m 644 $(DIR_SRC)/config/backup/includes/freeradius \
138 /var/ipfire/backup/addons/includes/freeradius
139
84d5f2fa
MT
140 # Logrotate
141 -mkdir -pv /etc/logrotate.d
142 install -v -m 644 $(DIR_SRC)/config/freeradius/logrotate \
143 /etc/logrotate.d/freeradius
144
dbb35fa6
JS
145 #install initscripts
146 $(call INSTALL_INITSCRIPT,freeradius)
147
71f578bb
MT
148 @rm -rf $(DIR_APP)
149 @$(POSTBUILD)