thepeople a931d77737 A new package smtptrapd to provide a (secondary) SMTP server returning 4xx soft error. Signed-off-by: Lubos Stanek (lubek) <lubek@lubek.name>
git-svn-id: svn://svn.openwrt.org/openwrt/packages@11065 3c298f89-4303-0410-b956-a3cf2f4a3e73
2008-05-08 00:57:21 +00:00

52 lines
1.2 KiB
Makefile

#
# Copyright (C) 2008 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=smtptrapd
PKG_VERSION:=1.5
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=http://smtptrapd.inodes.org
PKG_MD5SUM:=edc5f2f3ea9f9bdd9e0f479a58903bf1
include $(INCLUDE_DIR)/package.mk
define Package/smtptrapd
SECTION:=net
CATEGORY:=Network
DEPENDS:=+libpthread
TITLE:=SMTP Trap Daemon
URL:=http://smtptrapd.inodes.org/
endef
define Package/smtptrapd/description
The smtptrapd program is a multi-threaded daemon that provides
a RFC 2821 compliant SMTP service that always returns a 4xx soft
error to the RCPT TO verb.
endef
define Build/Compile
$(TARGET_CC) \
$(TARGET_CFLAGS) \
-I $(STAGING_DIR)/usr/include \
-D_REENTRANT \
$(PKG_BUILD_DIR)/smtptrapd.c \
-o $(PKG_BUILD_DIR)/smtptrapd \
-L$(STAGING_DIR)/usr/lib/ -lpthread
endef
define Package/smtptrapd/install
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/smtptrapd.init $(1)/etc/init.d/smtptrapd
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/smtptrapd $(1)/usr/sbin/
endef
$(eval $(call BuildPackage,smtptrapd))