Index: configure
===================================================================
--- configure	(revision 4fe91a16d4808ebf47ea8be6f4206139c91d3347)
+++ configure	(revision 2e78f75dc5e33fe6d804e71d999f9cab933afd91)
@@ -57,7 +57,4 @@
 pie=1
 
-arch=$(uname -s)
-cpu=$(uname -m)
-
 GLIB_MIN_VERSION=2.16
 
@@ -200,6 +197,4 @@
 
 TARGET=$target
-ARCH=$arch
-CPU=$cpu
 
 INSTALL=install -p
@@ -248,6 +243,4 @@
 #define PIDFILE "$pidfile"
 #define IPCSOCKET "$ipcsocket"
-#define ARCH "$arch"
-#define CPU "$cpu"
 EOF
 
Index: debian/changelog
===================================================================
--- debian/changelog	(revision 4fe91a16d4808ebf47ea8be6f4206139c91d3347)
+++ debian/changelog	(revision 2e78f75dc5e33fe6d804e71d999f9cab933afd91)
@@ -1,2 +1,9 @@
+bitlbee (3.4.2-1) UNRELEASED; urgency=medium
+
+  * Make the build reproducible by not encoding ARCH / CPU defines in
+    the binary.
+
+ -- Jelmer Vernooĳ <jelmer@debian.org>  Sun, 15 May 2016 17:15:13 +0000
+
 bitlbee (3.4.1-1) unstable; urgency=medium
 
Index: irc_commands.c
===================================================================
--- irc_commands.c	(revision 4fe91a16d4808ebf47ea8be6f4206139c91d3347)
+++ irc_commands.c	(revision 2e78f75dc5e33fe6d804e71d999f9cab933afd91)
@@ -767,6 +767,6 @@
 static void irc_cmd_version(irc_t *irc, char **cmd)
 {
-	irc_send_num(irc, 351, "%s-%s. %s :%s/%s ",
-	             PACKAGE, BITLBEE_VERSION, irc->root->host, ARCH, CPU);
+	irc_send_num(irc, 351, "%s-%s. %s :",
+	             PACKAGE, BITLBEE_VERSION, irc->root->host);
 }
 
Index: irc_send.c
===================================================================
--- irc_send.c	(revision 4fe91a16d4808ebf47ea8be6f4206139c91d3347)
+++ irc_send.c	(revision 2e78f75dc5e33fe6d804e71d999f9cab933afd91)
@@ -41,6 +41,6 @@
 {
 	irc_send_num(irc,   1, ":Welcome to the %s gateway, %s", PACKAGE, irc->user->nick);
-	irc_send_num(irc,   2, ":Host %s is running %s %s %s/%s.", irc->root->host,
-	             PACKAGE, BITLBEE_VERSION, ARCH, CPU);
+	irc_send_num(irc,   2, ":Host %s is running %s %s.", irc->root->host,
+	             PACKAGE, BITLBEE_VERSION);
 	irc_send_num(irc,   3, ":%s", IRCD_INFO);
 	irc_send_num(irc,   4, "%s %s %s %s", irc->root->host, BITLBEE_VERSION, UMODES UMODES_PRIV, CMODES);
Index: irc_user.c
===================================================================
--- irc_user.c	(revision 4fe91a16d4808ebf47ea8be6f4206139c91d3347)
+++ irc_user.c	(revision 2e78f75dc5e33fe6d804e71d999f9cab933afd91)
@@ -251,5 +251,5 @@
 	if (g_strcasecmp(ctcp[0], "VERSION") == 0) {
 		irc_send_msg_f(iu, "NOTICE", iu->irc->user->nick, "\001%s %s\001",
-		               ctcp[0], PACKAGE " " BITLBEE_VERSION " " ARCH "/" CPU);
+		               ctcp[0], PACKAGE " " BITLBEE_VERSION);
 	} else if (g_strcasecmp(ctcp[0], "PING") == 0) {
 		irc_send_msg_f(iu, "NOTICE", iu->irc->user->nick, "\001%s %s\001",
Index: lib/http_client.c
===================================================================
--- lib/http_client.c	(revision 4fe91a16d4808ebf47ea8be6f4206139c91d3347)
+++ lib/http_client.c	(revision 2e78f75dc5e33fe6d804e71d999f9cab933afd91)
@@ -95,5 +95,5 @@
 	request = g_strdup_printf("GET %s HTTP/1.0\r\n"
 	                          "Host: %s\r\n"
-	                          "User-Agent: BitlBee " BITLBEE_VERSION " " ARCH "/" CPU "\r\n"
+	                          "User-Agent: BitlBee " BITLBEE_VERSION "\r\n"
 	                          "\r\n", url->file, url->host);
 
Index: protocols/jabber/iq.c
===================================================================
--- protocols/jabber/iq.c	(revision 4fe91a16d4808ebf47ea8be6f4206139c91d3347)
+++ protocols/jabber/iq.c	(revision 2e78f75dc5e33fe6d804e71d999f9cab933afd91)
@@ -67,5 +67,4 @@
 			xt_add_child(reply, xt_new_node("name", set_getstr(&ic->acc->set, "user_agent"), NULL));
 			xt_add_child(reply, xt_new_node("version", BITLBEE_VERSION, NULL));
-			xt_add_child(reply, xt_new_node("os", ARCH, NULL));
 		} else if (strcmp(s, XMLNS_TIME_OLD) == 0) {
 			time_t time_ep;
Index: protocols/twitter/twitter_http.c
===================================================================
--- protocols/twitter/twitter_http.c	(revision 4fe91a16d4808ebf47ea8be6f4206139c91d3347)
+++ protocols/twitter/twitter_http.c	(revision 2e78f75dc5e33fe6d804e71d999f9cab933afd91)
@@ -79,5 +79,5 @@
 	g_string_printf(request, "%s %s%s%s%s HTTP/1.1\r\n"
 	                "Host: %s\r\n"
-	                "User-Agent: BitlBee " BITLBEE_VERSION " " ARCH "/" CPU "\r\n",
+	                "User-Agent: BitlBee " BITLBEE_VERSION "\r\n",
 	                is_post ? "POST" : "GET",
 	                base_url ? base_url->file : td->url_path,
