CC: ca-certificages: Add certificate bundle for packages that need it
[15.05/openwrt.git] / package / system / ca-certificates / Makefile
index 9c50fef..8590952 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2006-2015 OpenWrt.org
+# Copyright (C) 2006-2016 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -7,11 +7,13 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=ca-certificates
-PKG_VERSION:=20150426
+PKG_VERSION:=20160104
+PKG_MAINTAINER:=Christian Schoenebeck <christian.schoenebeck@gmail.com>
 
 PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION).tar.xz
 PKG_SOURCE_URL:=http://ftp.debian.org/debian/pool/main/c/ca-certificates
-PKG_MD5SUM:=717455f13fb31fd014a11a468ea3895d
+PKG_MD5SUM:=d9665a83d0d3ef8176a38e6aa20458e9
+PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
 
 PKG_INSTALL:=1
 
@@ -21,6 +23,14 @@ define Package/ca-certificates
   SECTION:=base
   CATEGORY:=Base system
   TITLE:=System CA certificates
+  PKGARCH:=all
+endef
+
+define Package/ca-bundle
+  SECTION:=base
+  CATEGORY:=Base system
+  TITLE:=System CA certificates as a bundle
+  PKGARCH:=all
 endef
 
 define Build/Install
@@ -44,4 +54,9 @@ define Package/ca-certificates/install
        done
 endef
 
+define Package/ca-bundle/install
+       $(INSTALL_DIR) $(1)/etc/ssl/certs
+       cat $(PKG_INSTALL_DIR)/usr/share/ca-certificates/*/*.crt >$(1)/etc/ssl/certs/ca-certificates.crt
+endef
 $(eval $(call BuildPackage,ca-certificates))
+$(eval $(call BuildPackage,ca-bundle))