ndn-tools: Update to version 0.4

Change-Id: Iefe311bfad99323a7cf5bb3145d16014dfe09ed6
diff --git a/ndn-tools/debian/changelog b/ndn-tools/debian/changelog
index fb65484..b8f9992 100644
--- a/ndn-tools/debian/changelog
+++ b/ndn-tools/debian/changelog
@@ -1,3 +1,24 @@
+ndn-tools (0.4-ppa3~DISTRO) DISTRO; urgency=low
+
+  * New version based on ndn-tools-0.4 (https://github.com/named-
+    data/ndn-tools)
+
+ -- Alexander Afanasyev <alexander.afanasyev@ucla.edu>  Thu, 26 Jan 2017 05:11:35 +0000
+
+ndn-tools (0.4-ppa2~DISTRO) DISTRO; urgency=low
+
+  * New version based on ndn-tools-0.4 (https://github.com/named-
+    data/ndn-tools)
+
+ -- Alexander Afanasyev <alexander.afanasyev@ucla.edu>  Thu, 26 Jan 2017 04:35:21 +0000
+
+ndn-tools (0.4-ppa1~DISTRO) DISTRO; urgency=low
+
+  * New version based on ndn-tools-0.4 (https://github.com/named-
+    data/ndn-tools)
+
+ -- Alexander Afanasyev <alexander.afanasyev@ucla.edu>  Thu, 26 Jan 2017 04:30:06 +0000
+
 ndn-tools (0.3-28-g72c96d2-ppa1~DISTRO) DISTRO; urgency=low
 
   * New version based on 72c96d23f0c66d157c69954b4b06d8cc2ef330c2
diff --git a/ndn-tools/debian/control b/ndn-tools/debian/control
index ac7c4a8..6b5aef1 100644
--- a/ndn-tools/debian/control
+++ b/ndn-tools/debian/control
@@ -7,7 +7,7 @@
  pkg-config (>= 0.26),
  libpcap-dev,
  python-sphinx,
- ndn-cxx-dev (>= 0.5.0)
+ ndn-cxx-dev (>= 0.5.1)
 Standards-Version: 3.9.2
 Section: net
 Homepage: http://github.com/named-data/ndn-tools
@@ -15,43 +15,43 @@
 Vcs-Browser: http://github.com/named-data/ndn-tools
 
 Package: ndn-tools
-Architecture: i386 amd64
+Architecture: i386 amd64 arm64 armel armhf ppc64el
 Depends: ndndump, ndnping, ndnpeek, ndn-dissect
 Description: A collection of essential tools for Named Data Networking
 
 Package: ndndump
-Architecture: i386 amd64
+Architecture: i386 amd64 arm64 armel armhf ppc64el
 Depends: ${shlibs:Depends}, ${misc:Depends}, ndn-cxx
 Description: A traffic analysis tool that captures Interest and Data packets
  on the wire, and displays brief information about captured packets.
 
 Package: ndnping
-Architecture: i386 amd64
+Architecture: i386 amd64 arm64 armel armhf ppc64el
 Depends: ${shlibs:Depends}, ${misc:Depends}, ndn-cxx, nfd
 Description: Reachability testing tools for Named Data Networking.
 
 Package: ndn-tlv-ping
-Architecture: i386 amd64
+Architecture: i386 amd64 arm64 armel armhf ppc64el
 Depends: ndnping
 Description: Deprecated package, use ndnping instead
 
 Package: ndnpeek
-Architecture: i386 amd64
+Architecture: i386 amd64 arm64 armel armhf ppc64el
 Depends: ${shlibs:Depends}, ${misc:Depends}, ndn-cxx
 Description: ndnpeek and ndnpoke are a pair of programs to request and make available
  for retrieval of a single Data packet.
 
 Package: ndn-dissect
-Architecture: i386 amd64
+Architecture: i386 amd64 arm64 armel armhf ppc64el
 Depends: ${shlibs:Depends}, ${misc:Depends}, ndn-cxx
 Description: An NDN packet format inspector. It reads zero or more NDN packets from either
  an input file or the standard input, and displays the Type-Length-Value (TLV) structure
  of those packets on the standard output.
 
 Package: ndn-dissect-wireshark
-Architecture: i386 amd64
+Architecture: i386 amd64 arm64 armel armhf ppc64el
 Description: Wireshark extension to inspect TLV structure of NDN packets
 
-Package: ndn-pib
-Architecture: i386 amd64
-Description: A service to manage the public information of keys and publish certificates
+# Package: ndn-pib
+# Architecture: i386 amd64 arm64 armel armhf ppc64el
+# Description: A service to manage the public information of keys and publish certificates
diff --git a/ndn-tools/debian/patches/series b/ndn-tools/debian/patches/series
new file mode 100644
index 0000000..fd704fb
--- /dev/null
+++ b/ndn-tools/debian/patches/series
@@ -0,0 +1 @@
+wscript.patch
diff --git a/ndn-tools/debian/patches/wscript.patch b/ndn-tools/debian/patches/wscript.patch
new file mode 100644
index 0000000..1fe6fab
--- /dev/null
+++ b/ndn-tools/debian/patches/wscript.patch
@@ -0,0 +1,12 @@
+Index: a/wscript
+===================================================================
+--- a.orig/wscript	2017-01-26 05:03:14.250879786 +0000
++++ a/wscript	2017-01-26 05:03:52.114878924 +0000
+@@ -62,6 +62,7 @@
+     bld.recurse('manpages')
+ 
+ def version(bld):
++    didGetVersion = False
+     # Modified from ndn-cxx wscript
+     try:
+         cmd = ['git', 'describe', '--always', '--match', '%s*' % GIT_TAG_PREFIX]
diff --git a/ndn-tools/debian/rules b/ndn-tools/debian/rules
index a4d748a..c0d37c1 100755
--- a/ndn-tools/debian/rules
+++ b/ndn-tools/debian/rules
@@ -11,12 +11,13 @@
 
 LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS)
 CXXFLAGS := $(shell dpkg-buildflags --get CXXFLAGS)
+LIBDIR := /usr/lib/$(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
 
 %:
 	dh $@ --parallel --with=systemd
 
 override_dh_auto_configure:
-	CXXFLAGS="$(CXXFLAGS)" LINKFLAGS="$(LDFLAGS)" ./waf configure --prefix=/usr
+	CXXFLAGS="$(CXXFLAGS)" LINKFLAGS="$(LDFLAGS)" ./waf configure --prefix=/usr --boost-libs="$(LIBDIR)"
 
 override_dh_auto_build:
 	./waf build