move into submenus
[openwrt/svn-archive/archive.git] / net / freeradius / Makefile
index 0d0e964f4c35aecd51410c93a430bc3f73cde3a1..2d659375a2cc2471285c929b39bd91c4364eaeff 100644 (file)
@@ -22,70 +22,6 @@ PKG_CAT:=zcat
 
 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
 
-PKG_CONFIGURE_OPTIONS := \
-       --enable-shared \
-       --disable-static \
-       --disable-ltdl-install \
-       --with-ltdl-include="$(STAGING_DIR)/usr/include" \
-       --with-ltdl-lib="$(STAGING_DIR)/usr/lib" \
-       --with-openssl-includes="$(STAGING_DIR)/usr/include" \
-       --with-openssl-libraries="$(STAGING_DIR)/usr/lib" \
-       --enable-strict-dependencies \
-       --with-raddbdir=/etc/freeradius \
-       --without-edir \
-       --without-snmp \
-       --with-experimental-modules \
-       --without-rlm_attr-rewrite \
-       --without-rlm_checkval \
-       --without-rlm_counter \
-       --without-rlm_dbm \
-       --with-rlm_eap \
-       --without-rlm_eap_sim \
-       --without-rlm_example \
-       --without-rlm_ippool \
-       --without-rlm_krb5 \
-       --without-rlm_otp \
-       --without-rlm_pam \
-       --without-rlm_perl \
-       --without-rlm_python \
-       --without-rlm_radutmp \
-       --without-rlm_smb \
-       --with-rlm_sql \
-       --with-rlm_sqlcounter \
-       --without-rlm_sql_db2 \
-       --without-rlm_sql_freetds \
-       --without-rlm_sql_iodbc \
-       --without-rlm_sql_oracle \
-       --without-rlm_sql_sybase \
-       --without-rlm_sql_unixodbc \
-       --without-rlm_sql_log \
-       --without-rlm_unix \
-
-ifneq ($(CONFIG_PACKAGE_freeradius-mod-ldap),)
-PKG_CONFIGURE_LIBS += -lcrypto -lssl
-PKG_CONFIGURE_OPTIONS += \
-       --with-rlm_ldap-include-dir="$(STAGING_DIR)/usr/include" \
-       --with-rlm_ldap-lib-dir="$(STAGING_DIR)/usr/lib"
-else
-PKG_CONFIGURE_OPTIONS += --without-rlm_ldap
-endif
-ifneq ($(CONFIG_PACKAGE_freeradius-mod-sql-mysql),)
-PKG_CONFIGURE_LIBS += -lz
-PKG_CONFIGURE_OPTIONS += \
-       --with-mysql-include-dir="$(STAGING_DIR)/usr/include" \
-       --with-mysql-lib-dir="$(STAGING_DIR)/usr/lib/mysql" \
-       --without-threads
-else
-PKG_CONFIGURE_OPTIONS += --without-rlm_sql_mysql
-endif
-ifneq ($(CONFIG_PACKAGE_freeradius-mod-sql-pgsql),)
-PKG_CONFIGURE_OPTIONS += \
-       --with-rlm_sql_postgresql-include-dir="$(STAGING_DIR)/usr/include" \
-       --with-rlm_sql_postgresql-lib-dir="$(STAGING_DIR)/usr/lib"
-else
-PKG_CONFIGURE_OPTIONS += --without-rlm_sql_postgresql
-endif
-
 include $(INCLUDE_DIR)/package.mk
 
 define Package/freeradius
@@ -94,6 +30,7 @@ define Package/freeradius
   DEPENDS:=+libltdl +libopenssl +libpthread
   TITLE:=A flexible RADIUS server
   URL:=http://www.freeradius.org/
+  MENU:=1
 endef
 
 define Package/freeradius/conffiles
@@ -105,18 +42,21 @@ define Package/freeradius-democerts
   $(call Package/freeradius)
   DEPENDS:=freeradius
   TITLE:=Demo certificates to test the server
+  MENU:=0
 endef
 
 define Package/freeradius-mod-chap
   $(call Package/freeradius)
   DEPENDS:=freeradius
   TITLE:=CHAP module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-detail
   $(call Package/freeradius)
   DEPENDS:=freeradius
   TITLE:=Detailed accounting module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-eap
@@ -133,24 +73,28 @@ define Package/freeradius-mod-eap-gtc
   $(call Package/freeradius)
   DEPENDS:=freeradius-mod-eap
   TITLE:=EAP/GTC module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-eap-md5
   $(call Package/freeradius)
   DEPENDS:=freeradius-mod-eap
   TITLE:=EAP/MD5 module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-eap-mschapv2
   $(call Package/freeradius)
   DEPENDS:=freeradius-mod-eap
   TITLE:=EAP/MS-CHAPv2 module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-eap-peap
   $(call Package/freeradius)
   DEPENDS:=freeradius-mod-eap
   TITLE:=EAP/PEAP module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-eap-tls
@@ -163,12 +107,14 @@ define Package/freeradius-mod-eap-ttls
   $(call Package/freeradius)
   DEPENDS:=freeradius-mod-eap-tls
   TITLE:=EAP/TTLS module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-files
   $(call Package/freeradius)
   DEPENDS:=freeradius
   TITLE:=Module using local files for authorization
+  MENU:=0
 endef
 
 define Package/freeradius-mod-files/conffiles
@@ -181,6 +127,7 @@ define Package/freeradius-mod-ldap
   $(call Package/freeradius)
   DEPENDS:=freeradius +libopenldap
   TITLE:=LDAP module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-ldap/conffiles
@@ -191,18 +138,21 @@ define Package/freeradius-mod-mschap
   $(call Package/freeradius)
   DEPENDS:=freeradius
   TITLE:=MS-CHAP and MS-CHAPv2 module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-pap
   $(call Package/freeradius)
   DEPENDS:=freeradius
   TITLE:=PAP module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-preprocess
   $(call Package/freeradius)
   DEPENDS:=freeradius
   TITLE:=Request pre-processing module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-preprocess/conffiles
@@ -214,6 +164,7 @@ define Package/freeradius-mod-realm
   $(call Package/freeradius)
   DEPENDS:=freeradius
   TITLE:=Realms handling module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-realm/conffiles
@@ -230,26 +181,106 @@ define Package/freeradius-mod-sql-mysql
   $(call Package/freeradius)
   DEPENDS:=freeradius-mod-sql +libmysqlclient
   TITLE:=MySQL module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-sql-pgsql
   $(call Package/freeradius)
   DEPENDS:=freeradius-mod-sql +libpq
   TITLE:=PostgreSQL module
+  MENU:=0
 endef
 
 define Package/freeradius-mod-sqlcounter
   $(call Package/freeradius)
   DEPENDS:=freeradius-mod-sql
   TITLE:=Generic SQL Counter module
+  MENU:=0
 endef
 
 define Package/freeradius-utils
   $(call Package/freeradius)
   DEPENDS:=freeradius
   TITLE:=Misc. client utilities
+  MENU:=0
 endef
 
+PKG_CONFIGURE_OPTIONS := \
+       --enable-shared \
+       --disable-static \
+       --disable-ltdl-install \
+       --with-ltdl-include="$(STAGING_DIR)/usr/include" \
+       --with-ltdl-lib="$(STAGING_DIR)/usr/lib" \
+       --with-openssl-includes="$(STAGING_DIR)/usr/include" \
+       --with-openssl-libraries="$(STAGING_DIR)/usr/lib" \
+       --enable-strict-dependencies \
+       --with-raddbdir=/etc/freeradius \
+       --without-edir \
+       --without-snmp \
+       --with-experimental-modules \
+       --without-rlm_attr-rewrite \
+       --without-rlm_checkval \
+       --without-rlm_counter \
+       --without-rlm_dbm \
+       --with-rlm_eap \
+       --without-rlm_eap_sim \
+       --without-rlm_example \
+       --without-rlm_ippool \
+       --without-rlm_krb5 \
+       --without-rlm_otp \
+       --without-rlm_pam \
+       --without-rlm_perl \
+       --without-rlm_python \
+       --without-rlm_radutmp \
+       --without-rlm_smb \
+       --with-rlm_sql \
+       --with-rlm_sqlcounter \
+       --without-rlm_sql_db2 \
+       --without-rlm_sql_freetds \
+       --without-rlm_sql_iodbc \
+       --without-rlm_sql_oracle \
+       --without-rlm_sql_sybase \
+       --without-rlm_sql_unixodbc \
+       --without-rlm_sql_log \
+       --without-rlm_unix \
+
+ifeq ($(SDK),)
+  ifneq ($(CONFIG_PACKAGE_freeradius-mod-ldap),)
+    PKG_CONFIGURE_LIBS += -lcrypto -lssl
+    PKG_CONFIGURE_OPTIONS += \
+               --with-rlm_ldap-include-dir="$(STAGING_DIR)/usr/include" \
+               --with-rlm_ldap-lib-dir="$(STAGING_DIR)/usr/lib"
+  else
+    PKG_CONFIGURE_OPTIONS += --without-rlm_ldap
+  endif
+  ifneq ($(CONFIG_PACKAGE_freeradius-mod-sql-mysql),)
+    PKG_CONFIGURE_LIBS += -lz
+    PKG_CONFIGURE_OPTIONS += \
+               --with-mysql-include-dir="$(STAGING_DIR)/usr/include" \
+               --with-mysql-lib-dir="$(STAGING_DIR)/usr/lib/mysql" \
+               --without-threads
+  else
+    PKG_CONFIGURE_OPTIONS += --without-rlm_sql_mysql
+  endif
+  ifneq ($(CONFIG_PACKAGE_freeradius-mod-sql-pgsql),)
+    PKG_CONFIGURE_OPTIONS += \
+               --with-rlm_sql_postgresql-include-dir="$(STAGING_DIR)/usr/include" \
+               --with-rlm_sql_postgresql-lib-dir="$(STAGING_DIR)/usr/lib"
+  else
+    PKG_CONFIGURE_OPTIONS += --without-rlm_sql_postgresql
+  endif
+else
+  PKG_CONFIGURE_LIBS += -lcrypto -lssl -lz
+  PKG_CONFIGURE_OPTIONS += \
+               --with-rlm_ldap-include-dir="$(STAGING_DIR)/usr/include" \
+               --with-rlm_ldap-lib-dir="$(STAGING_DIR)/usr/lib" \
+               --with-mysql-include-dir="$(STAGING_DIR)/usr/include" \
+               --with-mysql-lib-dir="$(STAGING_DIR)/usr/lib/mysql" \
+               --without-threads \
+               --with-rlm_sql_postgresql-include-dir="$(STAGING_DIR)/usr/include" \
+               --with-rlm_sql_postgresql-lib-dir="$(STAGING_DIR)/usr/lib"
+endif
+
 define Build/Configure
        (cd $(PKG_BUILD_DIR); rm -f config.cache; \
                $(TARGET_CONFIGURE_OPTS) \