[packages] httping: update to 1.5.1
authorStephen Walker <stephendwalker@gmail.com>
Mon, 1 Aug 2011 02:17:57 +0000 (02:17 +0000)
committerStephen Walker <stephendwalker@gmail.com>
Mon, 1 Aug 2011 02:17:57 +0000 (02:17 +0000)
 * add nossl variant
 * drop unused extra_flags patch
 * refresh patches

SVN-Revision: 27857

net/httping/Makefile
net/httping/patches/001-extra_flags.patch [deleted file]
net/httping/patches/002-version.patch

index 0a11935adfdaec809acf1eb37f18ce9111e7e06c..61b098d9a662038a5b97228ffeec632577c6abe0 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2006-2010 OpenWrt.org
+# Copyright (C) 2006-2011 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -8,37 +8,69 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=httping
-PKG_VERSION:=1.4.4
+PKG_VERSION:=1.5.1
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tgz
 PKG_SOURCE_URL:=http://www.vanheusden.com/httping
-PKG_MD5SUM:=e36bb30bd758c766d7260bdde6fe6450
+PKG_MD5SUM:=aeecd67cf90015e50cb03356f89d3c2c
 
+PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
 PKG_INSTALL:=1
 
 include $(INCLUDE_DIR)/package.mk
 
-define Package/httping
+define Package/httping/Default
   SECTION:=net
   CATEGORY:=Network
-  DEPENDS:=+libopenssl
   TITLE:=Httping is like 'ping' but for http-requests
   URL:=http://www.vanheusden.com/httping/
 endef
 
-define Package/httping/description
+define Package/httping/Default/description
        Give it an url, and it'll show you how long it takes to connect, send a
        request and retrieve the reply (only the headers). Be aware that the
        transmission across the network also takes time!
 endef
 
+define Package/httping
+  $(call Package/httping/Default)
+  DEPENDS+= +libopenssl
+  TITLE+= (with SSL support)
+  VARIANT:=ssl
+endef
+
+define Package/httping/description
+       $(call Package/httping/Default/description)
+       This package is built with SSL support.
+endef
+
+define Package/httping-nossl
+  $(call Package/httping/Default)
+  TITLE+= (without SSL support)
+  VARIANT:=nossl
+endef
+
+define Package/httping-nossl/description
+       $(call Package/httping/Default/description)
+       This package is built without SSL support.
+endef
+
 MAKE_FLAGS += \
-       CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS)" \
+       CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS)"
+
+ifeq ($(BUILD_VARIANT),nossl)
+       MAKE_FLAGS += \
+               SSL="no" \
+               CFLAGS+="-DNO_SSL"
+endif
 
 define Package/httping/install
        $(INSTALL_DIR) $(1)/usr/bin
        $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/httping $(1)/usr/bin/
 endef
 
+Package/httping-nossl/install = $(Package/httping/install)
+
 $(eval $(call BuildPackage,httping))
+$(eval $(call BuildPackage,httping-nossl))
diff --git a/net/httping/patches/001-extra_flags.patch b/net/httping/patches/001-extra_flags.patch
deleted file mode 100644 (file)
index c259dc9..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
---- a/Makefile
-+++ b/Makefile
-@@ -18,7 +18,7 @@ TARGET=httping
- WFLAGS=-Wall -W
- OFLAGS=-O2
--CFLAGS+=$(WFLAGS) $(OFLAGS) -DVERSION=\"$(VERSION)\"
-+CFLAGS+=$(EXTRA_CFLAGS) $(WFLAGS) $(OFLAGS) -DVERSION=\"$(VERSION)\"
- PACKAGE=$(TARGET)-$(VERSION)
- PREFIX=/usr
-@@ -47,7 +47,7 @@ ifeq ($(SSL),no)
- CFLAGS+=-DNO_SSL
- else
- OBJS+=mssl.o
--LDFLAGS+=-lssl -lcrypto
-+LDFLAGS+=$(EXTRA_LDFLAGS) -lssl -lcrypto
- endif
- ifeq ($(DEBUG),yes)
index ed5553bb91ff98f467ac3fba74ed77bfef5651a1..556e53c34d03124161d7d404725d069145d37159 100644 (file)
@@ -4,7 +4,7 @@
  #include "utils.h"
  #include "error.h"
  
-+#define VERSION "1.4.4"
++#define VERSION "1.5.1"
 +
  static volatile int stop = 0;
  
@@ -18,7 +18,7 @@
  #ifndef NO_SSL
        fprintf(stderr, "SSL support included\n");
  #endif
-@@ -606,7 +608,7 @@ int main(int argc, char *argv[])
+@@ -637,7 +639,7 @@ int main(int argc, char *argv[])
        if (useragent)
                sprintf(&request[strlen(request)], "User-Agent: %s\r\n", useragent);
        else