2009-02-03 05:45:14 +00:00
|
|
|
#
|
|
|
|
# Copyright (C) 2009 David Cooper <dave@kupesoft.com>
|
2011-01-06 04:52:24 +00:00
|
|
|
# Copyright (C) 2009-2011 OpenWrt.org
|
2009-02-03 05:45:14 +00:00
|
|
|
#
|
|
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
|
|
# See /LICENSE for more information.
|
|
|
|
#
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=msmtp
|
2011-03-05 07:26:09 +00:00
|
|
|
PKG_VERSION:=1.4.23
|
2010-12-24 12:04:11 +00:00
|
|
|
PKG_RELEASE:=1
|
2009-02-03 05:45:14 +00:00
|
|
|
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
|
|
|
PKG_SOURCE_URL:=@SF/msmtp
|
2011-03-05 07:26:09 +00:00
|
|
|
PKG_MD5SUM:=5fb7ae88186624cdb125d3efad3fdc16
|
2009-02-03 05:45:14 +00:00
|
|
|
|
2009-10-05 14:46:22 +00:00
|
|
|
PKG_FIXUP:=libtool
|
2010-12-24 12:04:11 +00:00
|
|
|
PKG_INSTALL:=1
|
2009-02-03 05:45:14 +00:00
|
|
|
|
2010-02-28 12:26:51 +00:00
|
|
|
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
|
|
|
|
|
2009-02-03 05:45:14 +00:00
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
|
|
|
|
define Package/msmtp/Default
|
|
|
|
SECTION:=mail
|
|
|
|
CATEGORY:=Mail
|
|
|
|
TITLE:=Simple sendmail SMTP forwarding
|
|
|
|
URL:=http://msmtp.sourceforge.net/
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/msmtp/Default/description
|
|
|
|
msmtp is an SMTP client. In the default mode, it transmits a mail to
|
|
|
|
an SMTP server (for example at a free mail provider) which does the
|
|
|
|
delivery. To use this program with your mail user agent (MUA), create
|
|
|
|
a configuration file with your mail account(s) and tell your MUA to
|
|
|
|
call msmtp instead of /usr/sbin/sendmail.
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/msmtp
|
|
|
|
$(call Package/msmtp/Default)
|
|
|
|
DEPENDS+= +libopenssl
|
|
|
|
TITLE+= (with SSL support)
|
2010-02-28 12:26:51 +00:00
|
|
|
VARIANT:=ssl
|
2009-02-03 05:45:14 +00:00
|
|
|
endef
|
|
|
|
|
2009-02-03 05:45:25 +00:00
|
|
|
define Package/msmtp/conffiles
|
2011-03-05 07:26:09 +00:00
|
|
|
/etc/msmtprc
|
2009-02-03 05:45:25 +00:00
|
|
|
endef
|
|
|
|
|
2009-02-03 05:45:14 +00:00
|
|
|
define Package/msmtp/description
|
|
|
|
$(call Package/msmtp/Default/description)
|
|
|
|
This package is built with SSL support.
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/msmtp-nossl
|
|
|
|
$(call Package/msmtp/Default)
|
|
|
|
TITLE+= (without SSL support)
|
2010-02-28 12:26:51 +00:00
|
|
|
VARIANT:=nossl
|
2009-02-03 05:45:14 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/msmtp-nossl/description
|
|
|
|
$(call Package/msmtp/Default/description)
|
|
|
|
This package is built without SSL support.
|
|
|
|
endef
|
|
|
|
|
|
|
|
CONFIGURE_ARGS += \
|
2009-10-05 14:46:22 +00:00
|
|
|
--disable-rpath \
|
2010-12-24 12:04:11 +00:00
|
|
|
--without-libssl32-prefix \
|
2010-12-24 12:33:11 +00:00
|
|
|
--without-libintl-prefix \
|
2009-02-03 05:45:14 +00:00
|
|
|
--without-libgsasl \
|
|
|
|
--without-libidn
|
|
|
|
|
2010-02-28 12:26:51 +00:00
|
|
|
MAKE_FLAGS :=
|
|
|
|
|
|
|
|
ifeq ($(BUILD_VARIANT),ssl)
|
|
|
|
CONFIGURE_ARGS += \
|
2009-02-03 05:45:14 +00:00
|
|
|
--with-ssl=openssl \
|
2010-02-28 12:26:51 +00:00
|
|
|
--with-libssl-prefix="$(STAGING_DIR)/usr/include"
|
2009-02-03 05:45:14 +00:00
|
|
|
endif
|
2010-02-28 12:26:51 +00:00
|
|
|
|
|
|
|
ifeq ($(BUILD_VARIANT),nossl)
|
|
|
|
CONFIGURE_ARGS += \
|
|
|
|
--with-ssl=no
|
2009-02-03 05:45:14 +00:00
|
|
|
endif
|
2010-02-28 12:26:51 +00:00
|
|
|
|
|
|
|
define Package/msmtp/install
|
|
|
|
$(INSTALL_DIR) $(1)/etc
|
|
|
|
$(INSTALL_CONF) $(PKG_BUILD_DIR)/doc/msmtprc-system.example \
|
|
|
|
$(1)/etc/msmtprc
|
|
|
|
$(INSTALL_DIR) $(1)/usr/bin
|
2010-12-24 12:04:11 +00:00
|
|
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/msmtp $(1)/usr/bin/
|
|
|
|
$(INSTALL_BIN) $(PKG_BUILD_DIR)/scripts/msmtpqueue/msmtp-{en,list,run}queue.sh $(1)/usr/bin/
|
2010-02-28 12:26:51 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/sbin
|
2010-03-24 16:37:17 +00:00
|
|
|
endef
|
|
|
|
|
2010-12-24 12:04:11 +00:00
|
|
|
define Package/msmtp/postinst
|
2010-03-24 16:37:17 +00:00
|
|
|
ln -sf ../bin/msmtp $${IPKG_INSTROOT}/usr/sbin/sendmail
|
2010-02-28 12:26:51 +00:00
|
|
|
endef
|
|
|
|
|
2011-03-05 07:26:09 +00:00
|
|
|
Package/msmtp-nossl/conffiles = $(Package/msmtp/conffiles)
|
2010-02-28 12:26:51 +00:00
|
|
|
Package/msmtp-nossl/install = $(Package/msmtp/install)
|
2010-12-24 12:04:11 +00:00
|
|
|
Package/msmtp-nossl/postinst = $(Package/msmtp/postinst)
|
2009-02-03 05:45:14 +00:00
|
|
|
|
|
|
|
$(eval $(call BuildPackage,msmtp))
|
|
|
|
$(eval $(call BuildPackage,msmtp-nossl))
|