Skip to contentSkip to conversation

libpam-radius-auth: new package

PATCH New giovanni.zantedeschi 2 participants 2 messages Aug 19, 2015 – Aug 28, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 libpam-radius-auth: new package

From: "Giovanni Zantedeschi" <[email protected]>

---
 package/Config.in                                |  1 +
 package/libpam-radius-auth/Config.in             |  6 ++++++
 package/libpam-radius-auth/libpam-radius-auth.mk | 25 ++++++++++++++++++++++++
 3 files changed, 32 insertions(+)
 create mode 100644 package/libpam-radius-auth/Config.in
 create mode 100644 package/libpam-radius-auth/libpam-radius-auth.mk
package/Config.in +1 -0
index 47d14d7..a4e9e13 100644
@@ -1074,6 +1074,7 @@ menu "Other"
 	source "package/libical/Config.in"
 	source "package/liblinear/Config.in"
 	source "package/libnspr/Config.in"
+	source "package/libpam-radius-auth/Config.in"
 	source "package/libpfm4/Config.in"
 	source "package/libplatform/Config.in"
 	source "package/libplist/Config.in"
package/libpam-radius-auth/Config.in new file +6 -0
new file mode 100644
index 0000000..f77fc1a
@@ -0,0 +1,6 @@
+ config BR2_PACKAGE_LIBPAM_RADIUS_AUTH
+        bool "libpam-radius-auth"
+        help
+          Lib needed to use pam-radius and FreeRadius
+
+          http://freeradius.org/pam_radius_auth/
package/libpam-radius-auth/libpam-radius-auth.mk new file +25 -0
new file mode 100644
index 0000000..8603903
@@ -0,0 +1,25 @@
+################################################################################
+#
+# libpam-radius-auth
+#
+################################################################################
+
+LIBPAM_RADIUS_AUTH_VERSION = release_1_4_0
+LIBPAM_RADIUS_AUTH_SITE = https://github.com/FreeRADIUS/pam_radius.git
+LIBPAM_RADIUS_AUTH_SITE_METHOD = git
+
+LIBPAM_RADIUS_AUTH_INSTALL_STAGING = YES
+LIBPAM_RADIUS_AUTH_AUTORECONF = YES
+LIBPAM_RADIUS_AUTH_LICENSE = GPLv2+
+LIBPAM_RADIUS_AUTH_LICENSE_FILES = LICENSE
+LIBPAM_RADIUS_AUTH_MAKE_OPTS = CC="$(TARGET_CC)" LD="$(TARGET_LD)"
+
+define LIBPAM_RADIUS_AUTH_INSTALL_STAGING_CMDS
+    $(INSTALL) -D -m 0755 $(@D)/pam_radius_auth.so* $(STAGING_DIR)/lib/security/
+endef
+
+define LIBPAM_RADIUS_AUTH_INSTALL_TARGET_CMDS
+    $(INSTALL) -D -m 0755 $(@D)/pam_radius_auth.so* $(TARGET_DIR)/lib/security/
+endef
+
+$(eval $(autotools-package))
Signature · 1 line
1.9.1
#1 lore raw

PATCH 1/1 libpam-radius-auth: new package

Giovanni,

Thanks for this patch!

Quoted 10 lines · giovanni.zantedeschi

From: "Giovanni Zantedeschi" <[email protected]>

---
 package/Config.in                                |  1 +
 package/libpam-radius-auth/Config.in             |  6 ++++++
 package/libpam-radius-auth/libpam-radius-auth.mk | 25 ++++++++++++++++++++++++
 3 files changed, 32 insertions(+)
 create mode 100644 package/libpam-radius-auth/Config.in
 create mode 100644 package/libpam-radius-auth/libpam-radius-auth.mk

I've applied it to the next branch, but I had to do quite a bit of changes beforehand:

[Thomas:
- make libpam-radius-auth depend on linux-pam (since it's a linux-pam plugin, it needs some header files from linux-pam) by adding a "if BR2_PACKAGE_LINUX_PAM...endif" block in package/Config.in. This way, we will be grouping all the Linux PAM plugins together.
- Fix the indententation in the Config.in file.
- Use a better Config.in help text, copy/pasted from the website.
- Use a tarball instead of github. This allows to remove AUTORECONF=YES.
- Add linux-pam as a dependency.
- Use $(TARGET_CONFIGURE_OPTS) instead of passing just CC/LD, but pass it in the environment rather than as options so that the CFLAGS/LDFLAGS added by the package Makefile are still taken into account.
- Use mkdir -p + cp -dpfr instead of $(INSTALL) -D since we are copying multiple files.
- Add a hash file.]

Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com