Description: <short summary of the patch>
 TODO: Put a short summary on the line above and replace this paragraph
 with a longer explanation of this change. Complete the meta-information
 with other relevant fields (see below for details). To make it easier, the
 information below has been extracted from the changelog. Adjust it or drop
 it.
 .
 kbtin (1.0.18-3) unstable; urgency=medium
 .
   * Drop Build-Conflicts on fakeroot.
Author: Adam Borowski <kilobyte@angband.pl>

---
The information above should follow the Patch Tagging Guidelines, please
checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
are templates for supplementary fields that you might want to add:

Origin: <vendor|upstream|other>, <url of original patch>
Bug: <url in upstream bugtracker>
Bug-Debian: https://bugs.debian.org/<bugnumber>
Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
Forwarded: <no|not-needed|url proving that it has been forwarded>
Reviewed-By: <name and email of someone who approved the patch>
Last-Update: 2018-01-21

--- /dev/null
+++ kbtin-1.0.18/.travis.yml
@@ -0,0 +1,10 @@
+language: c
+dist: xenial
+addons:
+  apt:
+    packages:
+    - libz-dev
+    - libglib2.0-dev
+    - libgnutls28-dev
+script: ./autogen.sh && ./configure && make check
+after_failure: cat tests/testsuite.log
--- kbtin-1.0.18.orig/Makefile.am
+++ kbtin-1.0.18/Makefile.am
@@ -19,7 +19,7 @@ AM_CFLAGS=@GLIB_CFLAGS@ -Wall
 KBtin_DOCS=BUGS OLDNEWS KEYPAD FAQ
 EXTRA_DIST=KBtin_help.in commands make_commands $(man_MANS) help2ansi \
 	fixmanual terminfo.src prof_init kbtin.ico make_protos $(KBtin_DOCS) \
-	autogen.sh VERSION get_version a2html
+	autogen.sh VERSION get_version
 CLEANFILES=$(BUILT_SOURCES) KBtin_help.gz manual.html
 DISTCLEANFILES=_stdint.h
 
--- kbtin-1.0.18.orig/colors.c
+++ kbtin-1.0.18/colors.c
@@ -93,11 +93,6 @@ int setcolor(char *txt, int c)
 typedef unsigned char u8;
 struct rgb { u8 r; u8 g; u8 b; };
 
-static inline u8 ramp256_6(int i)
-{
-    return i ? 55 + i * 40 : 0;
-}
-
 static struct rgb rgb_from_256(int i)
 {
     struct rgb c;
@@ -115,9 +110,9 @@ static struct rgb rgb_from_256(int i)
     }
     else if (i < 232)
     {   /* 6x6x6 colour cube. */
-        c.r = ramp256_6((i - 16) / 36);
-        c.g = ramp256_6((i - 16) / 6 % 6);
-        c.b = ramp256_6((i - 16) % 6);
+        c.r = (i - 16) / 36 * 85 / 2;
+        c.g = (i - 16) / 6 % 6 * 85 / 2;
+        c.b = (i - 16) % 6 * 85 / 2;
     }
     else/* Grayscale ramp. */
         c.r = c.g = c.b = i * 10 - 2312;
