2 # Copyright (C) 2019 Lucian Cristian <lucian.cristian@gmail.com>
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
15 PKG_SOURCE_URL
:=https
://codeload.github.com
/ndilieto
/uacme
/tar.gz
/upstream
/$(PKG_VERSION
)?
16 PKG_HASH
:=c9106e166156685fcf9f164f0b2935cf680251a653f460b04da26a290e946bf9
18 PKG_MAINTAINER
:=Lucian Cristian
<lucian.cristian@gmail.com
>
19 PKG_LICENSE
:=GPL-3.0
-or-later
20 PKG_LICENSE_FILES
:=COPYING
22 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-upstream-
$(PKG_VERSION
)
26 PKG_CONFIG_DEPENDS
:= \
27 CONFIG_LIBCURL_GNUTLS \
28 CONFIG_LIBCURL_MBEDTLS \
29 CONFIG_LIBCURL_OPENSSL \
30 CONFIG_LIBCURL_WOLFSSL \
33 include $(INCLUDE_DIR
)/package.mk
38 DEPENDS
:=+libcurl
+LIBCURL_WOLFSSL
:libmbedtls
39 TITLE
:=lightweight client for ACMEv2
40 URL
:=https
://github.com
/ndilieto
/uacme
43 define Package
/uacme
/Default
/description
44 lightweight client for the RFC8555 ACMEv2 protocol
, written in plain C code
45 with minimal dependencies
(libcurl and one of GnuTLS
, OpenSSL or mbedTLS
).
46 The ACMEv2 protocol allows a Certificate Authority
(https
://letsencrypt.org
47 is a popular one
) and an applicant to automate the process of verification
48 and certificate issuance. The protocol also provides facilities for other
49 certificate management functions
, such
as certificate revocation.
52 define Package
/uacme
/config
53 if PACKAGE_uacme
&& LIBCURL_WOLFSSL
54 comment
"libcurl uses WolfSSL; uacme will install mbedtls"
55 comment
"Choose another SSL lib in libcurl to avoid this"
57 if PACKAGE_uacme
&& LIBCURL_NOSSL
58 comment
"libcurl is built without ssl; uacme needs ssl support"
59 comment
"Choose another SSL lib in libcurl to avoid this"
62 TARGET_LDFLAGS
+= -Wl
,--gc-sections
,--as-needed
65 --disable-maintainer-mode \
67 $(if
$(CONFIG_LIBCURL_GNUTLS
),--with-gnutls
--without-mbedtls
--without-openssl
,) \
68 $(if
$(CONFIG_LIBCURL_MBEDTLS
),--without-gnutls
--with-mbedtls
--without-openssl
,) \
69 $(if
$(CONFIG_LIBCURL_OPENSSL
),--without-gnutls
--without-mbedtls
--with-openssl
,) \
70 $(if
$(CONFIG_LIBCURL_WOLFSSL
),--without-gnutls
--with-mbedtls
--without-openssl
,)
72 define Package
/uacme
/conffiles
77 define Package
/uacme
/install
85 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/uacme
$(1)/usr
/sbin
/uacme
86 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/share
/uacme
/uacme.sh
$(1)/usr
/share
/uacme
/
87 $(SED
) '/^CHALLENGE_PATH=/d' $(1)/usr
/share
/uacme
/uacme.sh
88 $(INSTALL_CONF
) .
/files
/acme.config
$(1)/etc
/config
/acme
89 $(INSTALL_BIN
) .
/files
/run.sh
$(1)/usr
/share
/uacme
/run-uacme
90 $(INSTALL_BIN
) .
/files
/acme.init
$(1)/etc
/init.d
/acme
93 $(eval
$(call BuildPackage
,uacme
))