4 # The contents of this file are subject to the terms of the
5 # Common Development and Distribution License (the "License").
6 # You may not use this file except in compliance with the License.
8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 # or http://www.opensolaris.org/os/licensing.
10 # See the License for the specific language governing permissions
11 # and limitations under the License.
13 # When distributing Covered Code, include this CDDL HEADER in each
14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 # If applicable, add the following below this CDDL HEADER, with the
16 # fields enclosed by brackets "[]" replaced with your own identifying
17 # information: Portions Copyright [yyyy] [name of copyright owner]
21 # Copyright (c) 2024, Friedrich Kink
24 include ..
/..
/..
/make-rules
/shared-macros.mk
26 COMPONENT_NAME
= freeradius
27 COMPONENT_VERSION
= 3.2.6
28 COMPONENT_VERSION_
= $(subst .
,_
,$(COMPONENT_VERSION
))
29 COMPONENT_SUMMARY
= The FreeRADIUS server
30 COMPONENT_DESCRIPTION
= The FreeRADIUS Server Project is a high performance and highly \
31 configurable multi-protocol policy server
, supporting RADIUS
, DHCPv4 DHCPv6
, DNS
, \
32 TACACS
+ and VMPS. Using RADIUS allows authentication and authorization for a \
33 network to be centralized
, and minimizes the number of changes that have to be \
34 done when adding or deleting new users to a network.
35 COMPONENT_SRC
= $(COMPONENT_NAME
)-server-release_
$(COMPONENT_VERSION_
)
36 COMPONENT_ARCHIVE
= $(COMPONENT_SRC
).
tar.gz
37 COMPONENT_PROJECT_URL
= https
://freeradius.org
/
38 COMPONENT_ARCHIVE_URL
= https
://github.com
/FreeRADIUS
/freeradius-server
/archive
/refs
/tags/release_
$(COMPONENT_VERSION_
).
tar.gz
39 COMPONENT_ARCHIVE_HASH
= sha256
:65e099edf5d72ac2f9f7198c800cf0199544f974aae13c93908ab739815b9625
40 COMPONENT_FMRI
= network
/radius
41 COMPONENT_CLASSIFICATION
= Applications
/Internet
42 COMPONENT_LICENSE
= GPLv2
43 COMPONENT_LICENSE_FILE
= LICENSE
45 TEST_TARGET
= $(NO_TESTS
)
46 include $(WS_MAKE_RULES
)/common.mk
48 COMPONENT_PRE_CONFIGURE_ACTION
+= ( \
49 $(CLONEY
) $(SOURCE_DIR
) $(@D
); \
50 $(GSED
) -i
-e
's/-D_LIBRADIUS/-D_LIBRADIUS -D_XPG4_2/' $(@D
)/src
/lib
/all.mk
; );
54 CONFIGURE_OPTIONS
+= CFLAGS
="-I/usr/include/odbc"
55 CONFIGURE_OPTIONS
+= LDFLAGS
="-lldap_r"
56 CONFIGURE_OPTIONS
+= --srcdir=$(BUILD_DIR
)/$(MACH64
)
57 CONFIGURE_OPTIONS
+= --sysconfdir
=$(ETCDIR
)
58 CONFIGURE_OPTIONS
+= --localstatedir
=$(VARDIR
)
59 CONFIGURE_OPTIONS
+= --with-pcap-lib-dir
=$(USRLIBDIR
)
60 CONFIGURE_OPTIONS
+= --with-pcap-include-dir
=/usr
/include/pcap
61 CONFIGURE_OPTIONS
+= --with-rlm-ldap-include-dir
=/usr
/include/openldap
62 CONFIGURE_OPTIONS
+= --with-rlm-sql_postgresql-include-dir
=/usr
/postgres
/$(PG_VERSION
)/include
63 CONFIGURE_OPTIONS
+= --with-openssl-lib-dir
=$(OPENSSL_LIBDIR
)
64 CONFIGURE_OPTIONS
+= --with-openssl-include-dir
=$(OPENSSL_INCDIR
)
65 CONFIGURE_OPTIONS
+= --without-static-modules
67 COMPONENT_INSTALL_ARGS
+= R
=$(PROTO_DIR
)
68 COMPONENT_POST_INSTALL_ACTION
= \
69 $(CP
) $(SOURCE_DIR
)/raddb
/mods-config
/attr_filter
/* $(PROTOETCDIR
)/raddb
/mods-config
/attr_filter
; \
70 $(CP
) $(SOURCE_DIR
)/raddb
/mods-config
/files
/* $(PROTOETCDIR
)/raddb
/mods-config
/files
; \
71 $(CP
) $(SOURCE_DIR
)/raddb
/policy.d
/* $(PROTOETCDIR
)/raddb
/policy.d
; \
72 /usr
/bin
/elfedit
-e
'dyn:value -s RUNPATH "$(MYSQL_LIBDIR)"' $(PROTOUSRLIBDIR64
)/rlm_sql_mysql.so
; \
73 /usr
/bin
/elfedit
-e
'dyn:value -s RPATH "$(MYSQL_LIBDIR)"' $(PROTOUSRLIBDIR64
)/rlm_sql_mysql.so
; \
74 /usr
/bin
/elfedit
-e
'dyn:value -s RUNPATH "$(GCC_LIBDIR)"' $(PROTOUSRLIBDIR64
)/rlm_sql_unixodbc.so
; \
75 /usr
/bin
/elfedit
-e
'dyn:value -s RPATH "$(GCC_LIBDIR)"' $(PROTOUSRLIBDIR64
)/rlm_sql_unixodbc.so
; \
76 /usr
/bin
/elfedit
-e
'dyn:value -s RUNPATH "$(PG_LIBDIR)"' $(PROTOUSRLIBDIR64
)/rlm_sql_postgresql.so
; \
77 /usr
/bin
/elfedit
-e
'dyn:value -s RPATH "$(PG_LIBDIR)"' $(PROTOUSRLIBDIR64
)/rlm_sql_postgresql.so
; \
78 /usr
/bin
/elfedit
-e
'dyn:delete NEEDED' $(PROTOUSRLIBDIR64
)/rlm_python.so
; \
79 /usr
/bin
/elfedit
-e
'dyn:value -s NEEDED "libpython$(PYTHON_VERSION).so.1.0"' $(PROTOUSRLIBDIR64
)/rlm_python.so
; \
80 /usr
/bin
/elfedit
-e
'dyn:value -s RUNPATH "$(GCC_LIBDIR):$(USRLIBDIR)/python$(PYTHON_VERSION)/config-$(PYTHON_VERSION)"' $(PROTOUSRLIBDIR64
)/rlm_python.so
; \
81 /usr
/bin
/elfedit
-e
'dyn:value -s RPATH "$(GCC_LIBDIR):$(USRLIBDIR)/python$(PYTHON_VERSION)/config-$(PYTHON_VERSION)"' $(PROTOUSRLIBDIR64
)/rlm_python.so
;
83 # Manually added build dependencies
84 REQUIRED_PACKAGES
+= $(PG_DEVELOPER_PKG
)
86 # Auto-generated dependencies
87 PERL_REQUIRED_PACKAGES
+= runtime
/perl
88 PYTHON_REQUIRED_PACKAGES
+= runtime
/python
89 REQUIRED_PACKAGES
+= $(MYSQL_LIBRARY_PKG
)
90 REQUIRED_PACKAGES
+= $(OPENSSL_PKG
)
91 REQUIRED_PACKAGES
+= $(PG_LIBRARY_PKG
)
92 REQUIRED_PACKAGES
+= $(READLINE_PKG
)
93 REQUIRED_PACKAGES
+= SUNWcs
94 REQUIRED_PACKAGES
+= database
/sqlite-3
95 REQUIRED_PACKAGES
+= library
/database
/gdbm
96 REQUIRED_PACKAGES
+= library
/freetds
97 REQUIRED_PACKAGES
+= library
/json-c
98 REQUIRED_PACKAGES
+= library
/libmemcached
99 REQUIRED_PACKAGES
+= library
/openldap
100 REQUIRED_PACKAGES
+= library
/talloc
101 REQUIRED_PACKAGES
+= library
/unixodbc
102 REQUIRED_PACKAGES
+= runtime
/perl
103 REQUIRED_PACKAGES
+= service
/network
/unbound
104 REQUIRED_PACKAGES
+= service
/security
/kerberos-5
105 REQUIRED_PACKAGES
+= shell/ksh93
106 REQUIRED_PACKAGES
+= system
/library
107 REQUIRED_PACKAGES
+= system
/library
/libpcap
108 REQUIRED_PACKAGES
+= web
/curl