libesmtp: streamline makefile
Signed-off-by: Othmar Truniger <github@truniger.ch>
This commit is contained in:
parent
58245f257f
commit
7ae9c98341
1 changed files with 17 additions and 28 deletions
|
@ -1,5 +1,5 @@
|
||||||
#
|
#
|
||||||
# Copyright (C) 2008-2014 OpenWrt.org
|
# Copyright (C) 2008-2015 OpenWrt.org
|
||||||
#
|
#
|
||||||
# This is free software, licensed under the GNU General Public License v2.
|
# This is free software, licensed under the GNU General Public License v2.
|
||||||
# See /LICENSE for more information.
|
# See /LICENSE for more information.
|
||||||
|
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=libesmtp
|
PKG_NAME:=libesmtp
|
||||||
PKG_VERSION:=1.0.6
|
PKG_VERSION:=1.0.6
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=2
|
||||||
PKG_MD5SUM:=c4fedc999b6c3820296b0eb92cc2e252
|
PKG_MD5SUM:=c4fedc999b6c3820296b0eb92cc2e252
|
||||||
|
|
||||||
PKG_MAINTAINER:=Othmar Truniger <github@truniger.ch>
|
PKG_MAINTAINER:=Othmar Truniger <github@truniger.ch>
|
||||||
|
@ -19,6 +19,9 @@ PKG_LICENSE_FILES:=COPYING
|
||||||
PKG_SOURCE_URL:=http://www.stafford.uklinux.net/libesmtp
|
PKG_SOURCE_URL:=http://www.stafford.uklinux.net/libesmtp
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||||
|
|
||||||
|
PKG_BUILD_PARALLEL:=1
|
||||||
|
PKG_INSTALL:=1
|
||||||
|
|
||||||
include $(INCLUDE_DIR)/package.mk
|
include $(INCLUDE_DIR)/package.mk
|
||||||
|
|
||||||
define Package/libesmtp
|
define Package/libesmtp
|
||||||
|
@ -29,38 +32,24 @@ define Package/libesmtp
|
||||||
DEPENDS:=+libpthread
|
DEPENDS:=+libpthread
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Build/Configure
|
CONFIGURE_ARGS += \
|
||||||
$(call Build/Configure/Default,--without-openssl)
|
--without-openssl
|
||||||
endef
|
|
||||||
|
|
||||||
define Build/Compile
|
|
||||||
$(MAKE) -C $(PKG_BUILD_DIR) \
|
|
||||||
DESTDIR="$(PKG_INSTALL_DIR)" \
|
|
||||||
all install
|
|
||||||
endef
|
|
||||||
|
|
||||||
define Build/InstallDev
|
define Build/InstallDev
|
||||||
mkdir -p $(STAGING_DIR)/usr/include
|
$(INSTALL_DIR) $(1)/usr/bin
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/libesmtp.h $(STAGING_DIR)/usr/include/
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/libesmtp-config $(1)/usr/bin/
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/auth-client.h $(STAGING_DIR)/usr/include/
|
$(SED) 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' $(1)/usr/bin/libesmtp-config
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/auth-plugin.h $(STAGING_DIR)/usr/include/
|
|
||||||
mkdir -p $(STAGING_DIR)/usr/lib
|
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libesmtp.{a,so*} $(STAGING_DIR)/usr/lib/
|
|
||||||
$(INSTALL_DIR) $(2)/bin
|
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/libesmtp-config $(2)/bin/
|
|
||||||
$(SED) 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' $(2)/bin/libesmtp-config
|
|
||||||
endef
|
|
||||||
|
|
||||||
define Build/UninstallDev
|
$(INSTALL_DIR) $(1)/usr/include
|
||||||
rm -rf \
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/*.h $(1)/usr/include/
|
||||||
$(STAGING_DIR)/usr/include/libesmtp.h \
|
$(INSTALL_DIR) $(1)/usr/lib
|
||||||
$(STAGING_DIR)/usr/include/auth-client.h \
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libesmtp.{a,so*} $(1)/usr/lib/
|
||||||
$(STAGING_DIR)/usr/include/auth-plugin.h \
|
$(INSTALL_DIR) $(2)/bin
|
||||||
$(STAGING_DIR)/usr/lib/libesmtp.{a,so*}
|
$(LN) ../../usr/bin/libesmtp-config $(2)/bin/
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/libesmtp/install
|
define Package/libesmtp/install
|
||||||
mkdir -p $(1)/usr/lib
|
$(INSTALL_DIR) $(1)/usr/lib
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libesmtp.so.* $(1)/usr/lib/
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libesmtp.so.* $(1)/usr/lib/
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue