commit: f5752e31ef3246c94ef25cfc4710676bb3240463
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date: Fri, 3 May 2019 05:30:21 +0200
Initial commit
Diffstat:
106 files changed, 5417 insertions(+), 0 deletions(-)
diff --git a/bashrc b/bashrc
@@ -0,0 +1,5 @@
+if [ "${EBUILD_PHASE}" == "postinst" ] || [ "${EBUILD_PHASE}" == "postrm" ];
+then
+ echo ":: Calling makewhatis"
+ makewhatis -Q -T utf8 ${MANPATH//:/ }
+fi
diff --git a/env/badwolf b/env/badwolf
@@ -0,0 +1 @@
+EGIT_OVERRIDE_BRANCH_BADWOLF=features/keybinds+
\ No newline at end of file
diff --git a/env/cxx11 b/env/cxx11
@@ -0,0 +1 @@
+CXXFLAGS="${CXXFLAGS} -std=cxx11"
diff --git a/env/debug b/env/debug
@@ -0,0 +1,2 @@
+CFLAGS="-O1 -pipe -ggdb"
+CXXFLAGS="${CFLAGS}"
diff --git a/env/fPIC b/env/fPIC
@@ -0,0 +1,2 @@
+CFLAGS="${CFLAGS} -fPIC"
+CXXFLAGS="${CXXFLAGS} -fPIC"
diff --git a/env/gcc b/env/gcc
@@ -0,0 +1,10 @@
+AS="as"
+AR="gcc-ar"
+CC="gcc"
+CCC="g++"
+CXX="g++"
+CFLAGS="-O2 -pipe -march=native -mtune=native -Wall -Wconversion -Wno-error=conversion -Wsign-conversion -Wno-error=sign-conversion -Wformat -Wformat-security"
+#CFLAGS="-O2 -pipe -march=native -mtune=native -Wall -Wextra -Wconversion -Wno-error=conversion -Wsign-conversion -Wno-error=sign-conversion -Wformat -Wformat-security"
+CXXFLAGS="${CFLAGS}"
+NM="gcc-nm"
+RANLIB="ranlib"
diff --git a/env/gcc-ar b/env/gcc-ar
@@ -0,0 +1 @@
+AR="gcc-ar"+
\ No newline at end of file
diff --git a/env/gcc-as b/env/gcc-as
@@ -0,0 +1 @@
+AS="as"+
\ No newline at end of file
diff --git a/env/latomic b/env/latomic
@@ -0,0 +1 @@
+LDFLAGS="${LDFLAGS} -latomic"+
\ No newline at end of file
diff --git a/env/libstdcxx b/env/libstdcxx
@@ -0,0 +1 @@
+CXXFLAGS="${CXXFLAGS} -stdlib=libstdc++"+
\ No newline at end of file
diff --git a/env/libtool b/env/libtool
@@ -0,0 +1 @@
+LIBTOOL="libtool"+
\ No newline at end of file
diff --git a/env/llvm4 b/env/llvm4
@@ -0,0 +1,9 @@
+AS="llvm-as"
+AR="llvm-ar"
+CC="clang-4.0"
+CCC="clang++-4.0"
+CXX="clang++-4.0"
+CFLAGS="-Qunused-arguments -O2 -pipe -march=native -mtune=native -Wall -Wextra -Wconversion -Wsign-conversion -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -pie -fPIE -fPIC"
+CXXFLAGS="${CFLAGS}"
+NM="llvm-nm"
+RANLIB="llvm-ranlib"
diff --git a/env/log_disable_0 b/env/log_disable_0
@@ -0,0 +1,3 @@
+# https://trac.webkit.org/wiki/WebKitGTK/Debugging#Loggingsupport
+export CFLAGS="${CFLAGS} -DLOG_DISABLED=0"
+export CXXFLAGS="${CXXFLAGS} -DLOG_DISABLED=0"
diff --git a/make.conf b/make.conf
@@ -0,0 +1,45 @@
+PORTDIR="/usr/portage"
+PKGDIR="${PORTDIR}/packages"
+DISTDIR="${PORTDIR}/distfiles"
+USE=" -sslv3 libzfs libressl X dane -handbook cjk -suid xinerama startup-notification alsa -geoloc -geolocation lcms opengl dbus libnotify -nsplugin -pin-upstream-blobs -policykit -kwallet socks5 fontconfig latex grammar spell cacert injection xcb luajit cryptsetup -cups upnp icu llvm libproxy gold eme-free -kdesu smp force-gtk3 jumbo-build sasl stunnel idn gtk3 -exiv2 -printsupport libkms"
+USE="$USE jpeg gif png webp mod mikmod v4l wayland gles -gles2 egl clang libcxx acpi truetype -binary xft threads xcsecurity glamor -kde -gucharmap canna urandom lm_sensors d3d9 xa xvmc -vulkan vdpau vaapi (dri) nntp"
+USE="$USE -luajittex -libunwind -pulseaudio"
+USE="$USE -pax_kernel"
+USE="$USE symlink xbuild developer"
+CALLIGRA_FEATURES="sheets words"
+CALLIGRA_EXPERIMENTAL_FEATURES="braindump stage"
+QEMU_SOFTMMU_TARGETS="x86_64 arm arm64 i386 sparc64"
+QEMU_USER_TARGETS="${QEMU_SOFTMMU_TARGETS}"
+LIRC_DEVICES="all"
+ALSA_CARDS="hda-intel usb-audio"
+INPUT_DEVICES="evdev keyboard mouse libinput wacom"
+VIDEO_CARDS="nouveau (nvidia) (virgl)"
+LUA_TARGETS="lua52"
+#LUA_IGNORE_TARGET_DUPLICATION="yes" # I’m a maintainer
+FONT_TYPES="ttf otf"
+BITCOIN_POLICY="rbf spamfilter"
+DOTNET_TARGETS="net46 net45 net40"
+USE="$USE ${DOTNET_TARGETS}"
+FEATURES="-nostrip splitdebug"
+
+GRUB_PLATFORMS="pc"
+
+CPU_FLAGS_X86="mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3"
+CHOST="x86_64-pc-linux-gnu"
+ABI_X86="64 32"
+
+RUBY_TARGETS="ruby24"
+POSTGRES_TARGETS="postgres9_6"
+PYTHON_TARGETS="python3_6"
+
+#LIBTOOL="clibtool"
+
+# LLVM
+AS="llvm-as"
+CC="clang"
+CCC="clang++"
+CXX="clang++"
+CXXFLAGS="-Qunused-arguments ${CXXFLAGS}"
+CFLAGS="-Qunused-arguments ${CFLAGS}"
+NM="llvm-nm"
+RANLIB="llvm-ranlib"
diff --git a/package.accept_keywords b/package.accept_keywords
@@ -0,0 +1,427 @@
+*/*::lanodanOverlay ~*
+net-im/tootle::lanodanOverlay **
+app-editors/vis ~*
+www-plugins/passff ~*
+www-plugins/passff-host ~*
+games-arcade/oshu ~*
+
+=dev-util/perf-4.1.5-r1 ~amd64
+=dev-libs/unibilium-1.1.4 ~amd64
+=dev-libs/libtermkey-0.19 ~amd64
+=sys-boot/grub-2.02 ~amd64
+~dev-python/cryptography-1.9 ~amd64
+=dev-python/asn1crypto-0.22.0 ~amd64
+media-fonts/source-pro ~*
+=media-libs/openal-1.18.0 ~amd64
+=media-sound/milkytracker-1.0.0 ~amd64
+=media-sound/ibniz-1.18 ~amd64
+=dev-lang/tcc-0.9.26-r3 ~amd64
+sys-firmware/nvidia-firmware ~amd64
+dev-util/plan9port ~amd64
+media-fonts/unifont ~amd64
+=games-arcade/spout-1.3 **
+=games-arcade/savagewheels-1.6.1-r1 ~amd64
+www-client/weboob ~*
+app-i18n/unicode-data ~amd64
+=dev-libs/nspr-4.16 ~amd64
+=net-misc/drawterm-9999 ~amd64
+virtual/pmake ~amd64
+=sys-devel/bmake-20170510 ~amd64
+=dev-util/amtterm-1.6 ~amd64
+=dev-python/scandir-1.5 ~amd64
+=dev-python/pathlib2-2.3.0 ~amd64
+=app-shells/thefuck-3.18 ~amd64
+=app-i18n/translate-shell-0.9.6.2 ~*
+media-gfx/krita::lanodanOverlay ~amd64
+=games-engines/love-0.10.2 ~amd64
+dev-util/shellcheck ~amd64
+=media-gfx/arss-0.2.3-r1 ~amd64
+=media-libs/fontconfig-2.12.4 ~*
+=dev-python/scfbuild-0_p20170226 ~amd64
+media-fonts/emojione-color-font ~amd64
+=dev-util/svgo-0.7.2 ~amd64
+=sys-libs/binutils-libs-2.28.1 ~amd64
+=net-libs/tox-0.1.10 ~amd64
+=net-im/toxic-0.7.2-r1 ~amd64
+=net-im/qtox-1.11.0 ~amd64
+=dev-libs/capstone-3.0.5_rc2-r1 ~amd64
+=app-emulation/wine-mono-4.5.6 ~amd64
+=app-emulation/wine-1.8.7-r3 ~amd64
+=app-emulation/wine-gecko-2.40 ~amd64
+=app-emulation/wine-vanilla-1.8.7-r5 ~amd64
+=app-eselect/eselect-wine-1.5-r1 ~amd64
+=dev-libs/wayland-protocols-1.10 ~amd64
+~dev-python/urllib3-1.20 ~* # support for socks5h:// and socks4a://
+=net-proxy/redsocks-0.5 ~amd64
+app-text/texlive-core ~*
+app-text/texlive ~*
+dev-texlive/* ~*
+app-crypt/signify ~amd64
+app-shells/mksh ~*
+sci-libs/libticonv ~amd64
+sci-libs/libtifiles2 ~amd64
+sci-calculators/tilp2 ~amd64
+sci-libs/libticalcs2 ~amd64
+sci-libs/libticables2 ~amd64
+~dev-python/m2crypto-0.25.1 ~*
+=app-misc/bb-1.3.0_rc1-r4 ~amd64
+=app-crypt/johntheripper-1.7.9-r11 ~amd64
+=net-vpn/iodine-0.7.0-r2 ~amd64
+=net-vpn/tinc-1.1_pre15 ~amd64
+=net-wireless/reaver-1.4-r3 ~amd64
+=app-misc/crunch-3.6 ~amd64
+=media-libs/libpng-1.6.32 ~amd64
+=dev-lang/mono-5.2.0.224 ~amd64
+=dev-libs/nss-3.33::gentoo ~amd64
+=media-gfx/gmic-2.0.0 ~*
+=media-gfx/mypaint-1.2.1 ~*
+=media-libs/libmypaint-1.3.0 ~amd64
+=media-libs/cimg-2.0.0 ~amd64
+=app-eselect/eselect-lua-2 ~amd64
+~dev-lang/lua-5.2.4 ~amd64
+=dev-lang/lua-5.1.5-r101 ~amd64
+=media-fonts/fira-mono-3.205 ~amd64
+=dev-texlive/texlive-metapost-2017 ~amd64
+=dev-python/unicodedata2-10.0.0 ~amd64
+=dev-python/defcon-0.3.4 ~amd64
+=dev-python/fonttools-3.15.1 ~amd64
+=dev-python/MutatorMath-2.0.4 ~amd64
+=dev-python/ufoLib-2.1.0 ~amd64
+=dev-util/afdko-2.5.65781_p20170727 ~amd64
+=dev-python/pyclipper-1.0.6 ~amd64
+=dev-python/booleanOperations-0.7.1 ~amd64
+=dev-python/fontMath-0.4.3 ~amd64
+=dev-python/compositor-0_p20170303 ~amd64
+=dev-util/patchbin-20160208 ~amd64
+=app-emulation/wine-vanilla-1.8.7-r7 ~amd64
+=app-shells/thefuck-3.23 ~amd64
+=app-eselect/eselect-wine-1.5.2 ~amd64
+=dev-lua/mpack-1.0.4 ~amd64
+=dev-libs/msgpack-1.2.0 ~amd64
+=dev-libs/libvterm-0.0_pre20160305 ~amd64
+=app-editors/neovim-0.2.0 ~amd64
+=www-client/dillo-3.0.5-r1 ~amd64
+=www-client/torbrowser-52.4.0.7.0.5.1.1 ~amd64
+=www-client/qutebrowser-0.9.1 ~amd64
+=www-client/dooble-1.56c ~amd64
+=dev-python/pygments-2.2.0 ~amd64
+=www-client/midori-0.5.11-r2 ~amd64
+=dev-python/pypeg2-2.15.2 ~amd64
+=games-misc/ponysay-3.0.2 ~amd64
+=games-misc/doge-3.5.0 ~amd64
+=sys-auth/oath-toolkit-2.6.2 ~amd64
+=app-admin/pass-otp-1.0.0 ~amd64
+=sys-power/powerstat-0.02.11 ~amd64
+=app-forensics/radamsa-0.5-r1 ~amd64
+=app-admin/paxtest-0.9.15-r1 ~amd64
+=app-forensics/scalpel-2.0 ~amd64
+=dev-util/radare2-2.0.1 ~*
+=app-forensics/afl-2.51b ~amd64
+=net-libs/ldns-1.6.17-r1 ~*
+=www-plugins/lightspark-0.8.0 ~amd64
+~dev-dotnet/msbuildcontrib-2014.06.05.01 ~amd64
+~dev-dotnet/dotnetzip-semverd-1.9.3-r1 ~amd64
+=sys-fs/ecryptfs-utils-108-r1 ~amd64
+~dev-dotnet/buildtools-1.0.27 ~amd64
+~dev-dotnet/msbuild-roslyn-csc-15.3 ~amd64
+~dev-dotnet/msbuild-tasks-api-15.3-r1 ~amd64
+~dev-dotnet/system-reflection-metadata-2.0.0_pre ~amd64
+~dev-dotnet/newtonsoft-json-6.0.8-r1 ~amd64
+~dev-util/msbuild-15.3-r2 ~amd64
+~dev-dotnet/system-collections-immutable-2.0.0_pre ~amd64
+~dev-dotnet/msbuild-defaulttasks-15.3-r2 ~amd64
+~dev-dotnet/msbuildtasks-1.5.0.240-r3 ~amd64
+~dev-dotnet/dotnetzip-semverd-1.9.3-r2 ~amd64
+=dev-lang/mono-5.4.0.201::lanodanOverlay ~*
+=sci-biology/ugene-1.20.0 ~amd64
+
+=net-vpn/tor-0.3.2.10 ~*
+=sys-apps/linux-misc-apps-4.4-r1 ~amd64
+=games-roguelike/zangband-2.7.4c ~amd64
+=app-eselect/eselect-wine-1.5.3 ~amd64
+media-gfx/inkscape ~*
+=media-gfx/scour-0.36 ~amd64
+
+sys-apps/yarn ~amd64
+net-libs/nodejs::libressl ~amd64
+net-libs/nodejs::chaoslab ~amd64
+=dev-libs/libuv-1.17.0 ~amd64
+=sys-libs/db-5.1.29-r1 ~amd64
+
+=www-apps/ctpp2-2.8.3:mva ~amd64
+=games-misc/katawa-shoujo-1.3 ~amd64
+=www-apps/ctpp2-2.8.3 ~amd64
+=net-analyzer/openbsd-netcat-1.105-r1 ~amd64
+=dev-java/gradle-3.4 ~amd64
+=app-misc/freeplane-1.5.18 ~amd64
+=x11-misc/qarma-1 ~amd64
+=dev-python/python-evdev-0.7.0 ~amd64
+=games-util/lutris-0.4.14 ~amd64
+<=dev-lang/erlang-20.1 ~*
+=x11-plugins/purple-discord-9999 ~amd64
+=games-engines/scummvm-2.0.0 ~amd64
+=games-strategy/openra-20141029-r2 ~amd64
+=games-emulation/mupen64plus-rsp-hle-2.5 ~amd64
+=games-fps/xonotic-0.8.2 ~amd64
+=games-misc/katawa-shoujo-1.3.1 ~amd64
+=games-board/cockatrice-20170505 ~amd64
+=games-emulation/mupen64plus-audio-sdl-2.5 ~amd64
+=games-emulation/mupen64plus-input-sdl-2.5 ~amd64
+=games-emulation/mupen64plus-core-2.5-r1 ~amd64
+=games-emulation/mupen64plus-ui-console-2.5 ~amd64
+=games-action/noiz2sa-0.51a-r1 ~amd64
+=games-emulation/mupen64plus-video-glide64mk2-2.5 ~amd64
+=games-emulation/mupen64plus-video-rice-2.5 ~amd64
+
+=games-emulation/m64py-0.2.3-r2 ~amd64
+=dev-libs/d0_blind_id-1.0 ~amd64
+=games-misc/rfksay-0.1-r1 ~amd64
+=games-misc/funny-manpages-1.3_rc5-r1 ~amd64
+=games-emulation/mupen64plus-2.5 ~amd64
+=gnustep-base/gnustep-make-2.7.0 ~amd64 # Trying to fix Obj-C setup error… https://pouet.it/@lanodan_tmp/99248554766667217
+=gnustep-base/libobjc2-1.8.1 ~amd64
+=sys-devel/slibtool-0.5.17 ~amd64
+
+=net-misc/cadaver-0.23.3 ~amd64
+=app-misc/khard-0.11.4 ~amd64
+=dev-python/vdirsyncer-0.16.0-r1 ~amd64
+=dev-python/vobject-0.9.5 ~amd64
+=dev-python/requests-toolbelt-0.8.0 ~amd64
+=dev-python/atomicwrites-1.1.5-r2 ~amd64
+=dev-python/click-threading-0.3.0 ~amd64
+=dev-python/click-log-0.1.8 ~amd64
+=app-misc/khal-0.9.7 ~amd64
+
+=dev-python/freezegun-0.3.9 ~amd64
+=net-misc/pussh-9999::lanodanOverlay **
+
+=www-client/netsurf-3.6 ~amd64
+=media-libs/libnsbmp-0.1.4 ~amd64
+=dev-libs/libcss-0.7.0 ~amd64
+=dev-libs/libcss-0.6.1 ~amd64
+=media-libs/libnspsl-0.1.2 ~amd64
+=dev-libs/nsgenbind-0.5 ~amd64
+=dev-libs/libnsutils-0.0.3 ~amd64
+=media-libs/libnsgif-0.2.0 ~amd64
+=dev-libs/libnsfb-0.1.6 ~amd64
+=dev-libs/libwapcaplet-0.4.0 ~amd64
+=dev-libs/libutf8proc-1.3.1_p3 ~amd64
+=net-libs/libdom-0.3.2 ~amd64
+=media-libs/librosprite-0.1.2-r1 ~amd64
+=media-libs/libsvgtiny-0.1.6 ~amd64
+
+=games-board/gnushogi-1.4.1-r1 ~amd64
+=games-board/xboard-4.8.0-r1 ~amd64
+
+=dev-python/sip-4.19.6 ~amd64
+=sys-kernel/genkernel-3.5.2.5 ~amd64
+=app-misc/pax-utils-1.2.2-r2 ~amd64
+sys-firmware/intel-microcode ~*
+=media-gfx/opentoonz-1.2.0 ~amd64
+=media-gfx/brlcad-7.24.2 ~amd64
+=sci-libs/tnt-3.0.12 ~amd64
+=games-action/bzflag-2.4.12 ~amd64
+=sys-apps/fwupdate-9 ~amd64
+=sys-apps/fwts-17.02.00 ~amd64
+=dev-python/pyliblzma-0.5.3-r1 ~amd64
+=sys-apps/fwupd-1.0.3 ~amd64
+
+=media-plugins/calf-0.0.60-r1 ~amd64
+=media-sound/lmms-1.2.0_rc4 ~amd64
+=games-engines/scummvm-tools-2.0.0-r1 ~amd64
+=mail-mta/sendmail-8.14.9-r1 ~amd64
+=dev-libs/cyrus-sasl-2.1.26-r11 ~amd64
+=mail-mta/opensmtpd-6.0.2_p1-r2 ~amd64
+=net-misc/stunnel-5.44 ~*
+media-fonts/fontawesome ~amd64
+=media-plugins/gst-plugins-zbar-1.12.3 ~amd64
+=net-dns/getdns-1.3.0 ~amd64
+=dev-haskell/qtah-qt5-0.4.0 ~amd64
+=dev-haskell/hoppy-std-0.3.0 ~amd64
+=dev-haskell/qtah-generator-0.3.0 ~amd64
+=dev-haskell/hoppy-runtime-0.4.0 ~amd64
+=dev-haskell/qtah-cpp-qt5-0.4.0 ~amd64
+=dev-haskell/hoppy-generator-0.3.3 ~amd64
+=dev-haskell/hoppy-generator-0.4.0 ~amd64
+=dev-haskell/hoppy-std-0.4.0 ~amd64
+=dev-haskell/qtah-generator-0.2.1 ~amd64
+=dev-haskell/hoppy-generator-0.2.0 ~amd64
+=dev-haskell/hoppy-std-0.2.0 ~amd64
+=dev-haskell/qtah-generator-0.1.2 ~amd64
+=dev-embedded/esptool-2.2 ~*
+=media-sound/sfxr-1.2.1 ~amd64
+=dev-python/firmtool-1.3 ~amd64
+games-visualnovel/doki-doki-litterature-club ~amd64
+=net-libs/serf-1.3.9 ~amd64
+=dev-lua/lpeg-1.0.1 ~amd64
+=net-misc/ntpsec-1.0.0-r2 ~amd64
+=app-editors/kakoune-0_pre20171120 ~amd64
+mail-client/mutt ~*
+=app-i18n/uim-1.8.6-r2 ~*
+=net-vpn/wireguard-0.0.20180304 ~amd64
+=dev-cpp/luabind-0.9 ~amd64
+app-admin/pass-otp::gentoo ~*
+<dev-util/svgo-9999 ~*
+=dev-ruby/nokogumbo-1.5.0 ~amd64
+=dev-libs/gumbo-0.10.1 ~amd64
+dev-libs/libsass ~*
+=net-misc/ntpsec-1.0.0-r6 ~amd64
+=dev-lang/erlang-20.3 ~*
+=games-misc/bsd-games-2.17-r5 ~amd64
+# required by app-text/base91-2.0.0::lanodanOverlay
+=dev-haskell/mono-traversable-1.0.8.1 ~amd64
+=dev-haskell/vector-th-unbox-0.2.1.6 ~amd64
+=dev-haskell/math-functions-0.2.1.0 ~amd64
+=dev-haskell/mwc-random-0.13.6.0 ~amd64
+=dev-haskell/vector-algorithms-0.7.0.1-r1 ~amd64
+=x11-misc/slop-7.4 ~amd64
+dev-util/cargo::libressl ~*
+=games-arcade/tinymania-9999 **
+
+=sys-fs/zfs-auto-snapshot-1.2.4 ~amd64
+dev-lang/elixir ~amd64
+
+=www-plugins/browserpass-2.0.21 ~amd64
+=dev-libs/nss-3.37 ~amd64
+=dev-util/cargo-0.27.0 ~amd64
+=dev-libs/granite-0.5.0 ~amd64
+media-gfx/gmic::4nykey ~*
+=media-libs/cimg-2.2.3 ~amd64
+=media-fonts/ahem-1.0 ~amd64
+=media-libs/cimg-2.3.1 ~amd64
+app-misc/neofetch ~*
+~media-gfx/maim-5.5.1 ~amd64
+=dev-libs/libb64-1.2.1 ~amd64
+=dev-util/sysdig-0.21.0 ~amd64
+=sys-devel/lld-6.0.1 ~amd64
+=dev-util/lldb-6.0.1 ~amd64
+dev-lang/rust:stable ~*
+app-portage/gverify ~*
+=dev-libs/nss-3.38 ~amd64
+=dev-libs/nspr-4.19 ~amd64
+=dev-util/cargo-0.29.0 ~amd64
+=www-client/luakit-2017.08.10 ~amd64
+www-client/luakit **
+=games-arcade/osu-lazer-9999.999.9 ~amd64
+=games-arcade/crack-attack-1.1.14-r2 ~amd64
+=dev-lang/python-3.7.0 ~amd64
+=app-misc/g810-led-0.2.7 ~amd64
+=media-video/ffmpeg-4.0.2 ~amd64
+=app-text/mandoc-1.14.4 ~amd64
+net-im/gajim::tastytea ~*
+=dev-perl/Crypt-OpenSSL-ECDSA-0.80.0 ~amd64
+=dev-perl/Crypt-OpenSSL-EC-1.310.0 ~amd64
+net-vpn/i2pd ~amd64
+=dev-cpp/websocketpp-0.8.1 ~amd64
+
+=games-strategy/freeciv-2.6.0 ~amd64
+=dev-go/go-tools-0_pre20180817 ~amd64
+=dev-go/go-text-0.3.0 ~amd64
+=dev-go/go-crypto-0_pre20180816 ~amd64
+=dev-go/go-net-0_pre20180816 ~amd64
+=dev-go/go-sys-0_pre20180816 ~amd64
+games-emulation/pcsxr ~*
+dev-qt/qtnetwork::libressl ~*
+media-fonts/twemoji-color-font::jorgicio ~*
+net-misc/youtube-dl ~*
+=dev-python/phonenumbers-8.3.1 ~amd64
+=dev-python/arrow-0.12.1 ~amd64
+=dev-python/py-gfm-0.1.1 ~amd64
+=dev-python/humanize-0.5.1 ~amd64
+=virtual/gradle-0 ~amd64
+=app-eselect/eselect-gradle-0.1 ~amd64
+=dev-util/meson-0.48.2 ~amd64
+=app-text/scdoc-1.5.2 ~amd64
+=dev-libs/json-c-0.13.1-r1 ~amd64
+# move dev-libs/wlroots gui-libs/wlroots
+gui-libs/wlroots ~amd64
+# move dev-libs/sway gui-wm/sway
+gui-wm/sway ~amd64
+=games-board/mah-jong-1.14-r1 ~amd64
+
+sys-libs/netbsd-csu ~*
+gnustep-base/gnustep-base ~*
+=games-emulation/snes9x-1.58 ~amd64
+=games-emulation/higan-106_p1-r1 ~amd64
+=x11-libs/pixman-0.36.0 ~*
+=games-puzzle/pingus-0.7.6-r1 ~amd64
+=media-fonts/polarsys-b612-fonts-1.003 ~amd64
+=dev-python/cssutils-1.0.2 ~amd64
+=dev-python/precis-i18n-1.0.0 ~amd64
+=dev-python/python-axolotl-curve25519-0.4.1_p2-r1 ~amd64
+=dev-python/python-axolotl-0.1.42-r1 ~amd64
+=media-video/ffmpeg-4.1.1 ~amd64
+=dev-libs/openssl-1.0.2q-r200 ~amd64
+~dev-python/pipenv-9.0.0 ~*
+=dev-python/pythonz-bd-1.11.4 ~amd64
+=dev-python/pew-1.1.1 ~amd64
+=dev-python/shutilwhich-1.1.0 ~amd64
+=dev-python/resumable-urlretrieve-0.1.5 ~amd64
+=dev-python/m2crypto-0.31.0-r1 ~*
+=gui-apps/swaylock-1.3 ~amd64
+=gui-apps/swayidle-1.2 ~amd64
+=app-text/scdoc-1.9.3-r1 ~amd64
+=dev-libs/libgit2-0.28.1 ~*
+=dev-python/pygit2-0.27.4 ~*
+<dev-libs/libgit2-0.28.0 ~*
+=dev-python/weasyprint-43 ~amd64
+=dev-python/cairocffi-1.0.2 ~amd64
+=dev-python/cssselect2-0.2.0 ~amd64
+=dev-python/stripe-2.10.1 ~amd64
+=www-plugins/lightspark-0.8.1 ~amd64
+
+sys-apps/apparmor-utils ~amd64
+sys-libs/libapparmor ~amd64
+sys-apps/apparmor ~amd64
+sec-policy/apparmor-profiles ~amd64
+=app-text/mupdf-1.14.0-r3 ~*
+=dev-haskell/data-flags-0.0.3.4 ~amd64
+=dev-haskell/hayland-0.1.0.1 ~amd64
+=dev-haskell/utility-ht-0.0.14 ~amd64
+=dev-haskell/storable-record-0.0.4 ~amd64
+~sys-devel/llvm-6.0.1 ~*
+=dev-util/meson-0.49.2 ~*
+~x11-libs/libdrm-2.4.97 ~* # Required by x11-drivers/xf86-video-nouveau (apparently)
+<media-plugins/gst-plugins-libav-1.14.5 ~*
+=x11-libs/gtk+-3.24.7 ~*
+=dev-haskell/composition-1.0.2.1 ~amd64
+<dev-haskell/c2hs-0.28.7::haskell ~*
+=dev-haskell/language-c-0.8.2 ~amd64
+
+=dev-haskell/hsroots-9999::lanodanOverlay **
+=dev-haskell/wayland-scanner-9999::lanodanOverlay **
+=dev-haskell/libinput-9999::lanodanOverlay **
+=dev-haskell/hayland-9999::lanodanOverlay **
+=gui-wm/waymonad-9999::lanodanOverlay **
+=dev-haskell/waymonad-scanner-9999::lanodanOverlay **
+=dev-haskell/xkbcommon-9999::lanodanOverlay **
+
+=dev-haskell/profunctors-5.2.2-r1 ~amd64
+=dev-haskell/xdg-basedir-0.2.2 ~amd64
+=dev-haskell/kan-extensions-5.2 ~amd64
+=dev-haskell/config-value-0.6.3.1 ~amd64
+=dev-haskell/async-2.2.1-r1 ~amd64
+=dev-haskell/unliftio-0.2.10 ~amd64
+=dev-haskell/config-schema-0.5.0.1-r1 ~amd64
+=dev-haskell/unliftio-core-0.1.2.0 ~amd64
+=dev-haskell/th-abstraction-0.2.11.0 ~amd64
+=dev-haskell/stm-2.5.0.0 ~amd64
+=dev-haskell/formatting-6.3.4 ~amd64
+=dev-haskell/invariant-0.5.1 ~amd64
+=dev-haskell/stm-2.4.5.0 ~amd64
+media-fonts/unifont::gentoo ~*
+media-fonts/symbola::gentoo ~*
+media-fonts/symbola::flussence ~*
+=kde-plasma/breeze-gtk-5.15.4 ~*
+=www-client/badwolf-9999 **
+=net-dns/c-ares-1.15.0 ~amd64
+=net-libs/nghttp2-1.37.0 ~amd64
+=net-libs/http-parser-2.9.0-r1 ~amd64
+=dev-libs/libuv-1.27.0 ~amd64
+dev-haskell/cpphs ~*
+=x11-terms/st-0.8.2 ~*
+=media-libs/libpng-1.6.36 ~*
+x11-drivers/xf86-video-nouveau ~*
+media-libs/mesa ~*
+~sys-devel/llvmgold-7 ~amd64
+~sys-devel/llvm-7.0.1 ~amd64
diff --git a/package.env/badwolf b/package.env/badwolf
@@ -0,0 +1 @@
+www-client/badwolf badwolf+
\ No newline at end of file
diff --git a/package.env/debug b/package.env/debug
@@ -0,0 +1 @@
+=net-misc/openssh-7.7_p1-r9::gentoo debug
diff --git a/package.env/fPIC b/package.env/fPIC
@@ -0,0 +1 @@
+=x11-misc/redshift-1.12::gentoo fPIC
diff --git a/package.env/gcc b/package.env/gcc
@@ -0,0 +1,37 @@
+=app-accessibility/julius-4.3.1::lanodanOverlay gcc
+=app-misc/lirc-0.9.0-r6::gentoo gcc
+=app-text/libetonyek-0.1.6::gentoo gcc
+=dev-db/postgis-2.4.2::gentoo gcc
+=dev-libs/cyrus-sasl-2.1.26-r11::gentoo gcc
+=dev-libs/elfutils-0.170-r1::gentoo gcc
+=dev-libs/fribidi-0.19.6::gentoo gcc
+=dev-libs/libclc-0.2.0_pre20160921::gentoo gcc
+=dev-libs/libgcrypt-1.8.1::gentoo gcc
+=dev-libs/libgcrypt-1.8.1::lanodanOverlay gcc
+=dev-libs/libmimeapps-9999::lanodanOverlay gcc
+=dev-util/android-tools-6.0.1_p79::gentoo gcc
+=dev-util/cargo-0.29.0::gentoo gcc
+=media-gfx/blender-2.72b-r4::gentoo gcc
+=media-gfx/gmic-2.0.0::gentoo gcc
+=media-libs/aalib-1.4_rc5-r6::gentoo gcc
+=media-libs/devil-1.7.8-r2 gcc
+=net-wireless/crda-3.18-r1::gentoo gcc
+=sci-biology/ugene-1.20.0::science gcc
+=sys-apps/linux-misc-apps-4.4-r1::gentoo gcc
+=sys-boot/syslinux-6.04_pre1::gentoo gcc
+=sys-devel/gcc-7.3.0-r3:7.3.0/7.3.0::gentoo gcc
+=sys-firmware/seabios-1.10.1::gentoo gcc
+=sys-firmware/seabios-1.10.2::gentoo gcc
+=sys-libs/glibc-2.27-r6:2.2/2.2::gentoo gcc
+=x11-libs/fltk-1.3.3-r3::gentoo gcc
+=x11-libs/gtk+-2.24.31-r1::gentoo gcc
+=app-misc/g810-led-0.3.1::lanodanOverlay gcc
+=app-misc/g810-led-0.3.1::gentoo gcc
+=dev-libs/openssl-0.9.8z_p8-r1::gentoo gcc
+=sys-apps/busybox-1.29.3::gentoo gcc
+=app-emulation/xen-tools-4.10.3-r2::gentoo gcc
+=www-plugins/lightspark-0.8.1::gentoo gcc
+=sys-apps/apparmor-2.13.2::gentoo gcc
+=sys-libs/glibc-2.28-r5::gentoo gcc
+=app-shells/mksh-57-r1 gcc
+=media-libs/mesa-18.3.6::gentoo gcc
diff --git a/package.env/gcc-ar b/package.env/gcc-ar
@@ -0,0 +1,4 @@
+=sys-libs/timezone-data-2017c::gentoo gcc-ar
+app-text/pandoc gcc-ar
+=net-libs/libnet-1.0.2a-r5::gentoo gcc-ar
+dev-haskell/* gcc-ar
diff --git a/package.env/gcc-as b/package.env/gcc-as
@@ -0,0 +1,4 @@
+=app-emulation/qemu-2.10.1-r1::gentoo gcc-as
+=app-emulation/qemu-3.1.0-r1::gentoo gcc-as
+
+=app-emulation/qemu-3.1.0-r4::gentoo gcc-as
diff --git a/package.env/gcc-haskell b/package.env/gcc-haskell
@@ -0,0 +1,7 @@
+dev-haskell/* gcc
+x11-misc/xmobar gcc
+x11-drivers/nvidia-drivers gcc
+x11-wm/xmonad* gcc
+app-text/pandoc gcc
+dev-util/shellcheck gcc
+gui-wm/waymonad gcc
diff --git a/package.env/gcc-stdc11-bugs b/package.env/gcc-stdc11-bugs
@@ -0,0 +1 @@
+=app-text/stardict-3.0.6-r3 gcc
diff --git a/package.env/gcc-tmp b/package.env/gcc-tmp
@@ -0,0 +1,5 @@
+sys-devel/clang:6 gcc
+sys-devel/llvm:6 gcc
+=media-libs/mesa-18.2.8::gentoo gcc
+=media-libs/mesa-18.3.5::gentoo gcc
+=media-libs/mesa-19.0.0 gcc
diff --git a/package.env/latomic b/package.env/latomic
@@ -0,0 +1,2 @@
+=media-libs/mesa-17.2.8::gentoo latomic
+=media-libs/mesa-17.3.9::gentoo latomic
diff --git a/package.env/libstdcxx b/package.env/libstdcxx
@@ -0,0 +1 @@
+=sys-devel/gcc-6.4.0::gentoo libstdcxx
diff --git a/package.env/libtool b/package.env/libtool
@@ -0,0 +1,2 @@
+=sys-devel/gcc-7.2.0::gentoo libtool
+=sys-devel/gcc-6.4.0::gentoo libtool
diff --git a/package.env/log_disable_0 b/package.env/log_disable_0
@@ -0,0 +1 @@
+net-libs/webkit-gtk log_disable_0
diff --git a/package.license b/package.license
@@ -0,0 +1,28 @@
+sys-kernel/linux-firmware linux-firmware no-source-code freedist
+media-sound/milkytracker AIFFWriter.m
+sys-firmware/nvidia-firmware NVIDIA-r2
+media-fonts/kochi-substitute free-noncomm
+>=dev-util/plan9port-20140306-r3 9base BigelowHolmes
+media-libs/fmod fmod
+>=net-misc/drawterm-9999 9base
+games-action/lugaru free-noncomm
+x11-drivers/nvidia-drivers NVIDIA-r2
+=media-gfx/nvidia-cg-toolkit-3.1.0013-r3 NVIDIA-r1
+=dev-util/nvidia-cuda-sdk-8.0.61 CUDPP
+=dev-util/nvidia-cuda-toolkit-8.0.61 NVIDIA-CUDA
+sys-kernel/gentoo-sources freedist linux-firmware
+games-misc/funny-manpages freedist
+games-misc/katawa-shoujo CC-BY-NC-ND-3.0
+games-roguelike/zangband Moria
+games-arcade/bloboats CC-Sampling-Plus-1.0
+=app-doc/single-unix-specification-4_p2 sus4-copyright
+www-plugins/adobe-flash AdobeFlash-11.x
+=app-text/dictd-1.12.1-r2 ISOC-rfc
+sys-firmware/intel-microcode intel-ucode
+media-libs/urt free-noncomm
+app-accessibility/julius julius
+games-visualnovel/doki-doki-litterature-club all-rights-reserved
+games-arcade/stepmania CC-BY-NC-4.0
+games-arcade/oshu CC-BY-NC-4.0
+games-arcade/osu-lazer CC-BY-NC-4.0
+games-emulation/snes9x Snes9x
diff --git a/package.mask/NOPE b/package.mask/NOPE
@@ -0,0 +1,3 @@
+media-sound/audacity # See https://social.hacktivis.me/objects/08872b3a-a670-49b3-94d8-2181642329f5
+media-fonts/firacode # unreadable ligatures, anti-dyslexia
+dev-util/electron
dev-util/electron
diff --git a/package.mask/fails b/package.mask/fails
@@ -0,0 +1 @@
+=media-gfx/exiv2-0.26_p20180319::gentoo
diff --git a/package.mask/libressl b/package.mask/libressl
@@ -0,0 +1,3 @@
+dev-libs/openssl:0
+=net-libs/nodejs-6.11.5
+net-libs/nodejs::gentoo
diff --git a/package.mask/libtool b/package.mask/libtool
@@ -0,0 +1 @@
+<sys-devel/libtool-2.4.3-r2
diff --git a/package.mask/nvidia-drivers b/package.mask/nvidia-drivers
@@ -0,0 +1 @@
+>=x11-drivers/nvidia-drivers-341.0.0
diff --git a/package.mask/oldcrypto b/package.mask/oldcrypto
@@ -0,0 +1 @@
+dev-perl/Crypt-OpenSSL-DSA
diff --git a/package.mask/openrc b/package.mask/openrc
@@ -0,0 +1,3 @@
+<sys-apps/openrc-0.13.0
+<sys-process/procps-3.3.9-r2
+sys-apps/sysvinit
diff --git a/package.mask/perl b/package.mask/perl
@@ -0,0 +1 @@
+<dev-lang/perl-5.18.0
diff --git a/package.unmask b/package.unmask
@@ -0,0 +1,5 @@
+=app-eselect/eselect-wine-1.5-r1
+sys-kernel/hardened-sources
+dev-libs/openssl::lanodanOverlay
+=media-video/ffmpeg-4.0.2
+=media-video/mpv-0.29.0
diff --git a/package.use/01-deps b/package.use/01-deps
@@ -0,0 +1,72 @@
+app-crypt/gcr gtk
+app-crypt/qca qt5
+app-text/poppler cairo qt5
+app-text/texlive extra # doxygen
+app-text/xmlto text
+dev-db/mariadb -openssl
+dev-db/sqlite secure-delete
+dev-lang/python sqlite
+=dev-lang/ruby-2.1.9 -ssl
+dev-libs/glib dbus
+dev-libs/libdbusmenu gtk3
+dev-libs/libdnet python # ooni-probe
+dev-libs/libindicate gtk
+dev-libs/libpcre2 pcre16
+dev-libs/libpcre pcre16 pcre32
+dev-libs/libusb udev
+dev-libs/libxml2 python
+dev-libs/protobuf python # mypaint
+dev-libs/xmlsec nss
+dev-lua/lpeg -luajit
+dev-python/pillow tiff # adfko
+dev-python/PyQt5 declarative webkit multimedia gui network widgets printsupport
+dev-python/PyQt5 sql -webkit # =www-client/qutebrowser
+dev-python/PyQt5 svg # app-misc/anki
+dev-python/twisted conch
+dev-qt/qtcore icu #kde-frameworks/kcoreaddons
+dev-qt/qtmultimedia widgets
+dev-qt/qtscript scripttools # sci-biology/ugene
+dev-qt/qtwebengine widgets
+dev-qt/qtwebkit qml
+gnustep-base/gnustep-make libobjc2
+gnustep-base/gnustep-make native-exceptions # app-arch/unar-1.10.1::lanodanOverlay
+media-gfx/gmic qt5 opencv fftw
+media-gfx/imagemagick svg
+media-gfx/pstoedit plotutils # media-gfx/inkscape[latex]
+media-libs/devil tiff mng allegro
+media-libs/freetype fontforge
+media-libs/gst-plugins-base theora
+media-libs/harfbuzz icu
+media-libs/libmikmod openal # app-misc/bb
+media-libs/libpng apng
+media-libs/libsdl2 opengl
+media-libs/libvpx svc postproc
+media-libs/mesa gles2
+media-libs/opencv gstreamer # media-gfx/gmic-2.2.3::4nykey[v4l]
+media-libs/sdl2-image png gif jpeg webp
+media-libs/sdl2-mixer flac mad mp3 mod mikmod vorbis
+media-libs/speex ogg
+media-video/ffmpeg openssl
+net-ftp/ftp -ssl
+net-libs/libdom xml
+net-libs/nodejs bundled-ssl
+net-wireless/lorcon python # aircrack-ng
+sci-visualization/gnuplot wxwidgets
+sys-apps/util-linux static-libs
+sys-auth/consolekit policykit
+sys-devel/clang xml
+sys-fs/cryptsetup udev
+#sys-libs/libcxxabi -libunwind # conflicts with {llvm-,}libunwind (used by google-perftools)
+#sys-libs/libcxx -libunwind # conflicts with {llvm-,}libunwind (used by google-perftools)
+sys-libs/zlib minizip # required by www-client/chromium-60.0.3112.78::gentoo
+sys-libs/zlib static-libs
+sys-process/lsof rpc
+virtual/libusb udev
+www-client/w3m imlib
+x11-base/xorg-server xvfb
+x11-libs/cairo xcb # dev-libs/weston[xwayland]
+x11-libs/goffice gnome
+x11-libs/libxcb xkb
+app-accessibility/brltty python
+dev-libs/liblouis python
+app-accessibility/speech-dispatcher python
diff --git a/package.use/01.1-repair b/package.use/01.1-repair
@@ -0,0 +1,3 @@
+=dev-lang/ghc-8.0.2 binary
+media-libs/mesa -vulkan # Intel or AMD GPU required
+dev-python/passlib -scrypt # dev-python/scrypt current wants OpenSSL only
diff --git a/package.use/02-user b/package.use/02-user
@@ -0,0 +1,127 @@
+app-accessibility/espeak portaudio
+app-admin/pass dmenu
+app-crypt/gnupg doc tofu tools usb
+app-crypt/pinentry qt5
+app-dicts/stardict-* gzip
+app-editors/vim lua python perl lpeg
+app-emulation/lxc examples
+app-emulation/lxd -dnsmasq
+app-emulation/qemu gtk sdl sdl2 usb -vnc virgl spice
+app-emulation/wine* dos -udisks
+app-emulation/xen-tools -qemu # disable building bundled-qemu
+app-i18n/uim gtk qt5
+app-misc/anki -recording -sound
+app-misc/beep suid
+app-misc/g810-led -hidapi
+app-office/gnucash ofx quotes chipcard # hbci: Needs openssl
+app-office/gnumeric perl python
+app-office/libreoffice gtk3
+app-portage/layman sync-plugin-portage
+app-text/dictd minimal
+app-text/mupdf -openssl -curl
+app-text/stardict espeak tools
+app-text/texlive* graphics science xetex epspdf metapost tex4ht
+app-text/zathura-meta cb
+dev-db/postgresql uuid doc
+dev-db/sqlite tools
+dev-lang/erlang dirty-schedulers tk wxwidgets
+dev-lang/luajit lua52compat
+dev-lang/python tk
+dev-lang/ruby -rdoc
+dev-lang/rust clang libcxx
+dev-libs/capstone python
+dev-libs/libgcrypt o-flag-munging
+dev-libs/nss utils
+dev-libs/openct usb
+dev-libs/opensc openct secure-messaging
+dev-libs/openssl-bad -kerberos sctp sslv3
+dev-libs/openssl -tls-heartbeat
+dev-libs/weston wayland-compositor xwayland
+dev-qt/qtmultimedia gstreamer
+dev-qt/qtwebkit -gstreamer multimedia printsupport
+dev-scheme/racket doc -futures # needs USE=jit, disabled for hardening
+dev-tex/tex4ht java
+dev-util/ninja:virtual samurai
+dev-util/plan9port truetype
+dev-util/sysdig modules
+games-arcade/savagewheels fmod sound
+games-board/xboard gtk
+games-emulation/dosbox opengl
+games-emulation/pcsxr -sdl
+games-puzzle/pingus music
+games-rpg/manaplus opengl
+gnustep-base/gnustep-base -gnutls # I prefer libressl over gnutls
+gui-wm/sway wallpapers
+mail-client/claws-mail calendar sieve smime
+mail-client/mutt gpg gpgme idn imap nntp smtp sidebar
+media-gfx/brlcad examples
+media-gfx/fontforge cairo gtk svg truetype-debugger
+media-gfx/gmic gimp graphicsmagick krita cli
+media-gfx/graphicsmagick svg postscript
+media-gfx/inkscape imagemagick jpeg postscript wpg
+media-gfx/krita fftw pdf
+media-libs/freetype utils
+media-libs/libsdl2 dbus haptic static-libs udev
+media-libs/mlt ffmpeg xml sdl qt5 kdenlive melt
+media-libs/phonon -vlc
+media-libs/sdl-mixer flac mp3 vorbis mad
+media-libs/sdl-sound flac mikmod mp3
+media-plugins/gst-plugins-meta aac flac modplug mp3 ogg opus vpx http libass wavpack x264 mpeg theora ffmpeg
+media-sound/lmms fluidsynth ogg sdl
+media-sound/ncmpc search-screen song-screen artist-screen
+media-sound/sbagen mp3 vorbis
+media-video/ffmpeg alsa gnutls libass libdrm mp3 opus vorbis vpx x265 sdl
+media-video/mpv drm dvd lcms tools vaapi archive cli
+net-analyzer/wireshark tfshark lua -gtk
+net-dns/getdns stubby
+net-libs/gnutls tools
+net-libs/webkit-gtk examples jit -gles2 -libnotify -webgl
+net-misc/aria2 bittorrentnet-misc/ntpsec early
+net-misc/dhcp -client
+net-misc/iputils rarpd
+net-misc/ofono examples tools
+net-misc/openssh -X
+net-p2p/bitcoin-qt qt5 bitcoin_policy_spamfilter bip148
+net-vpn/openvpn iproute2 lz4
+net-wireless/wpa_supplicant qt5 ap
+sci-astronomy/stellarium stars
+sci-libs/libticables2 usb
+sci-mathematics/maxima sbcl tk
+sci-visualization/gnuplot examples
+sys-apps/firejail x11
+sys-apps/groff -X
+sys-apps/smartmontools -daemon -caps
+sys-boot/grub device-mapper
+sys-devel/clang default-compiler-rt default-libcxx
+sys-devel/clang-runtime crt
+sys-devel/llvm clang
+=sys-firmware/edk2-ovmf-2017_pre20170505 binary # Fails to build, needs patch for -fPIC
+sys-fs/ecryptfs-utils gpg
+sys-fs/lvm2 -thin
+sys-libs/libomp hwloc ompt
+sys-process/psmisc -X
+virtual/ffmpeg sdl
+www-client/chromium -hangouts
+www-client/firefox rust
+www-client/luakit doc
+www-client/netsurf fbcon gtk gtk2 gtk3 fbcon_frontend_linux gstreamer
+www-client/seamonkey crypt -calendar -chatzilla -gmp-autoupdate gtk3
+www-plugins/gnash gtk sdl
+www-plugins/passff firefox
+www-plugins/passff-host firefox
+www-servers/uwsgi python
+x11-drivers/nvidia-drivers -tools
+x11-libs/gtk+:3 examples gtk-doc
+x11-libs/libvdpau dri
+x11-misc/xmobar wifi
+x11-terms/st -savedconfig # Now using patches instead
+x11-wm/dwm savedconfig
+x11-wm/xmonad -default-term
+x11-wm/xmonad* doc
+app-editors/vis lpeg lua
+media-plugins/gst-plugins-meta mp3 mpeg ogg opus theora vorbis vpx wavpack x264 lame
+www-client/badwolf savedconfig
+x11-libs/gtk+ gtk-doc
+sys-apps/openrc init
+gui-wm/cage xwayland
+gui-libs/wlroots rootston x11-backend
diff --git a/package.use/04-constrait b/package.use/04-constrait
@@ -0,0 +1 @@
+dev-libs/opensc -pcsc-lite
diff --git a/package.use/05-no-python2 b/package.use/05-no-python2
@@ -0,0 +1,24 @@
+=dev-vcs/git-2.19.2::gentoo -python
+=dev-vcs/git-2.21.0::gentoo -python
+=dev-python/m2crypto-0.31.0-r1 python_targets_python2_7
+=dev-python/setuptools-40.6.3 python_targets_python2_7
+=dev-python/certifi-2018.4.16 python_targets_python2_7
+=virtual/python-typing-0-r1 python_targets_python2_7
+=dev-python/typing-3.6.2-r1 python_targets_python2_7
+=app-emulation/xen-tools-4.10.3-r2::gentoo python_targets_python2_7
+=dev-python/lxml-4.2.5 python_targets_python2_7
+=dev-python/pypam-0.5.0-r3 python_targets_python2_7
+=dev-python/bz2file-0.98::gentoo python_targets_python2_7
+=dev-python/pygtk-2.24.0-r4::gentoo python_targets_python2_7
+=dev-python/pygobject-2.28.6-r55::gentoo python_targets_python2_7
+=net-libs/nodejs-10.15.0::libressl python_targets_python2_7
+=dev-vcs/mercurial-4.9::gentoo python_targets_python2_7
+=games-engines/renpy-6.99.12.4-r3::gentoo python_targets_python2_7
+=dev-python/misaka-1.0.2::gentoo python_targets_python2_7
+=dev-python/rst2pdf-0.93-r3::gentoo python_targets_python2_7
+=dev-util/gtk-doc-1.25-r1::gentoo python_targets_python2_7
+=dev-util/itstool-2.0.2::gentoo python_targets_python2_7
+=x11-misc/arandr-0.1.9::gentoo python_targets_python2_7
+=sys-devel/clang-6.0.1::gentoo python_targets_python2_7
+=dev-python/pycairo-1.17.0-r1 python_targets_python2_7 # required by pygtk (argument)
+=net-libs/nodejs-10.15.3::libressl python_targets_python2_7
diff --git a/patches/app-editors/vis-0.4/619.patch b/patches/app-editors/vis-0.4/619.patch
@@ -0,0 +1,65 @@
+From b24be0909923f9f237accc98986128032d98b9db Mon Sep 17 00:00:00 2001
+From: Chris Rawnsley <chris@puny.agency>
+Date: Sun, 1 Oct 2017 20:32:12 +0100
+Subject: [PATCH] themes: add zenburn and make it the default 256 theme
+
+---
+ lua/themes/default-256.lua | 2 +-
+ lua/themes/zenburn.lua | 39 +++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 40 insertions(+), 1 deletion(-)
+ create mode 100644 lua/themes/zenburn.lua
+
+diff --git a/lua/themes/default-256.lua b/lua/themes/default-256.lua
+index 8479b1b5..e12776c0 120000
+--- a/lua/themes/default-256.lua
++++ b/lua/themes/default-256.lua
+@@ -1 +1 @@
+-solarized.lua
+\ No newline at end of file
++zenburn.lua
+\ No newline at end of file
+diff --git a/lua/themes/zenburn.lua b/lua/themes/zenburn.lua
+new file mode 100644
+index 00000000..f60e900f
+--- /dev/null
++++ b/lua/themes/zenburn.lua
+@@ -0,0 +1,39 @@
++-- A poor imitation of the original Vim colourscheme which can be
++-- found at https://github.com/jnurmine/Zenburn
++
++local lexers = vis.lexers
++
++lexers.STYLE_DEFAULT = 'fore:#d7d7d7,back:#3a3a3a'
++lexers.STYLE_NOTHING = ''
++lexers.STYLE_CLASS = ''
++lexers.STYLE_COMMENT = 'fore:#87af87'
++lexers.STYLE_CONSTANT = 'fore:#d7afaf,bold'
++lexers.STYLE_DEFINITION = 'fore:#ffd7af,bold'
++lexers.STYLE_ERROR = 'fore:#87d7af,back:#303030,bold'
++lexers.STYLE_FUNCTION = 'fore:#d7d7af'
++lexers.STYLE_KEYWORD = 'fore:#afaf87,bold'
++lexers.STYLE_LABEL = 'fore:#d7d7af'
++lexers.STYLE_NUMBER = 'fore:#87d7d7'
++lexers.STYLE_OPERATOR = 'fore:#ffffd7'
++lexers.STYLE_REGEX = ''
++lexers.STYLE_STRING = 'fore:#d78787'
++lexers.STYLE_PREPROCESSOR = 'fore:#ffd7af,bold'
++lexers.STYLE_TAG = 'fore:#d7afaf,bold'
++lexers.STYLE_TYPE = 'fore:#d7d7af,bold'
++lexers.STYLE_VARIABLE = ''
++lexers.STYLE_WHITESPACE = ''
++lexers.STYLE_EMBEDDED = ''
++lexers.STYLE_IDENTIFIER = ''
++
++lexers.STYLE_LINENUMBER = 'fore:#585858'
++lexers.STYLE_LINENUMBER_CURSOR = 'fore:#666666'
++lexers.STYLE_CURSOR = 'back:#585858'
++lexers.STYLE_CURSOR_PRIMARY = 'fore:#1c1c1c,back:#87afaf,bold'
++lexers.STYLE_CURSOR_LINE = 'back:#444444'
++lexers.STYLE_COLOR_COLUMN = 'back:#444444'
++lexers.STYLE_SELECTION = 'back:#5f875f'
++lexers.STYLE_STATUS = 'back:#262626,fore:#87af87'
++lexers.STYLE_STATUS_FOCUSED = 'back:#303030,fore:#afaf87,bold'
++lexers.STYLE_SEPARATOR = ''
++lexers.STYLE_INFO = ''
++lexers.STYLE_EOF = 'fore:#585858'
diff --git a/patches/app-editors/vis-0.4/vis-0.4-symbols.patch b/patches/app-editors/vis-0.4/vis-0.4-symbols.patch
@@ -0,0 +1,17 @@
+diff --git a/view.c b/view.c
+index fafabc5..c82384f 100644
+--- a/view.c
++++ b/view.c
+@@ -90,10 +90,10 @@ static const SyntaxSymbol symbols_none[] = {
+ };
+
+ static const SyntaxSymbol symbols_default[] = {
+- [SYNTAX_SYMBOL_SPACE] = { "·" /* Middle Dot U+00B7 */ },
++ [SYNTAX_SYMBOL_SPACE] = { "␣" /* Open Box U+2423 */ },
+ [SYNTAX_SYMBOL_TAB] = { "›" /* Single Right-Pointing Angle Quotation Mark U+203A */ },
+ [SYNTAX_SYMBOL_TAB_FILL] = { " " },
+- [SYNTAX_SYMBOL_EOL] = { "↵" /* Downwards Arrow with Corner Leftwards U+21B5 */ },
++ [SYNTAX_SYMBOL_EOL] = { "⏎" /* RETURN SYMBOL U+23CE */ },
+ [SYNTAX_SYMBOL_EOF] = { "~" },
+ };
+
diff --git a/patches/app-editors/vis-0.4/vis-0.4_ebuild_lexer.patch b/patches/app-editors/vis-0.4/vis-0.4_ebuild_lexer.patch
@@ -0,0 +1,107 @@
+diff --git a/lua/lexers/ebuild.lua b/lua/lexers/ebuild.lua
+new file mode 100644
+index 0000000..9ecb7d8
+--- /dev/null
++++ b/lua/lexers/ebuild.lua
+@@ -0,0 +1,87 @@
++-- Copyright 2006-2017 Mitchell mitchell.att.foicica.com. See LICENSE.
++-- Shell LPeg lexer.
++
++local l = require('lexer')
++local token, word_match = l.token, l.word_match
++local P, R, S = lpeg.P, lpeg.R, lpeg.S
++
++local M = {_NAME = 'ebuild'}
++
++-- Whitespace.
++local ws = token(l.WHITESPACE, l.space^1)
++
++-- Comments.
++local comment = token(l.COMMENT, '#' * l.nonnewline^0)
++
++-- Strings.
++local sq_str = l.delimited_range("'", false, true)
++local dq_str = l.delimited_range('"')
++local ex_str = l.delimited_range('`')
++local heredoc = '<<' * P(function(input, index)
++ local s, e, _, delimiter =
++ input:find('%-?(["\']?)([%a_][%w_]*)%1[\n\r\f;]+', index)
++ if s == index and delimiter then
++ local _, e = input:find('[\n\r\f]+'..delimiter, e)
++ return e and e + 1 or #input + 1
++ end
++end)
++local string = token(l.STRING, sq_str + dq_str + ex_str + heredoc)
++
++-- Numbers.
++local number = token(l.NUMBER, l.float + l.integer)
++
++-- Keywords.
++local keyword = token(l.KEYWORD, word_match({
++ -- Bash keywords
++ 'if', 'then', 'elif', 'else', 'fi', 'case', 'in', 'esac', 'while', 'for',
++ 'do', 'done', 'continue', 'local', 'return', 'select',
++ -- Ebuild keywords
++ 'use', 'has_version', 'best_version', 'use_width', 'use_enable',
++ 'keepdir', 'econf', 'die', 'einstall', 'einfo', 'ewarn', 'eerror', 'diropts',
++ 'dobin', 'docinto', 'dodoc', 'doexe', 'doheader', 'doinfo', 'doins',
++ 'dolib', 'dolib.a', 'dolib.so', 'doman', 'dosbin', 'dosym', 'emake', 'exeinto',
++ 'exeopts', 'fowners', 'fperms', 'insinto', 'insopts', 'into', 'libopts', 'newbin',
++ 'newexe', 'newheader', 'newins', 'newman', 'newsbin', 'has', 'unpack', 'into',
++ 'doinitd', 'doconfd', 'doenvd', 'domo', 'dodir', 'ebegin', 'eend',
++ 'newconfd', 'newdoc', 'newenvd', 'newinitd', 'newlib.a', 'newlib.so',
++ 'hasv', 'usev', 'usex', 'elog', 'eapply', 'eapply_user',
++ 'einstalldocs', 'in_iuse', 'get_libdir',
++ 'addread', 'addwrite', 'adddeny', 'addpredict',
++ -- Operators.
++ '-a', '-b', '-c', '-d', '-e', '-f', '-g', '-h', '-k', '-p', '-r', '-s', '-t',
++ '-u', '-w', '-x', '-O', '-G', '-L', '-S', '-N', '-nt', '-ot', '-ef', '-o',
++ '-z', '-n', '-eq', '-ne', '-lt', '-le', '-gt', '-ge'
++}, '-'))
++
++-- Identifiers.
++local identifier = token(l.IDENTIFIER, l.word)
++
++-- Variables.
++local variable = token(l.VARIABLE,
++ '$' * (S('!#?*@$') + l.digit^1 + l.word +
++ l.delimited_range('{}', true, true, true)))
++
++-- Operators.
++local operator = token(l.OPERATOR, S('=!<>+-/*^&|~.,:;?()[]{}'))
++
++M._rules = {
++ {'whitespace', ws},
++ {'keyword', keyword},
++ {'identifier', identifier},
++ {'string', string},
++ {'comment', comment},
++ {'number', number},
++ {'variable', variable},
++ {'operator', operator},
++}
++
++M._foldsymbols = {
++ _patterns = {'[a-z]+', '[{}]', '#'},
++ [l.KEYWORD] = {
++ ['if'] = 1, fi = -1, case = 1, esac = -1, ['do'] = 1, done = -1
++ },
++ [l.OPERATOR] = {['{'] = 1, ['}'] = -1},
++ [l.COMMENT] = {['#'] = l.fold_line_comments('#')}
++}
++
++return M
+diff --git a/lua/plugins/filetype.lua b/lua/plugins/filetype.lua
+index 52eef25..539513f 100644
+--- a/lua/plugins/filetype.lua
++++ b/lua/plugins/filetype.lua
+@@ -107,6 +107,9 @@ vis.ftdetect.filetypes = {
+ dsv = {
+ ext = { "group", "gshadow", "passwd", "shadow" },
+ },
++ ebuild = {
++ ext = { "%.ebuild$" },
++ },
+ eiffel = {
+ ext = { "%.e$", "%.eif$" },
+ },
diff --git a/patches/app-editors/vis-0.5/vis-0.4-symbols.patch b/patches/app-editors/vis-0.5/vis-0.4-symbols.patch
@@ -0,0 +1,13 @@
+diff --git a/view.c b/view.c
+index fafabc5..c82384f 100644
+--- a/view.c
++++ b/view.c
+@@ -90,6 +90,6 @@ static const SyntaxSymbol symbols_none[] = {
+ };
+
+ static const SyntaxSymbol symbols_default[] = {
+- [SYNTAX_SYMBOL_SPACE] = { "·" /* Middle Dot U+00B7 */ },
++ [SYNTAX_SYMBOL_SPACE] = { "␣" /* Open Box U+2423 */ },
+ [SYNTAX_SYMBOL_TAB] = { "›" /* Single Right-Pointing Angle Quotation Mark U+203A */ },
+ [SYNTAX_SYMBOL_TAB_FILL] = { " " },
+
diff --git a/patches/app-editors/vis-0.5/vis-0.4_ebuild_lexer.patch b/patches/app-editors/vis-0.5/vis-0.4_ebuild_lexer.patch
@@ -0,0 +1,107 @@
+diff --git a/lua/lexers/ebuild.lua b/lua/lexers/ebuild.lua
+new file mode 100644
+index 0000000..9ecb7d8
+--- /dev/null
++++ b/lua/lexers/ebuild.lua
+@@ -0,0 +1,87 @@
++-- Copyright 2006-2017 Mitchell mitchell.att.foicica.com. See LICENSE.
++-- Shell LPeg lexer.
++
++local l = require('lexer')
++local token, word_match = l.token, l.word_match
++local P, R, S = lpeg.P, lpeg.R, lpeg.S
++
++local M = {_NAME = 'ebuild'}
++
++-- Whitespace.
++local ws = token(l.WHITESPACE, l.space^1)
++
++-- Comments.
++local comment = token(l.COMMENT, '#' * l.nonnewline^0)
++
++-- Strings.
++local sq_str = l.delimited_range("'", false, true)
++local dq_str = l.delimited_range('"')
++local ex_str = l.delimited_range('`')
++local heredoc = '<<' * P(function(input, index)
++ local s, e, _, delimiter =
++ input:find('%-?(["\']?)([%a_][%w_]*)%1[\n\r\f;]+', index)
++ if s == index and delimiter then
++ local _, e = input:find('[\n\r\f]+'..delimiter, e)
++ return e and e + 1 or #input + 1
++ end
++end)
++local string = token(l.STRING, sq_str + dq_str + ex_str + heredoc)
++
++-- Numbers.
++local number = token(l.NUMBER, l.float + l.integer)
++
++-- Keywords.
++local keyword = token(l.KEYWORD, word_match({
++ -- Bash keywords
++ 'if', 'then', 'elif', 'else', 'fi', 'case', 'in', 'esac', 'while', 'for',
++ 'do', 'done', 'continue', 'local', 'return', 'select',
++ -- Ebuild keywords
++ 'use', 'has_version', 'best_version', 'use_width', 'use_enable',
++ 'keepdir', 'econf', 'die', 'einstall', 'einfo', 'ewarn', 'eerror', 'diropts',
++ 'dobin', 'docinto', 'dodoc', 'doexe', 'doheader', 'doinfo', 'doins',
++ 'dolib', 'dolib.a', 'dolib.so', 'doman', 'dosbin', 'dosym', 'emake', 'exeinto',
++ 'exeopts', 'fowners', 'fperms', 'insinto', 'insopts', 'into', 'libopts', 'newbin',
++ 'newexe', 'newheader', 'newins', 'newman', 'newsbin', 'has', 'unpack', 'into',
++ 'doinitd', 'doconfd', 'doenvd', 'domo', 'dodir', 'ebegin', 'eend',
++ 'newconfd', 'newdoc', 'newenvd', 'newinitd', 'newlib.a', 'newlib.so',
++ 'hasv', 'usev', 'usex', 'elog', 'eapply', 'eapply_user',
++ 'einstalldocs', 'in_iuse', 'get_libdir',
++ 'addread', 'addwrite', 'adddeny', 'addpredict',
++ -- Operators.
++ '-a', '-b', '-c', '-d', '-e', '-f', '-g', '-h', '-k', '-p', '-r', '-s', '-t',
++ '-u', '-w', '-x', '-O', '-G', '-L', '-S', '-N', '-nt', '-ot', '-ef', '-o',
++ '-z', '-n', '-eq', '-ne', '-lt', '-le', '-gt', '-ge'
++}, '-'))
++
++-- Identifiers.
++local identifier = token(l.IDENTIFIER, l.word)
++
++-- Variables.
++local variable = token(l.VARIABLE,
++ '$' * (S('!#?*@$') + l.digit^1 + l.word +
++ l.delimited_range('{}', true, true, true)))
++
++-- Operators.
++local operator = token(l.OPERATOR, S('=!<>+-/*^&|~.,:;?()[]{}'))
++
++M._rules = {
++ {'whitespace', ws},
++ {'keyword', keyword},
++ {'identifier', identifier},
++ {'string', string},
++ {'comment', comment},
++ {'number', number},
++ {'variable', variable},
++ {'operator', operator},
++}
++
++M._foldsymbols = {
++ _patterns = {'[a-z]+', '[{}]', '#'},
++ [l.KEYWORD] = {
++ ['if'] = 1, fi = -1, case = 1, esac = -1, ['do'] = 1, done = -1
++ },
++ [l.OPERATOR] = {['{'] = 1, ['}'] = -1},
++ [l.COMMENT] = {['#'] = l.fold_line_comments('#')}
++}
++
++return M
+diff --git a/lua/plugins/filetype.lua b/lua/plugins/filetype.lua
+index 52eef25..539513f 100644
+--- a/lua/plugins/filetype.lua
++++ b/lua/plugins/filetype.lua
+@@ -107,6 +107,9 @@ vis.ftdetect.filetypes = {
+ dsv = {
+ ext = { "group", "gshadow", "passwd", "shadow" },
+ },
++ ebuild = {
++ ext = { "%.ebuild$" },
++ },
+ eiffel = {
+ ext = { "%.e$", "%.eif$" },
+ },
diff --git a/patches/app-editors/vis-0.5/vis-0.5-match_quotes.patch b/patches/app-editors/vis-0.5/vis-0.5-match_quotes.patch
@@ -0,0 +1,22 @@
+diff --git a/vis-motions.c.old b/vis-motions.c
+index b72f280..781ee1f 100644
+--- a/vis-motions.c.old
++++ b/vis-motions.c
+@@ -181,7 +181,7 @@ static size_t window_nop(Vis *vis, Win *win, size_t pos) {
+ }
+
+ static size_t bracket_match(Text *txt, size_t pos) {
+- size_t hit = text_bracket_match_symbol(txt, pos, "(){}[]<>");
++ size_t hit = text_bracket_match_symbol(txt, pos, "(){}[]<>'\"");
+ if (hit != pos)
+ return hit;
+ char current;
+@@ -196,6 +196,8 @@ static size_t bracket_match(Text *txt, size_t pos) {
+ case ']':
+ case '<':
+ case '>':
++ case '\'':
++ case '"':
+ return it.pos;
+ }
+ text_iterator_byte_next(&it, NULL);
diff --git a/patches/app-text/enchant/enchant-1.6.1-Add-tag=CC.patch b/patches/app-text/enchant/enchant-1.6.1-Add-tag=CC.patch
@@ -0,0 +1,9 @@
+diff -u enchant-1.6.1.orig/configure enchant-1.6.1/configure
+--- enchant-1.6.1.orig/configure 2017-12-17 16:56:55.527440216 -0600
++++ enchant-1.6.1/configure 2017-12-17 16:56:28.533441941 -0600
+@@ -11038,7 +11038,7 @@
+ LIBTOOL_DEPS=$ltmain
+
+ # Always use our own libtool.
+-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
++LIBTOOL='$(SHELL) $(top_builddir)/libtool --tag=CC'
diff --git a/patches/dev-embedded/avrdude/avrdude-6.3_no-datetime.patch b/patches/dev-embedded/avrdude/avrdude-6.3_no-datetime.patch
@@ -0,0 +1,11 @@
+--- a/main.c 2017-11-09 13:40:44.251913289 +0000
++++ b/main.c 2017-11-09 13:41:40.659228746 +0000
+@@ -682,7 +682,7 @@
+ avrdude_message(MSG_NOTICE, "\n%s: Version %s, compiled on %s at %s\n"
+ "%sCopyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/\n"
+ "%sCopyright (c) 2007-2014 Joerg Wunsch\n\n",
+- progname, version, __DATE__, __TIME__, progbuf, progbuf);
++ progname, version, "Jan 13 1984", "12:30:30", progbuf, progbuf);
+ avrdude_message(MSG_NOTICE, "%sSystem wide configuration file is \"%s\"\n",
+ progbuf, sys_config);
+
diff --git a/patches/dev-haskell/cpphs-1.20.8/xkbcommon_fix.patch b/patches/dev-haskell/cpphs-1.20.8/xkbcommon_fix.patch
@@ -0,0 +1,14 @@
+https://github.com/malcolmwallace/cpphs/issues/16
+
+diff -rN -u old-cpphs/Language/Preprocessor/Cpphs/Tokenise.hs new-cpphs/Language/Preprocessor/Cpphs/Tokenise.hs
+--- old-cpphs/Language/Preprocessor/Cpphs/Tokenise.hs 2018-05-08 16:57:53.934565562 +0200
++++ new-cpphs/Language/Preprocessor/Cpphs/Tokenise.hs 2018-05-08 16:57:53.934565562 +0200
+@@ -204,6 +204,8 @@
+ lexcpp LineComment w l ls (_:xs) = lexcpp LineComment (' ':w) l ls xs
+ lexcpp (NestComment _) w l ls ('*':'/':xs)
+ = lexcpp Any [] (w*/*l) ls xs
++ lexcpp (NestComment _) w l ls xs@('\n':_)
++ = lexcpp Any [] (w*/*l) ls xs
+ lexcpp (NestComment n) w l ls (x:xs) = lexcpp (NestComment n) (white x:w) l
+ ls xs
+ lexcpp mode w l ((p,l'):ls) [] = cpp mode next w l p ls ('\n':l')
diff --git a/patches/dev-lang/nss/nss-3.33-no-datetime.patch b/patches/dev-lang/nss/nss-3.33-no-datetime.patch
@@ -0,0 +1,14 @@
+diff --git a/./lib/ckfw/pem/ckpemver.c.old b/./lib/ckfw/pem/ckpemver.c
+index 76ab5df..8600945 100644
+--- a/lib/ckfw/pem/ckpemver.c.old
++++ b/lib/ckfw/pem/ckpemver.c
+@@ -53,7 +53,7 @@
+ */
+ const char __nss_ckpem_rcsid[] = "$Header: NSS Access to Flat Files in PEM format"
+ NSS_CKPEM_LIBRARY_VERSION _DEBUG_STRING
+- " " __DATE__ " " __TIME__ " $";
++ " Jan 13 1984 12:30:30 $";
+ const char __nss_ckcapi_sccsid[] = "@(#)NSS Access to Flag Files in PEM format "
+ NSS_CKPEM_LIBRARY_VERSION _DEBUG_STRING
+- " " __DATE__ " " __TIME__;
++ " Jan 13 1984 12:30:30";
diff --git a/patches/dev-lang/python-2.7/python-2.7.12-no-compiler-version.patch b/patches/dev-lang/python-2.7/python-2.7.12-no-compiler-version.patch
@@ -0,0 +1,25 @@
+diff --git a/./Python/getcompiler.c.old b/./Python/getcompiler.c
+index 0f441de..df1e7d2 100644
+--- a/./Python/getcompiler.c.old
++++ b/./Python/getcompiler.c
+@@ -5,18 +5,10 @@
+
+ #ifndef COMPILER
+
+-#ifdef __GNUC__
+-#define COMPILER "\n[GCC " __VERSION__ "]"
+-#endif
+-
+-#endif /* !COMPILER */
+-
+-#ifndef COMPILER
+-
+ #ifdef __cplusplus
+-#define COMPILER "[C++]"
++#define COMPILER "[C++ 1.2.3]"
+ #else
+-#define COMPILER "[C]"
++#define COMPILER "[CC 1.2.3]"
+ #endif
+
+ #endif /* !COMPILER */
diff --git a/patches/dev-lang/python-2.7/python-2.7.12-no-datetime.patch b/patches/dev-lang/python-2.7/python-2.7.12-no-datetime.patch
@@ -0,0 +1,28 @@
+diff --git a/Modules/getbuildinfo.c.old b/Modules/getbuildinfo.c
+index 7069b6e..11d0674 100644
+--- a/Modules/getbuildinfo.c.old
++++ b/Modules/getbuildinfo.c
+@@ -4,21 +4,8 @@
+ #include <stdio.h>
+ #endif
+
+-#ifndef DATE
+-#ifdef __DATE__
+-#define DATE __DATE__
+-#else
+-#define DATE "xx/xx/xx"
++#define DATE "Jan 13 1984"
+-#endif
+-#endif
+-
+-#ifndef TIME
+-#ifdef __TIME__
+-#define TIME __TIME__
+-#else
+-#define TIME "xx:xx:xx"
++#define TIME "12:30:30"
+-#endif
+-#endif
+
+ /* on unix, SVNVERSION is passed on the command line.
+ * on Windows, the string is interpolated using
diff --git a/patches/dev-lang/python-3.4/python-2.7.12-no-compiler-version.patch b/patches/dev-lang/python-3.4/python-2.7.12-no-compiler-version.patch
@@ -0,0 +1,25 @@
+diff --git a/./Python/getcompiler.c.old b/./Python/getcompiler.c
+index 0f441de..df1e7d2 100644
+--- a/./Python/getcompiler.c.old
++++ b/./Python/getcompiler.c
+@@ -5,18 +5,10 @@
+
+ #ifndef COMPILER
+
+-#ifdef __GNUC__
+-#define COMPILER "\n[GCC " __VERSION__ "]"
+-#endif
+-
+-#endif /* !COMPILER */
+-
+-#ifndef COMPILER
+-
+ #ifdef __cplusplus
+-#define COMPILER "[C++]"
++#define COMPILER "[C++ 1.2.3]"
+ #else
+-#define COMPILER "[C]"
++#define COMPILER "[CC 1.2.3]"
+ #endif
+
+ #endif /* !COMPILER */
diff --git a/patches/dev-lang/python-3.4/python-2.7.12-no-datetime.patch b/patches/dev-lang/python-3.4/python-2.7.12-no-datetime.patch
@@ -0,0 +1,28 @@
+diff --git a/Modules/getbuildinfo.c.old b/Modules/getbuildinfo.c
+index 7069b6e..11d0674 100644
+--- a/Modules/getbuildinfo.c.old
++++ b/Modules/getbuildinfo.c
+@@ -4,21 +4,8 @@
+ #include <stdio.h>
+ #endif
+
+-#ifndef DATE
+-#ifdef __DATE__
+-#define DATE __DATE__
+-#else
+-#define DATE "xx/xx/xx"
++#define DATE "Jan 13 1984"
+-#endif
+-#endif
+-
+-#ifndef TIME
+-#ifdef __TIME__
+-#define TIME __TIME__
+-#else
+-#define TIME "xx:xx:xx"
++#define TIME "12:30:30"
+-#endif
+-#endif
+
+ /* on unix, SVNVERSION is passed on the command line.
+ * on Windows, the string is interpolated using
diff --git a/patches/dev-lang/python-3.5/python-2.7.12-no-compiler-version.patch b/patches/dev-lang/python-3.5/python-2.7.12-no-compiler-version.patch
@@ -0,0 +1,25 @@
+diff --git a/./Python/getcompiler.c.old b/./Python/getcompiler.c
+index 0f441de..df1e7d2 100644
+--- a/./Python/getcompiler.c.old
++++ b/./Python/getcompiler.c
+@@ -5,18 +5,10 @@
+
+ #ifndef COMPILER
+
+-#ifdef __GNUC__
+-#define COMPILER "\n[GCC " __VERSION__ "]"
+-#endif
+-
+-#endif /* !COMPILER */
+-
+-#ifndef COMPILER
+-
+ #ifdef __cplusplus
+-#define COMPILER "[C++]"
++#define COMPILER "[C++ 1.2.3]"
+ #else
+-#define COMPILER "[C]"
++#define COMPILER "[CC 1.2.3]"
+ #endif
+
+ #endif /* !COMPILER */
diff --git a/patches/dev-lang/python-3.5/python-2.7.12-no-datetime.patch b/patches/dev-lang/python-3.5/python-2.7.12-no-datetime.patch
@@ -0,0 +1,28 @@
+diff --git a/Modules/getbuildinfo.c.old b/Modules/getbuildinfo.c
+index 7069b6e..11d0674 100644
+--- a/Modules/getbuildinfo.c.old
++++ b/Modules/getbuildinfo.c
+@@ -4,21 +4,8 @@
+ #include <stdio.h>
+ #endif
+
+-#ifndef DATE
+-#ifdef __DATE__
+-#define DATE __DATE__
+-#else
+-#define DATE "xx/xx/xx"
++#define DATE "Jan 13 1984"
+-#endif
+-#endif
+-
+-#ifndef TIME
+-#ifdef __TIME__
+-#define TIME __TIME__
+-#else
+-#define TIME "xx:xx:xx"
++#define TIME "12:30:30"
+-#endif
+-#endif
+
+ /* on unix, SVNVERSION is passed on the command line.
+ * on Windows, the string is interpolated using
diff --git a/patches/dev-lang/python-3.6/python-2.7.12-no-compiler-version.patch b/patches/dev-lang/python-3.6/python-2.7.12-no-compiler-version.patch
@@ -0,0 +1,25 @@
+diff --git a/./Python/getcompiler.c.old b/./Python/getcompiler.c
+index 0f441de..df1e7d2 100644
+--- a/./Python/getcompiler.c.old
++++ b/./Python/getcompiler.c
+@@ -5,18 +5,10 @@
+
+ #ifndef COMPILER
+
+-#ifdef __GNUC__
+-#define COMPILER "\n[GCC " __VERSION__ "]"
+-#endif
+-
+-#endif /* !COMPILER */
+-
+-#ifndef COMPILER
+-
+ #ifdef __cplusplus
+-#define COMPILER "[C++]"
++#define COMPILER "[C++ 1.2.3]"
+ #else
+-#define COMPILER "[C]"
++#define COMPILER "[CC 1.2.3]"
+ #endif
+
+ #endif /* !COMPILER */
diff --git a/patches/dev-lang/python-3.6/python-2.7.12-no-datetime.patch b/patches/dev-lang/python-3.6/python-2.7.12-no-datetime.patch
@@ -0,0 +1,28 @@
+diff --git a/Modules/getbuildinfo.c.old b/Modules/getbuildinfo.c
+index 7069b6e..11d0674 100644
+--- a/Modules/getbuildinfo.c.old
++++ b/Modules/getbuildinfo.c
+@@ -4,21 +4,8 @@
+ #include <stdio.h>
+ #endif
+
+-#ifndef DATE
+-#ifdef __DATE__
+-#define DATE __DATE__
+-#else
+-#define DATE "xx/xx/xx"
++#define DATE "Jan 13 1984"
+-#endif
+-#endif
+-
+-#ifndef TIME
+-#ifdef __TIME__
+-#define TIME __TIME__
+-#else
+-#define TIME "xx:xx:xx"
++#define TIME "12:30:30"
+-#endif
+-#endif
+
+ /* on unix, SVNVERSION is passed on the command line.
+ * on Windows, the string is interpolated using
diff --git a/patches/dev-libs/nss/nss-3.33-no-datetime.patch b/patches/dev-libs/nss/nss-3.33-no-datetime.patch
@@ -0,0 +1,12 @@
+--- nss-abi_x86_32.x86/lib/ckfw/pem/ckpemver.c.old 2017-10-27 10:46:56.903556818 +0000
++++ nss-abi_x86_32.x86/lib/ckfw/pem/ckpemver.c 2017-10-27 10:49:13.298166407 +0000
+@@ -53,7 +53,7 @@
+ */
+ const char __nss_ckpem_rcsid[] = "$Header: NSS Access to Flat Files in PEM format"
+ NSS_CKPEM_LIBRARY_VERSION _DEBUG_STRING
+- " " __DATE__ " " __TIME__ " $";
++ " Jan 13 1984 12:30:30 $";
+ const char __nss_ckcapi_sccsid[] = "@(#)NSS Access to Flag Files in PEM format "
+ NSS_CKPEM_LIBRARY_VERSION _DEBUG_STRING
+- " " __DATE__ " " __TIME__;
++ " Jan 13 1984 12:30:30";
diff --git a/patches/dev-util/bam/bam-0.4.0-no-datetime.patch b/patches/dev-util/bam/bam-0.4.0-no-datetime.patch
@@ -0,0 +1,26 @@
+diff --git a/src/main.c.old b/src/main.c
+index 0b1786c..c8462d1 100644
+--- a/src/main.c.old
++++ b/src/main.c
+@@ -759,7 +759,7 @@ static void print_help()
+ printf(" %-20s %s\n", options[j].sw, options[j].desc);
+ }
+ printf("\n");
+- printf("bam version " BAM_VERSION_STRING_COMPLETE ". built "__DATE__" "__TIME__" using " LUA_VERSION "\n");
++ printf("bam version " BAM_VERSION_STRING_COMPLETE ". using " LUA_VERSION "\n");
+ printf("by Magnus Auvinen (magnus.auvinen@gmail.com)\n");
+ printf("\n");
+
+diff --git a/src/cache.c.old b/src/cache.c
+index c83df36..d9e1463 100644
+--- a/src/cache.c.old
++++ b/src/cache.c
+@@ -25,7 +25,7 @@ static char bamheader[8] = {
+ static void cache_setup_header()
+ {
+ /* save a hashed version of the date and time in the header */
+- unsigned hash = string_hash(__DATE__ __TIME__);
++ unsigned hash = string_hash("Jan 13 1984 12:30:30");
+ bamheader[5] = hash&0xff;
+ bamheader[6] = (hash>>8)&0xff;
+ bamheader[7] = (hash>>16)&0xff;
diff --git a/patches/dev-util/samurai/samurai-0.6-Add-fake-l-flag-for-compatibility.patch b/patches/dev-util/samurai/samurai-0.6-Add-fake-l-flag-for-compatibility.patch
@@ -0,0 +1,26 @@
+From 71ed7717c707c9117088bebb7cc4e70a561bdfe5 Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Fri, 8 Mar 2019 10:33:52 +0100
+Subject: [PATCH] samu.c: Add fake -l flag for compatibility
+
+---
+ samu.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/samu.c b/samu.c
+index 2eb6ce1..4f9ad8b 100644
+--- a/samu.c
++++ b/samu.c
+@@ -133,6 +133,9 @@ main(int argc, char *argv[])
+ case 'w':
+ warnflag(EARGF(usage()));
+ break;
++ case 'l':
++ // ignore for now ?
++ break;
+ default:
+ usage();
+ } ARGEND
+--
+2.19.2
+
diff --git a/patches/games-arcade/syobon/WASD controls DxLibs.h.patch b/patches/games-arcade/syobon/WASD controls DxLibs.h.patch
@@ -0,0 +1,17 @@
+--- DxLib.h 2017-09-28 13:33:46.073097546 +0200
++++ DxLib.h 2017-09-28 13:52:42.984297422 +0200
+@@ -67,10 +67,10 @@
+
+ //Key Aliases
+ #define KEY_INPUT_ESCAPE SDLK_ESCAPE
+-#define KEY_INPUT_LEFT SDLK_LEFT
+-#define KEY_INPUT_RIGHT SDLK_RIGHT
+-#define KEY_INPUT_DOWN SDLK_DOWN
+-#define KEY_INPUT_UP SDLK_UP
++#define KEY_INPUT_LEFT SDLK_a
++#define KEY_INPUT_RIGHT SDLK_d
++#define KEY_INPUT_DOWN SDLK_s
++#define KEY_INPUT_UP SDLK_w
+ #define KEY_INPUT_F1 SDLK_F1
+ #define KEY_INPUT_O SDLK_o
+ #define KEY_INPUT_K SDLK_k
diff --git a/patches/gnustep-base/libobjc2/libobjc2-1.8.1-fix_redefinition_of_i.patch b/patches/gnustep-base/libobjc2/libobjc2-1.8.1-fix_redefinition_of_i.patch
@@ -0,0 +1,30 @@
+diff --git a/loader.c b/loader.c
+index 70ab229..a69d864 100644
+--- a/loader.c
++++ b/loader.c
+@@ -109,13 +109,14 @@ void __objc_exec_class(struct objc_module_abi_8 *module)
+
+ unsigned short defs = 0;
+ // Load the classes from this module
+- for (unsigned short i=0 ; i<symbols->class_count ; i++)
++ unsigned short i;
++ for (i=0 ; i<symbols->class_count ; i++)
+ {
+ objc_load_class(symbols->definitions[defs++]);
+ }
+ unsigned int category_start = defs;
+ // Load the categories from this module
+- for (unsigned short i=0 ; i<symbols->category_count; i++)
++ for (i=0 ; i<symbols->category_count; i++)
+ {
+ objc_try_load_category(symbols->definitions[defs++]);
+ }
+@@ -131,7 +132,7 @@ void __objc_exec_class(struct objc_module_abi_8 *module)
+ objc_init_buffered_statics();
+ // Fix up the class links for loaded classes.
+ objc_resolve_class_links();
+- for (unsigned short i=0 ; i<symbols->category_count; i++)
++ for (i=0 ; i<symbols->category_count; i++)
+ {
+ struct objc_category *cat = (struct objc_category*)
+ symbols->definitions[category_start++];
diff --git a/patches/media-gfx/inkscape.old/inkscape-0.91-no-date.patch b/patches/media-gfx/inkscape.old/inkscape-0.91-no-date.patch
@@ -0,0 +1,26 @@
+diff --git a/src/main.cpp.old b/src/main.cpp
+index 517ba05..fc8c4ad 100644
+--- a/src/main.cpp.old
++++ b/src/main.cpp
+@@ -2178,7 +2178,7 @@ sp_process_args(poptContext ctx)
+ break;
+ }
+ case SP_ARG_VERSION: {
+- printf("Inkscape %s (%s)\n", Inkscape::version_string, __DATE__);
++ printf("Inkscape %s\n", Inkscape::version_string);
+ exit(0);
+ break;
+ }
+diff --git a/./src/extension/internal/emf-print.cpp.old b/./src/extension/internal/emf-print.cpp
+index f7b6626..da047f6 100644
+--- a/./src/extension/internal/emf-print.cpp.old
++++ b/./src/extension/internal/emf-print.cpp
+@@ -205,7 +205,7 @@ unsigned int PrintEmf::begin(Inkscape::Extension::Print *mod, SPDocument *doc)
+ } else {
+ p = ansi_uri;
+ }
+- snprintf(buff, sizeof(buff) - 1, "Inkscape %s (%s)\1%s\1", Inkscape::version_string, __DATE__, p);
++ snprintf(buff, sizeof(buff) - 1, "Inkscape %s\1%s\1", Inkscape::version_string, p);
+ uint16_t *Description = U_Utf8ToUtf16le(buff, 0, NULL);
+ int cbDesc = 2 + wchar16len(Description); // also count the final terminator
+ (void) U_Utf16leEdit(Description, '\1', '\0'); // swap the temporary \1 characters for nulls
diff --git a/patches/media-sound/audacity/enchant-1.6.1-Add-tag=CC.patch b/patches/media-sound/audacity/enchant-1.6.1-Add-tag=CC.patch
@@ -0,0 +1,9 @@
+diff -u enchant-1.6.1.orig/configure enchant-1.6.1/configure
+--- enchant-1.6.1.orig/configure 2017-12-17 16:56:55.527440216 -0600
++++ enchant-1.6.1/configure 2017-12-17 16:56:28.533441941 -0600
+@@ -11038,7 +11038,7 @@
+ LIBTOOL_DEPS=$ltmain
+
+ # Always use our own libtool.
+-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
++LIBTOOL='$(SHELL) $(top_builddir)/libtool --tag=CC'
diff --git a/patches/net-analyzer/nettop/nettop-0.2.3-no-datetime.patch b/patches/net-analyzer/nettop/nettop-0.2.3-no-datetime.patch
@@ -0,0 +1,13 @@
+diff --git a/nettop.c.old b/nettop.c
+index ffcb507..be2f37b 100644
+--- a/nettop.c.old
++++ b/nettop.c
+@@ -839,7 +839,7 @@ show_help()
+ SLsmg_gotorc(y++, 0);
+ SLsmg_printf("Written by Scott Parish, copyright 2001, BSD");
+ SLsmg_gotorc(y++, 0);
+- SLsmg_printf("Compiled at %s, %s", __TIME__, __DATE__);
++ SLsmg_printf("Compiled at %s, %s", "12:30:30", "Jan 13 1984");
+ y += 2;
+ SLsmg_gotorc(y++, 0);
+
diff --git a/patches/net-analyzer/nmap-7.70/nmap-7.70_nmap_error_h-time_h.patch b/patches/net-analyzer/nmap-7.70/nmap-7.70_nmap_error_h-time_h.patch
@@ -0,0 +1,13 @@
+diff --git a/nmap_error.h.old b/nmap_error.h
+index f6df970..c47dcce 100644
+--- a/nmap_error.h.old
++++ b/nmap_error.h
+@@ -132,6 +132,8 @@
+ #ifndef NMAP_ERROR_H
+ #define NMAP_ERROR_H
+
++#include <time.h>
++
+ #ifdef WIN32
+ #include "mswin32\winclude.h"
+ #endif
diff --git a/patches/net-libs/webkitgtk-2.24.1/0001-TextCodec.cpp-Fix-snprintf.patch b/patches/net-libs/webkitgtk-2.24.1/0001-TextCodec.cpp-Fix-snprintf.patch
@@ -0,0 +1,24 @@
+From b4b3beab5abc32b376f8bcbedae426d4fb618aea Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Fri, 5 Apr 2019 04:08:33 +0200
+Subject: [PATCH 1/9] TextCodec.cpp: Fix snprintf
+
+---
+ Source/WebCore/platform/text/TextCodec.cpp | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/Source/WebCore/platform/text/TextCodec.cpp b/Source/WebCore/platform/text/TextCodec.cpp
+index 86b89cfc..4be00cee 100644
+--- a/Source/WebCore/platform/text/TextCodec.cpp
++++ b/Source/WebCore/platform/text/TextCodec.cpp
+@@ -28,6 +28,7 @@
+ #include "TextCodec.h"
+
+ #include <array>
++#include <stdio.h>
+
+ namespace WebCore {
+
+--
+2.21.0
+
diff --git a/patches/net-libs/webkitgtk-2.24.1/0002-Defang-anchor-element-ping-attribute.patch b/patches/net-libs/webkitgtk-2.24.1/0002-Defang-anchor-element-ping-attribute.patch
@@ -0,0 +1,87 @@
+From a9d13da39c553f31bd5a1717b777572a57c03b42 Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Fri, 5 Apr 2019 09:03:39 +0200
+Subject: [PATCH 2/9] Defang anchor element ping attribute
+
+---
+ Source/WebCore/html/HTMLAnchorElement.cpp | 11 --------
+ Source/WebCore/loader/PingLoader.cpp | 34 -----------------------
+ 2 files changed, 45 deletions(-)
+
+diff --git a/Source/WebCore/html/HTMLAnchorElement.cpp b/Source/WebCore/html/HTMLAnchorElement.cpp
+index 37d98a33..815ed314 100644
+--- a/Source/WebCore/html/HTMLAnchorElement.cpp
++++ b/Source/WebCore/html/HTMLAnchorElement.cpp
+@@ -363,15 +363,6 @@ bool HTMLAnchorElement::isLiveLink() const
+
+ void HTMLAnchorElement::sendPings(const URL& destinationURL)
+ {
+- if (!document().frame())
+- return;
+-
+- if (!hasAttributeWithoutSynchronization(pingAttr) || !document().settings().hyperlinkAuditingEnabled())
+- return;
+-
+- SpaceSplitString pingURLs(attributeWithoutSynchronization(pingAttr), false);
+- for (unsigned i = 0; i < pingURLs.size(); i++)
+- PingLoader::sendPing(*document().frame(), document().completeURL(pingURLs[i]), destinationURL);
+ }
+
+ #if USE(SYSTEM_PREVIEW)
+@@ -493,8 +484,6 @@ void HTMLAnchorElement::handleClick(Event& event)
+ ASSERT(!adClickAttribution || adClickAttribution->url().isNull());
+
+ frame->loader().urlSelected(completedURL, effectiveTarget, &event, LockHistory::No, LockBackForwardList::No, shouldSendReferrer, document().shouldOpenExternalURLsPolicyToPropagate(), newFrameOpenerPolicy, downloadAttribute, systemPreviewInfo, WTFMove(adClickAttribution));
+-
+- sendPings(completedURL);
+ }
+
+ // Falls back to using <base> element's target if the anchor does not have one.
+diff --git a/Source/WebCore/loader/PingLoader.cpp b/Source/WebCore/loader/PingLoader.cpp
+index 2c0b2a3b..9225fdde 100644
+--- a/Source/WebCore/loader/PingLoader.cpp
++++ b/Source/WebCore/loader/PingLoader.cpp
+@@ -113,40 +113,6 @@ void PingLoader::loadImage(Frame& frame, const URL& url)
+ // http://www.whatwg.org/specs/web-apps/current-work/multipage/links.html#hyperlink-auditing
+ void PingLoader::sendPing(Frame& frame, const URL& pingURL, const URL& destinationURL)
+ {
+- ASSERT(frame.document());
+-
+- if (!pingURL.protocolIsInHTTPFamily())
+- return;
+-
+- ResourceRequest request(pingURL);
+- if (processContentExtensionRulesForLoad(frame, request, ResourceType::Raw))
+- return;
+-
+- auto& document = *frame.document();
+- document.contentSecurityPolicy()->upgradeInsecureRequestIfNeeded(request, ContentSecurityPolicy::InsecureRequestType::Load);
+-
+- request.setHTTPMethod("POST");
+- request.setHTTPContentType("text/ping");
+- request.setHTTPBody(FormData::create("PING"));
+- request.setHTTPHeaderField(HTTPHeaderName::CacheControl, "max-age=0");
+-
+- HTTPHeaderMap originalRequestHeader = request.httpHeaderFields();
+-
+- frame.loader().addExtraFieldsToSubresourceRequest(request);
+-
+- auto& sourceOrigin = document.securityOrigin();
+- FrameLoader::addHTTPOriginIfNeeded(request, sourceOrigin.toString());
+- request.setHTTPHeaderField(HTTPHeaderName::PingTo, destinationURL);
+- if (!SecurityPolicy::shouldHideReferrer(pingURL, frame.loader().outgoingReferrer())) {
+- request.setHTTPHeaderField(HTTPHeaderName::PingFrom, document.url());
+- if (!sourceOrigin.isSameSchemeHostPort(SecurityOrigin::create(pingURL).get())) {
+- String referrer = SecurityPolicy::generateReferrerHeader(document.referrerPolicy(), pingURL, frame.loader().outgoingReferrer());
+- if (!referrer.isEmpty())
+- request.setHTTPReferrer(referrer);
+- }
+- }
+-
+- startPingLoad(frame, request, WTFMove(originalRequestHeader), ShouldFollowRedirects::Yes, ContentSecurityPolicyImposition::DoPolicyCheck);
+ }
+
+ void PingLoader::sendViolationReport(Frame& frame, const URL& reportURL, Ref<FormData>&& report, ViolationReportType reportType)
+--
+2.21.0
+
diff --git a/patches/net-libs/webkitgtk-2.24.1/0003-Source-WebInspectorUI-UserInterface-Views-ConsoleMes.patch b/patches/net-libs/webkitgtk-2.24.1/0003-Source-WebInspectorUI-UserInterface-Views-ConsoleMes.patch
@@ -0,0 +1,55 @@
+From 88e3ffd657ace02aeedd56e857d54c217f1e861b Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Fri, 2 Nov 2018 17:59:57 +0100
+Subject: [PATCH 3/9]
+ Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.js: Remove %c
+ support in the console
+
+---
+ .../UserInterface/Views/ConsoleMessageView.js | 23 -------------------
+ 1 file changed, 23 deletions(-)
+
+diff --git a/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.js b/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.js
+index 4cf58fd3..f53f9ab7 100644
+--- a/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.js
++++ b/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.js
+@@ -674,26 +674,6 @@ WI.ConsoleMessageView = class ConsoleMessageView extends WI.Object
+ }
+
+ var currentStyle = null;
+- function styleFormatter(obj)
+- {
+- currentStyle = {};
+- var buffer = document.createElement("span");
+- buffer.setAttribute("style", obj.description);
+- for (var i = 0; i < buffer.style.length; i++) {
+- var property = buffer.style[i];
+- if (isWhitelistedProperty(property))
+- currentStyle[property] = buffer.style[property];
+- }
+- }
+-
+- function isWhitelistedProperty(property)
+- {
+- for (var prefix of ["background", "border", "color", "font", "line", "margin", "padding", "text"]) {
+- if (property.startsWith(prefix) || property.startsWith("-webkit-" + prefix))
+- return true;
+- }
+- return false;
+- }
+
+ // Firebug uses %o for formatting objects.
+ var formatters = {};
+@@ -705,9 +685,6 @@ WI.ConsoleMessageView = class ConsoleMessageView extends WI.Object
+ formatters.i = integerFormatter;
+ formatters.d = integerFormatter;
+
+- // Firebug uses %c for styling the message.
+- formatters.c = styleFormatter;
+-
+ // Support %O to force object formatting, instead of the type-based %o formatting.
+ formatters.O = parameterFormatter.bind(this, true);
+
+--
+2.21.0
+
diff --git a/patches/net-libs/webkitgtk-2.24.1/0004-CMakeLists.txt-Explain-which-variable-is-used-to-def.patch b/patches/net-libs/webkitgtk-2.24.1/0004-CMakeLists.txt-Explain-which-variable-is-used-to-def.patch
@@ -0,0 +1,26 @@
+From 5da0a39efade423c2ddd3460717b3d295ad69917 Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Tue, 6 Nov 2018 15:09:22 +0100
+Subject: [PATCH 4/9] CMakeLists.txt: Explain which variable is used to define
+ a port if undefined
+
+---
+ CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index cc3c732f..34b7de24 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -48,7 +48,7 @@ set(PORT "NOPORT" CACHE STRING "choose which WebKit port to build (one of ${ALL_
+
+ list(FIND ALL_PORTS ${PORT} RET)
+ if (${RET} EQUAL -1)
+- message(FATAL_ERROR "Please choose which WebKit port to build (one of ${ALL_PORTS})")
++ message(FATAL_ERROR "Please define a PORT to build with (one of ${ALL_PORTS})")
+ endif ()
+
+ string(TOLOWER ${PORT} WEBKIT_PORT_DIR)
+--
+2.21.0
+
diff --git a/patches/net-libs/webkitgtk-2.24.1/0005-Source-cmake-OptionsGTK.cmake-Add-note-on-fixing-CMa.patch b/patches/net-libs/webkitgtk-2.24.1/0005-Source-cmake-OptionsGTK.cmake-Add-note-on-fixing-CMa.patch
@@ -0,0 +1,25 @@
+From 392b55225fcfb75c4cd2fe67c8cd70683ea880b6 Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Tue, 6 Nov 2018 15:13:28 +0100
+Subject: [PATCH 5/9] Source/cmake/OptionsGTK.cmake: Add note on fixing CMake
+ defaults
+
+---
+ Source/cmake/OptionsGTK.cmake | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/Source/cmake/OptionsGTK.cmake b/Source/cmake/OptionsGTK.cmake
+index aa932581..1ec9c320 100644
+--- a/Source/cmake/OptionsGTK.cmake
++++ b/Source/cmake/OptionsGTK.cmake
+@@ -72,6 +72,7 @@ endif ()
+ # Public options specific to the GTK+ port. Do not add any options here unless
+ # there is a strong reason we should support changing the value of the option,
+ # and the option is not relevant to any other WebKit ports.
++# XXX: Do not default to optionnal stuff like USE_LIBSECRET to REQUIRED
+ WEBKIT_OPTION_DEFINE(ENABLE_GLES2 "Whether to enable OpenGL ES 2.0." PUBLIC ${ENABLE_GLES2_DEFAULT})
+ WEBKIT_OPTION_DEFINE(ENABLE_GTKDOC "Whether or not to use generate gtkdoc." PUBLIC OFF)
+ WEBKIT_OPTION_DEFINE(ENABLE_INTROSPECTION "Whether to enable GObject introspection." PUBLIC ON)
+--
+2.21.0
+
diff --git a/patches/net-libs/webkitgtk-2.24.1/0006-Source-WebCore-page-RuntimeEnabledFeatures.h-hard-di.patch b/patches/net-libs/webkitgtk-2.24.1/0006-Source-WebCore-page-RuntimeEnabledFeatures.h-hard-di.patch
@@ -0,0 +1,72 @@
+From c135e45d15c9654a4189241597fb7a409f9020a0 Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Sun, 2 Dec 2018 02:33:31 +0100
+Subject: [PATCH 6/9] Source/WebCore/page/RuntimeEnabledFeatures.h:
+ hard-disable some features
+
+---
+ Source/WebCore/page/RuntimeEnabledFeatures.h | 16 ++++++++--------
+ 1 file changed, 8 insertions(+), 8 deletions(-)
+
+diff --git a/Source/WebCore/page/RuntimeEnabledFeatures.h b/Source/WebCore/page/RuntimeEnabledFeatures.h
+index 0f7e7a50..2030412e 100644
+--- a/Source/WebCore/page/RuntimeEnabledFeatures.h
++++ b/Source/WebCore/page/RuntimeEnabledFeatures.h
+@@ -50,13 +50,13 @@ public:
+ bool displayContentsEnabled() const { return m_isDisplayContentsEnabled; }
+
+ void setLinkPreloadEnabled(bool isEnabled) { m_isLinkPreloadEnabled = isEnabled; }
+- bool linkPreloadEnabled() const { return m_isLinkPreloadEnabled; }
++ bool linkPreloadEnabled() const { return false; }
+
+ void setLinkPrefetchEnabled(bool isEnabled) { m_isLinkPrefetchEnabled = isEnabled; }
+- bool linkPrefetchEnabled() const { return m_isLinkPrefetchEnabled; }
++ bool linkPrefetchEnabled() const { return false; }
+
+ void setMediaPreloadingEnabled(bool isEnabled) { m_isMediaPreloadingEnabled = isEnabled; }
+- bool mediaPreloadingEnabled() const { return m_isMediaPreloadingEnabled; }
++ bool mediaPreloadingEnabled() const { return false; }
+
+ void setResourceTimingEnabled(bool isEnabled) { m_isResourceTimingEnabled = isEnabled; }
+ bool resourceTimingEnabled() const { return m_isResourceTimingEnabled; }
+@@ -70,19 +70,19 @@ public:
+ bool shadowDOMEnabled() const { return m_isShadowDOMEnabled; }
+
+ void setInputEventsEnabled(bool isEnabled) { m_inputEventsEnabled = isEnabled; }
+- bool inputEventsEnabled() const { return m_inputEventsEnabled; }
++ bool inputEventsEnabled() const { return false; }
+
+ void setInteractiveFormValidationEnabled(bool isEnabled) { m_isInteractiveFormValidationEnabled = isEnabled; }
+ bool interactiveFormValidationEnabled() const { return m_isInteractiveFormValidationEnabled; }
+
+ void setCustomElementsEnabled(bool areEnabled) { m_areCustomElementsEnabled = areEnabled; }
+- bool customElementsEnabled() const { return m_areCustomElementsEnabled; }
++ bool customElementsEnabled() const { return false; }
+
+ void setMenuItemElementEnabled(bool isEnabled) { m_isMenuItemElementEnabled = isEnabled; }
+ bool menuItemElementEnabled() const { return m_isMenuItemElementEnabled; }
+
+ void setDirectoryUploadEnabled(bool isEnabled) { m_isDirectoryUploadEnabled = isEnabled; }
+- bool directoryUploadEnabled() const { return m_isDirectoryUploadEnabled; }
++ bool directoryUploadEnabled() const { return false; }
+
+ #if ENABLE(DARK_MODE_CSS)
+ void setDarkModeCSSEnabled(bool isEnabled) { m_isDarkModeCSSEnabled = isEnabled; }
+@@ -320,12 +320,12 @@ public:
+
+ #if ENABLE(ENCRYPTED_MEDIA)
+ void setEncryptedMediaAPIEnabled(bool isEnabled) { m_encryptedMediaAPIEnabled = isEnabled; }
+- bool encryptedMediaAPIEnabled() const { return m_encryptedMediaAPIEnabled; }
++ bool encryptedMediaAPIEnabled() const { return false; }
+ #endif
+
+ #if ENABLE(LEGACY_ENCRYPTED_MEDIA)
+ void setLegacyEncryptedMediaAPIEnabled(bool isEnabled) { m_legacyEncryptedMediaAPIEnabled = isEnabled; }
+- bool legacyEncryptedMediaAPIEnabled() const { return m_legacyEncryptedMediaAPIEnabled; }
++ bool legacyEncryptedMediaAPIEnabled() const { return false; }
+ #endif
+
+ #if ENABLE(SERVICE_WORKER)
+--
+2.21.0
+
diff --git a/patches/net-libs/webkitgtk-2.24.1/0007-lanodan-TODO-New.patch b/patches/net-libs/webkitgtk-2.24.1/0007-lanodan-TODO-New.patch
@@ -0,0 +1,84 @@
+From b1db23c1b58f4e808037239ff6cc86417eeef887 Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Sun, 2 Dec 2018 11:11:22 +0100
+Subject: [PATCH 7/9] lanodan-TODO: New
+
+---
+ lanodan-TODO | 65 ++++++++++++++++++++++++++++++++++++++++++++++++++++
+ 1 file changed, 65 insertions(+)
+ create mode 100644 lanodan-TODO
+
+diff --git a/lanodan-TODO b/lanodan-TODO
+new file mode 100644
+index 00000000..d8acc42c
+--- /dev/null
++++ b/lanodan-TODO
+@@ -0,0 +1,65 @@
++## Javascript
++- [x] Console Styling (%c)
++- [ ] GeoLocation
++- [ ] AudioAPI
++- [ ] Gamepad (runtime, off by default): https://www.w3.org/TR/gamepad/
++- [ ] Service Workers (runtime, off by default)
++- [ ] IndexedDB (runtime, off by default)
++- [ ] Object Storage (runtime, off by default)
++- [ ] canvas (runtime, off by default)
++- [ ] WebGL (runtime, off by default)
++- [ ] Sensors
++ - [x] Battery (WebKit: Not Considering)
++ - [ ] microphone (runtime, off by default)
++ - [ ] video(webcam, screen, …) (runtime, off by default)
++ - …
++- [x] Web Bluetooth (WebKit: Not Considering)
++- [x] Web MIDI (WebKit: Not Considering)
++- [x] Web USB (WebKit: Not Considering)
++- [ ] Input Events
++ - [ ] Pointer Events
++ - [ ] Scroll Events
++ - [ ] Focus Events
++ - …
++- [ ] Timings
++ - Navigation Timing
++ - Resource Timing
++ - Performance Timeline: https://w3c.github.io/performance-timeline/
++ - High Resolution Time
++ - …
++- [ ] Viewport size
++- [ ] Elements size
++- [ ] multimedia player stats (FPS, caching, …)
++- [ ] Payment Request: https://www.w3.org/TR/payment-request/
++- [ ] Encoding Standard (explore): https://encoding.spec.whatwg.org/
++
++## Headers
++- [ ] referer
++- [ ] user-agent (spoof Intel Apple one?)
++- [ ] Cookies (runtime, off by default)
++
++## HTML
++- [ ] noscript
++- [x] Link ping
++- [x] Link prefetch
++- [x] Link preloading
++- [x] Media preloading
++- [x] custom elements
++- [ ] DNS prefetch
++- [ ] srcset (images)
++
++## CSS
++- [ ] Engine-specific extensions
++- [ ] WebFont (runtime, off by default)
++
++## TLS
++- [ ] Disable known-bad ciphers
++- [ ] TOFU?
++- [ ] DANE
++
++## Codebase
++- [ ] Remove Third-Party directory
++
++
++- https://webkit.org/status/
++- https://github.com/WICG
+--
+2.21.0
+
diff --git a/patches/net-libs/webkitgtk-2.24.1/0008-defang-AdClickAttribution.patch b/patches/net-libs/webkitgtk-2.24.1/0008-defang-AdClickAttribution.patch
@@ -0,0 +1,309 @@
+From 65d2f6b42f8baa812d7d62629c09d4e88c96888f Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Fri, 5 Apr 2019 06:44:31 +0200
+Subject: [PATCH 8/9] defang AdClickAttribution
+
+---
+ Source/WebCore/html/HTMLAnchorElement.cpp | 52 --------------------
+ Source/WebCore/html/HTMLAnchorElement.h | 3 --
+ Source/WebCore/html/HTMLAnchorElement.idl | 2 -
+ Source/WebCore/loader/AdClickAttribution.cpp | 42 +---------------
+ Source/WebCore/loader/AdClickAttribution.h | 48 +-----------------
+ Source/WebCore/loader/FrameLoader.cpp | 3 --
+ Source/WebCore/page/RuntimeEnabledFeatures.h | 4 +-
+ lanodan-TODO | 7 +--
+ 8 files changed, 10 insertions(+), 151 deletions(-)
+
+diff --git a/Source/WebCore/html/HTMLAnchorElement.cpp b/Source/WebCore/html/HTMLAnchorElement.cpp
+index 815ed314..9f3691e1 100644
+--- a/Source/WebCore/html/HTMLAnchorElement.cpp
++++ b/Source/WebCore/html/HTMLAnchorElement.cpp
+@@ -24,7 +24,6 @@
+ #include "config.h"
+ #include "HTMLAnchorElement.h"
+
+-#include "AdClickAttribution.h"
+ #include "DOMTokenList.h"
+ #include "ElementIterator.h"
+ #include "EventHandler.h"
+@@ -388,52 +387,6 @@ bool HTMLAnchorElement::isSystemPreviewLink() const
+ }
+ #endif
+
+-Optional<AdClickAttribution> HTMLAnchorElement::parseAdClickAttribution() const
+-{
+- using Campaign = AdClickAttribution::Campaign;
+- using Source = AdClickAttribution::Source;
+- using Destination = AdClickAttribution::Destination;
+-
+- if (!RuntimeEnabledFeatures::sharedFeatures().adClickAttributionEnabled() || !UserGestureIndicator::processingUserGesture())
+- return WTF::nullopt;
+-
+- if (!hasAttributeWithoutSynchronization(adcampaignidAttr) && !hasAttributeWithoutSynchronization(addestinationAttr))
+- return WTF::nullopt;
+-
+- auto adCampaignIDAttr = attributeWithoutSynchronization(adcampaignidAttr);
+- auto adDestinationAttr = attributeWithoutSynchronization(addestinationAttr);
+-
+- if (adCampaignIDAttr.isEmpty() || adDestinationAttr.isEmpty()) {
+- document().addConsoleMessage(MessageSource::Other, MessageLevel::Warning, "Both adcampaignid and addestination need to be set for Ad Click Attribution to work."_s);
+- return WTF::nullopt;
+- }
+-
+- RefPtr<Frame> frame = document().frame();
+- if (!frame || !frame->isMainFrame()) {
+- document().addConsoleMessage(MessageSource::Other, MessageLevel::Warning, "Ad Click Attribution is only supported in the main frame."_s);
+- return WTF::nullopt;
+- }
+-
+- auto adCampaignID = parseHTMLNonNegativeInteger(adCampaignIDAttr);
+- if (!adCampaignID) {
+- document().addConsoleMessage(MessageSource::Other, MessageLevel::Warning, "adcampaignid can not be converted to a non-negative integer which is required for Ad Click Attribution."_s);
+- return WTF::nullopt;
+- }
+-
+- if (adCampaignID.value() >= AdClickAttribution::MaxEntropy) {
+- document().addConsoleMessage(MessageSource::Other, MessageLevel::Warning, makeString("adcampaignid must have a non-negative value less than ", AdClickAttribution::MaxEntropy, " for Ad Click Attribution."));
+- return WTF::nullopt;
+- }
+-
+- URL adDestinationURL { URL(), adDestinationAttr };
+- if (!adDestinationURL.isValid() || !adDestinationURL.protocolIsInHTTPFamily()) {
+- document().addConsoleMessage(MessageSource::Other, MessageLevel::Warning, "adddestination could not be converted to a valid HTTP-family URL."_s);
+- return WTF::nullopt;
+- }
+-
+- return AdClickAttribution { Campaign(adCampaignID.value()), Source(document().domain()), Destination(adDestinationURL.host().toString()) };
+-}
+-
+ void HTMLAnchorElement::handleClick(Event& event)
+ {
+ event.setDefaultHandled();
+@@ -478,11 +431,6 @@ void HTMLAnchorElement::handleClick(Event& event)
+ else if (hasRel(Relation::NoOpener) || (RuntimeEnabledFeatures::sharedFeatures().blankAnchorTargetImpliesNoOpenerEnabled() && equalIgnoringASCIICase(effectiveTarget, "_blank")))
+ newFrameOpenerPolicy = NewFrameOpenerPolicy::Suppress;
+
+- auto adClickAttribution = parseAdClickAttribution();
+- // A matching conversion event needs to happen before the complete ad click attributionURL can be
+- // created. Thus, it should be empty for now.
+- ASSERT(!adClickAttribution || adClickAttribution->url().isNull());
+-
+ frame->loader().urlSelected(completedURL, effectiveTarget, &event, LockHistory::No, LockBackForwardList::No, shouldSendReferrer, document().shouldOpenExternalURLsPolicyToPropagate(), newFrameOpenerPolicy, downloadAttribute, systemPreviewInfo, WTFMove(adClickAttribution));
+ }
+
+diff --git a/Source/WebCore/html/HTMLAnchorElement.h b/Source/WebCore/html/HTMLAnchorElement.h
+index 61315ced..7f41385c 100644
+--- a/Source/WebCore/html/HTMLAnchorElement.h
++++ b/Source/WebCore/html/HTMLAnchorElement.h
+@@ -32,7 +32,6 @@
+
+ namespace WebCore {
+
+-class AdClickAttribution;
+ class DOMTokenList;
+
+ // Link relation bitmask values.
+@@ -97,8 +96,6 @@ private:
+
+ void sendPings(const URL& destinationURL);
+
+- Optional<AdClickAttribution> parseAdClickAttribution() const;
+-
+ void handleClick(Event&);
+
+ enum EventType {
+diff --git a/Source/WebCore/html/HTMLAnchorElement.idl b/Source/WebCore/html/HTMLAnchorElement.idl
+index 0d21fc7d..b7f59462 100644
+--- a/Source/WebCore/html/HTMLAnchorElement.idl
++++ b/Source/WebCore/html/HTMLAnchorElement.idl
+@@ -19,8 +19,6 @@
+ */
+
+ interface HTMLAnchorElement : HTMLElement {
+- [CEReactions=NotNeeded, EnabledAtRuntime=AdClickAttribution, Reflect] attribute DOMString adcampaignid;
+- [CEReactions=NotNeeded, EnabledAtRuntime=AdClickAttribution, Reflect] attribute DOMString addestination;
+ [CEReactions=NotNeeded, Reflect] attribute DOMString charset;
+ [CEReactions=NotNeeded, Reflect] attribute DOMString coords;
+ [CEReactions=NotNeeded, Conditional=DOWNLOAD_ATTRIBUTE, EnabledAtRuntime=DownloadAttribute, Reflect] attribute DOMString download;
+diff --git a/Source/WebCore/loader/AdClickAttribution.cpp b/Source/WebCore/loader/AdClickAttribution.cpp
+index bdc06393..2dab9617 100644
+--- a/Source/WebCore/loader/AdClickAttribution.cpp
++++ b/Source/WebCore/loader/AdClickAttribution.cpp
+@@ -34,59 +34,21 @@ namespace WebCore {
+
+ bool AdClickAttribution::isValid() const
+ {
+- return m_conversion
+- && m_conversion.value().isValid()
+- && m_campaign.isValid()
+- && !m_source.registrableDomain.isEmpty()
+- && !m_destination.registrableDomain.isEmpty()
+- && m_earliestTimeToSend;
++ return false;
+ }
+
+ void AdClickAttribution::setConversion(Conversion&& conversion)
+ {
+- if (!conversion.isValid() || (m_conversion && m_conversion->priority > conversion.priority))
+- return;
+-
+- m_conversion = WTFMove(conversion);
+- // 24-48 hour delay before sending. This helps privacy since the conversion and the attribution
+- // requests are detached and the time of the attribution does not reveal the time of the conversion.
+- m_earliestTimeToSend = m_timeOfAdClick + 24_h + Seconds(randomNumber() * (24_h).value());
++ return;
+ }
+
+ URL AdClickAttribution::url() const
+ {
+- if (!isValid())
+- return URL();
+-
+- StringBuilder builder;
+- builder.appendLiteral("https://");
+- builder.append(m_source.registrableDomain);
+- builder.appendLiteral("/.well-known/ad-click-attribution/");
+- builder.appendNumber(m_conversion.value().data);
+- builder.append('/');
+- builder.appendNumber(m_campaign.id);
+-
+- URL url { URL(), builder.toString() };
+- if (url.isValid())
+- return url;
+-
+ return URL();
+ }
+
+ URL AdClickAttribution::referrer() const
+ {
+- if (!isValid())
+- return URL();
+-
+- StringBuilder builder;
+- builder.appendLiteral("https://");
+- builder.append(m_destination.registrableDomain);
+- builder.append('/');
+-
+- URL url { URL(), builder.toString() };
+- if (url.isValid())
+- return url;
+-
+ return URL();
+ }
+
+diff --git a/Source/WebCore/loader/AdClickAttribution.h b/Source/WebCore/loader/AdClickAttribution.h
+index 34af2f2d..af6bf69c 100644
+--- a/Source/WebCore/loader/AdClickAttribution.h
++++ b/Source/WebCore/loader/AdClickAttribution.h
+@@ -150,41 +150,7 @@ void AdClickAttribution::encode(Encoder& encoder) const
+ template<class Decoder>
+ Optional<AdClickAttribution> AdClickAttribution::decode(Decoder& decoder)
+ {
+- Optional<CampaignId> campaignId;
+- decoder >> campaignId;
+- if (!campaignId)
+- return WTF::nullopt;
+-
+- Optional<String> sourceRegistrableDomain;
+- decoder >> sourceRegistrableDomain;
+- if (!sourceRegistrableDomain)
+- return WTF::nullopt;
+-
+- Optional<String> destinationRegistrableDomain;
+- decoder >> destinationRegistrableDomain;
+- if (!destinationRegistrableDomain)
+- return WTF::nullopt;
+-
+- Optional<WallTime> timeOfAdClick;
+- decoder >> timeOfAdClick;
+- if (!timeOfAdClick)
+- return WTF::nullopt;
+-
+- Optional<Optional<Conversion>> conversion;
+- decoder >> conversion;
+- if (!conversion)
+- return WTF::nullopt;
+-
+- Optional<Optional<WallTime>> earliestTimeToSend;
+- decoder >> earliestTimeToSend;
+- if (!earliestTimeToSend)
+- return WTF::nullopt;
+-
+- AdClickAttribution attribution { Campaign { WTFMove(*campaignId) }, Source { WTFMove(*sourceRegistrableDomain) }, Destination { WTFMove(*destinationRegistrableDomain) } };
+- attribution.m_conversion = WTFMove(*conversion);
+- attribution.m_earliestTimeToSend = WTFMove(*earliestTimeToSend);
+-
+- return attribution;
++ return WTF::nullopt;
+ }
+
+ template<class Encoder>
+@@ -196,17 +162,7 @@ void AdClickAttribution::Conversion::encode(Encoder& encoder) const
+ template<class Decoder>
+ Optional<AdClickAttribution::Conversion> AdClickAttribution::Conversion::decode(Decoder& decoder)
+ {
+- Optional<ConversionData> data;
+- decoder >> data;
+- if (!data)
+- return WTF::nullopt;
+-
+- Optional<PriorityValue> priority;
+- decoder >> priority;
+- if (!priority)
+- return WTF::nullopt;
+-
+- return Conversion { WTFMove(*data), Priority { WTFMove(*priority) } };
++ return WTF::nullopt;
+ }
+
+ } // namespace WebCore
+diff --git a/Source/WebCore/loader/FrameLoader.cpp b/Source/WebCore/loader/FrameLoader.cpp
+index 109b7d35..2903d158 100644
+--- a/Source/WebCore/loader/FrameLoader.cpp
++++ b/Source/WebCore/loader/FrameLoader.cpp
+@@ -1376,9 +1376,6 @@ void FrameLoader::loadURL(FrameLoadRequest&& frameLoadRequest, const String& ref
+ NavigationAction action { frameLoadRequest.requester(), request, frameLoadRequest.initiatedByMainFrame(), newLoadType, isFormSubmission, event, frameLoadRequest.shouldOpenExternalURLsPolicy(), frameLoadRequest.downloadAttribute() };
+ action.setLockHistory(lockHistory);
+ action.setLockBackForwardList(frameLoadRequest.lockBackForwardList());
+- if (adClickAttribution && m_frame.isMainFrame())
+- action.setAdClickAttribution(WTFMove(*adClickAttribution));
+-
+ if (!targetFrame && !effectiveFrameName.isEmpty()) {
+ action = action.copyWithShouldOpenExternalURLsPolicy(shouldOpenExternalURLsPolicyToApply(m_frame, frameLoadRequest));
+ policyChecker().checkNewWindowPolicy(WTFMove(action), WTFMove(request), WTFMove(formState), effectiveFrameName, [this, allowNavigationToInvalidURL, openerPolicy, completionHandler = completionHandlerCaller.release()] (const ResourceRequest& request, WeakPtr<FormState>&& formState, const String& frameName, const NavigationAction& action, ShouldContinue shouldContinue) mutable {
+diff --git a/Source/WebCore/page/RuntimeEnabledFeatures.h b/Source/WebCore/page/RuntimeEnabledFeatures.h
+index 2030412e..f693ebd3 100644
+--- a/Source/WebCore/page/RuntimeEnabledFeatures.h
++++ b/Source/WebCore/page/RuntimeEnabledFeatures.h
+@@ -341,8 +341,8 @@ public:
+ void setCSSLogicalEnabled(bool isEnabled) { m_CSSLogicalEnabled = isEnabled; }
+ bool cssLogicalEnabled() const { return m_CSSLogicalEnabled; }
+
+- bool adClickAttributionEnabled() const { return m_adClickAttributionEnabled; }
+- void setAdClickAttributionEnabled(bool isEnabled) { m_adClickAttributionEnabled = isEnabled; }
++ bool adClickAttributionEnabled() const { return false; }
++ void setAdClickAttributionEnabled(bool isEnabled) { }
+
+ WEBCORE_EXPORT static RuntimeEnabledFeatures& sharedFeatures();
+
+diff --git a/lanodan-TODO b/lanodan-TODO
+index d8acc42c..ef507ac4 100644
+--- a/lanodan-TODO
++++ b/lanodan-TODO
+@@ -40,9 +40,10 @@
+
+ ## HTML
+ - [ ] noscript
+-- [x] Link ping
+-- [x] Link prefetch
+-- [x] Link preloading
++- [x] Anchor ping
++- [x] Anchor prefetch
++- [x] Anchor preloading
++- [x] Anchor AdClickAttribution
+ - [x] Media preloading
+ - [x] custom elements
+ - [ ] DNS prefetch
+--
+2.21.0
+
diff --git a/patches/net-libs/webkitgtk-2.24.1/0009-lanodan-TODO-Beacon.patch b/patches/net-libs/webkitgtk-2.24.1/0009-lanodan-TODO-Beacon.patch
@@ -0,0 +1,24 @@
+From c6c52e0f5a9f70a913b4636fcdcc6c3c42c1869e Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Fri, 5 Apr 2019 08:29:03 +0200
+Subject: [PATCH 9/9] lanodan-TODO: Beacon
+
+---
+ lanodan-TODO | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/lanodan-TODO b/lanodan-TODO
+index ef507ac4..86487345 100644
+--- a/lanodan-TODO
++++ b/lanodan-TODO
+@@ -32,6 +32,7 @@
+ - [ ] multimedia player stats (FPS, caching, …)
+ - [ ] Payment Request: https://www.w3.org/TR/payment-request/
+ - [ ] Encoding Standard (explore): https://encoding.spec.whatwg.org/
++- [ ] Beacon API: https://developer.mozilla.org/en-US/docs/Web/API/Beacon_API
+
+ ## Headers
+ - [ ] referer
+--
+2.21.0
+
diff --git a/patches/net-misc/youtube-dl/8b703800ecb-pull-16105-rooster-teeth.diff b/patches/net-misc/youtube-dl/8b703800ecb-pull-16105-rooster-teeth.diff
@@ -0,0 +1,239 @@
+diff --git a/youtube_dl/extractor/roosterteeth.py b/youtube_dl/extractor/roosterteeth.py
+index 8b703800ecb..69a3c6d0164 100644
+--- a/youtube_dl/extractor/roosterteeth.py
++++ b/youtube_dl/extractor/roosterteeth.py
+@@ -1,35 +1,37 @@
+ # coding: utf-8
+ from __future__ import unicode_literals
+
+-import re
++import time
+
+ from .common import InfoExtractor
+ from ..utils import (
+ ExtractorError,
+- int_or_none,
+- strip_or_none,
+- unescapeHTML,
++ compat_str,
++ str_or_none,
++ try_get,
++ unified_timestamp,
+ urlencode_postdata,
+ )
+
+
+ class RoosterTeethIE(InfoExtractor):
+ _VALID_URL = r'https?://(?:.+?\.)?roosterteeth\.com/episode/(?P<id>[^/?#&]+)'
+- _LOGIN_URL = 'https://roosterteeth.com/login'
++ _LOGIN_URL = 'https://auth.roosterteeth.com/oauth/token'
++ _API_URL = 'https://svod-be.roosterteeth.com/api/v1/episodes/'
++ _ACCESS_TOKEN = None
+ _NETRC_MACHINE = 'roosterteeth'
+ _TESTS = [{
+ 'url': 'http://roosterteeth.com/episode/million-dollars-but-season-2-million-dollars-but-the-game-announcement',
+ 'md5': 'e2bd7764732d785ef797700a2489f212',
+ 'info_dict': {
+- 'id': '26576',
++ 'id': '9156',
+ 'display_id': 'million-dollars-but-season-2-million-dollars-but-the-game-announcement',
+ 'ext': 'mp4',
+- 'title': 'Million Dollars, But...: Million Dollars, But... The Game Announcement',
++ 'title': 'Million Dollars, But... The Game Announcement',
+ 'description': 'md5:0cc3b21986d54ed815f5faeccd9a9ca5',
+ 'thumbnail': r're:^https?://.*\.png$',
+ 'series': 'Million Dollars, But...',
+- 'episode': 'Million Dollars, But... The Game Announcement',
+- 'comment_count': int,
++ 'episode': 'S2:E10 - Million Dollars, But... The Game Announcement',
+ },
+ }, {
+ 'url': 'http://achievementhunter.roosterteeth.com/episode/off-topic-the-achievement-hunter-podcast-2016-i-didn-t-think-it-would-pass-31',
+@@ -54,64 +56,94 @@ def _login(self):
+ if username is None:
+ return
+
+- login_page = self._download_webpage(
+- self._LOGIN_URL, None,
+- note='Downloading login page',
+- errnote='Unable to download login page')
+-
+- login_form = self._hidden_inputs(login_page)
+-
+- login_form.update({
+- 'username': username,
+- 'password': password,
+- })
++ cookie = self._get_cookie('rt_access_token')
++ if cookie and not cookie.is_expired():
++ self._ACCESS_TOKEN = cookie.value
++ return
+
+- login_request = self._download_webpage(
++ response = self._download_json(
+ self._LOGIN_URL, None,
+ note='Logging in',
+- data=urlencode_postdata(login_form),
+- headers={
+- 'Referer': self._LOGIN_URL,
++ errnote='Unable to log in',
++ data=urlencode_postdata({
++ 'username': username,
++ 'password': password,
++ 'client_id': '4338d2b4bdc8db1239360f28e72f0d9ddb1fd01e7a38fbb07b4b1f4ba4564cc5',
++ 'grant_type': 'password',
+ })
++ )
+
+- if not any(re.search(p, login_request) for p in (
+- r'href=["\']https?://(?:www\.)?roosterteeth\.com/logout"',
+- r'>Sign Out<')):
+- error = self._html_search_regex(
+- r'(?s)<div[^>]+class=(["\']).*?\balert-danger\b.*?\1[^>]*>(?:\s*<button[^>]*>.*?</button>)?(?P<error>.+?)</div>',
+- login_request, 'alert', default=None, group='error')
+- if error:
+- raise ExtractorError('Unable to login: %s' % error, expected=True)
++ self._ACCESS_TOKEN = response.get('access_token')
++ if not self._ACCESS_TOKEN:
+ raise ExtractorError('Unable to log in')
+
++ created_at = response.get('created_at', 0)
++ expires_in = response.get('expires_in', 0)
++
++ self._set_cookie('.roosterteeth.com', 'rt_access_token', self._ACCESS_TOKEN, created_at + expires_in)
++
+ def _real_initialize(self):
+ self._login()
+
+ def _real_extract(self, url):
+ display_id = self._match_id(url)
+
+- webpage = self._download_webpage(url, display_id)
+-
+- episode = strip_or_none(unescapeHTML(self._search_regex(
+- (r'videoTitle\s*=\s*(["\'])(?P<title>(?:(?!\1).)+)\1',
+- r'<title>(?P<title>[^<]+)</title>'), webpage, 'title',
+- default=None, group='title')))
+-
+- title = strip_or_none(self._og_search_title(
+- webpage, default=None)) or episode
+-
+- m3u8_url = self._search_regex(
+- r'file\s*:\s*(["\'])(?P<url>http.+?\.m3u8.*?)\1',
+- webpage, 'm3u8 url', default=None, group='url')
+-
++ headers = {}
++ if self._ACCESS_TOKEN:
++ headers['Authorization'] = 'Bearer ' + self._ACCESS_TOKEN
++
++ api_response = self._call_api(
++ display_id,
++ note='Downloading video information (1/2)',
++ errnote='Unable to download video information (1/2)',
++ headers=headers,
++ )
++
++ data = api_response['data'][0]
++
++ attributes = data['attributes']
++ episode = attributes.get('display_title')
++ title = attributes['title']
++ description = attributes.get('caption')
++ series = attributes.get('show_title')
++
++ thumbnails = []
++ for i, size in enumerate(['thumb', 'small', 'medium', 'large']):
++ thumbnail = try_get(data, lambda x: x['included']['images'][0]['attributes'][size], compat_str)
++ if thumbnail:
++ thumbnails.append({'url': thumbnail, 'id': i})
++
++ video_response = self._call_api(
++ display_id,
++ path='/videos',
++ note='Downloading video information (2/2)',
++ errnote='Unable to download video information (2/2)',
++ headers=headers,
++ )
++
++ if video_response.get('access') is not None:
++ now = time.time()
++ sponsor_golive = unified_timestamp(attributes.get('sponsor_golive_at'))
++ member_golive = unified_timestamp(attributes.get('member_golive_at'))
++ public_golive = unified_timestamp(attributes.get('public_golive_at'))
++
++ if attributes.get('is_sponsors_only', False):
++ if now < sponsor_golive:
++ self._golive_error(display_id, 'FIRST members')
++ else:
++ self.raise_login_required('{0} is only available for FIRST members'.format(display_id))
++ else:
++ if now < member_golive:
++ self._golive_error(display_id, 'site members')
++ elif now < public_golive:
++ self._golive_error(display_id, 'the public')
++ else:
++ raise ExtractorError('Video is not available')
++
++ video_attributes = try_get(video_response, lambda x: x['data'][0]['attributes'])
++
++ m3u8_url = video_attributes.get('url')
+ if not m3u8_url:
+- if re.search(r'<div[^>]+class=["\']non-sponsor', webpage):
+- self.raise_login_required(
+- '%s is only available for FIRST members' % display_id)
+-
+- if re.search(r'<div[^>]+class=["\']golive-gate', webpage):
+- self.raise_login_required('%s is not available yet' % display_id)
+-
+ raise ExtractorError('Unable to extract m3u8 URL')
+
+ formats = self._extract_m3u8_formats(
+@@ -119,30 +151,31 @@ def _real_extract(self, url):
+ entry_protocol='m3u8_native', m3u8_id='hls')
+ self._sort_formats(formats)
+
+- description = strip_or_none(self._og_search_description(webpage))
+- thumbnail = self._proto_relative_url(self._og_search_thumbnail(webpage))
+-
+- series = self._search_regex(
+- (r'<h2>More ([^<]+)</h2>', r'<a[^>]+>See All ([^<]+) Videos<'),
+- webpage, 'series', fatal=False)
+-
+- comment_count = int_or_none(self._search_regex(
+- r'>Comments \((\d+)\)<', webpage,
+- 'comment count', fatal=False))
+-
+- video_id = self._search_regex(
+- (r'containerId\s*=\s*["\']episode-(\d+)\1',
+- r'<div[^<]+id=["\']episode-(\d+)'), webpage,
+- 'video id', default=display_id)
++ video_id = str_or_none(video_attributes.get('content_id'))
+
+ return {
+ 'id': video_id,
+ 'display_id': display_id,
+ 'title': title,
+ 'description': description,
+- 'thumbnail': thumbnail,
++ 'thumbnails': thumbnails,
+ 'series': series,
+ 'episode': episode,
+- 'comment_count': comment_count,
+ 'formats': formats,
+ }
++
++ def _golive_error(self, video_id, member_level):
++ raise ExtractorError('{0} is not yet live for {1}'.format(video_id, member_level))
++
++ def _call_api(self, video_id, path=None, **kwargs):
++ url = self._API_URL + video_id
++ if path:
++ url = url + path
++
++ return self._download_json(url, video_id, **kwargs)
++
++ def _get_cookie(self, name):
++ for cookie in self._downloader.cookiejar:
++ if cookie.name == name:
++ return cookie
++ return None
diff --git a/patches/net-vpn/tor-0.3.2.9/tor-0.3.2.9-fix redefinition of unsigned u.patch b/patches/net-vpn/tor-0.3.2.9/tor-0.3.2.9-fix redefinition of unsigned u.patch
@@ -0,0 +1,18 @@
+diff --git a/src/or/channeltls.c b/src/or/channeltls.c
+index 8277813..900bff9 100644
+--- a/src/or/channeltls.c
++++ b/src/or/channeltls.c
+@@ -2156,10 +2156,11 @@ channel_tls_process_certs_cell(var_cell_t *cell, channel_tls_t *chan)
+ }
+
+ err:
+- for (unsigned u = 0; u < ARRAY_LENGTH(x509_certs); ++u) {
++ unsigned u = 0;
++ for (u = 0; u < ARRAY_LENGTH(x509_certs); ++u) {
+ tor_x509_cert_free(x509_certs[u]);
+ }
+- for (unsigned u = 0; u < ARRAY_LENGTH(ed_certs); ++u) {
++ for (u = 0; u < ARRAY_LENGTH(ed_certs); ++u) {
+ tor_cert_free(ed_certs[u]);
+ }
+ tor_free(rsa_ed_cc_cert);
diff --git a/patches/sys-libs/glibc/glibc-2.27-meme-sigsegv-message.patch b/patches/sys-libs/glibc/glibc-2.27-meme-sigsegv-message.patch
@@ -0,0 +1,13 @@
+diff --git a/sysdeps/generic/siglist.h.old b/sysdeps/generic/siglist.h
+index 99d05b2..fc46574 100644
+--- a/sysdeps/generic/siglist.h.old
++++ b/sysdeps/generic/siglist.h
+@@ -36,7 +36,7 @@
+ init_sig (SIGKILL, "KILL", N_("Killed"))
+ init_sig (SIGBUS, "BUS", N_("Bus error"))
+ init_sig (SIGSYS, "SYS", N_("Bad system call"))
+- init_sig (SIGSEGV, "SEGV", N_("Segmentation fault"))
++ init_sig (SIGSEGV, "SEGV", N_("it done did a broke (SEGV)"))
+ init_sig (SIGPIPE, "PIPE", N_("Broken pipe"))
+ init_sig (SIGALRM, "ALRM", N_("Alarm clock"))
+ init_sig (SIGTERM, "TERM", N_("Terminated"))
diff --git a/patches/sys-libs/glibc/stfu-rms-on-abort.patch b/patches/sys-libs/glibc/stfu-rms-on-abort.patch
@@ -0,0 +1,21 @@
+X-Git-Url: https://sourceware.org/git/?p=glibc.git;a=blobdiff_plain;f=manual%2Fstartup.texi;h=21c48cd0374dcc906c33165267412081fc7de2dc;hp=7395d32dd0c877487938857fd432650e87fe7bb2;hb=340d9652b9d0e1d4136588f18b726662d195777c;hpb=c57bf7c15ba179168d01f7c6acde7ecbf5dd9cd8
+
+diff --git a/manual/startup.texi b/manual/startup.texi
+index 7395d32..21c48cd 100644
+--- a/manual/startup.texi
++++ b/manual/startup.texi
+@@ -1005,14 +1005,6 @@ This function actually terminates the process by raising a
+ intercept this signal; see @ref{Signal Handling}.
+ @end deftypefun
+
+-@c Put in by rms. Don't remove.
+-@cartouche
+-@strong{Future Change Warning:} Proposed Federal censorship regulations
+-may prohibit us from giving you information about the possibility of
+-calling this function. We would be required to say that this is not an
+-acceptable way of terminating a program.
+-@end cartouche
+-
+ @node Termination Internals
+ @subsection Termination Internals
+
diff --git a/patches/sys-libs/libomp/FreeBSD_bug32279.patch b/patches/sys-libs/libomp/FreeBSD_bug32279.patch
@@ -0,0 +1,16 @@
+diff --git a/runtime/cmake/LibompHandleFlags.cmake.old b/runtime/cmake/LibompHandleFlags.cmake
+index 4bdbf8f..a411119 100644
+--- a/runtime/cmake/LibompHandleFlags.cmake.old
++++ b/runtime/cmake/LibompHandleFlags.cmake
+@@ -152,6 +152,11 @@ function(libomp_get_libflags libflags)
+ if(${IA32})
+ libomp_append(libflags_local -lirc_pic LIBOMP_HAVE_IRC_PIC_LIBRARY)
+ endif()
++ IF(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
++ libomp_append(libflags_local "-Wl,--no-as-needed" LIBOMP_HAVE_AS_NEEDED_FLAG)
++ libomp_append(libflags_local -lm)
++ libomp_append(libflags_local "-Wl,--as-needed" LIBOMP_HAVE_AS_NEEDED_FLAG)
++ ENDIF(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
+ IF(${CMAKE_SYSTEM_NAME} MATCHES "NetBSD")
+ libomp_append(libflags_local -lm)
+ ENDIF(${CMAKE_SYSTEM_NAME} MATCHES "NetBSD")
diff --git a/patches/www-client/firefox/firefox-solarized-view-source.diff b/patches/www-client/firefox/firefox-solarized-view-source.diff
@@ -0,0 +1,70 @@
+--- firefox-52.2.0esr/layout/style/res/viewsource.css.old 2017-07-24 03:27:24.487605257 +0200
++++ firefox-52.2.0esr/layout/style/res/viewsource.css 2017-07-24 03:29:46.253217198 +0200
+@@ -6,8 +6,8 @@
+ @namespace url(http://www.w3.org/1999/xhtml); /* set default namespace to HTML */
+
+ *|*:root {
+- background-color: white;
+- color: black;
++ background-color: #002b36;
++ color: #839496;
+ direction: ltr;
+ -moz-control-character-visibility: visible;
+ height: 100%;
+@@ -20,7 +20,7 @@
+ height: 100%;
+ box-sizing: border-box;
+ margin: 0;
+- padding: 8px;
++ padding: 0;
+ }
+ #viewsource.wrap {
+ white-space: pre-wrap;
+@@ -41,20 +41,21 @@
+ width: 5ch;
+ margin: 0 0 0 -5ch;
+ text-align: right;
+- color: #ccc;
++ color: #93a1a1;
++ background-color: #073642;
+ font-weight: normal;
+ font-style: normal;
+ }
+ .highlight .start-tag {
+- color: purple;
++ color: #6c71c4;
+ font-weight: bold;
+ }
+ .highlight .end-tag {
+- color: purple;
++ color: #6c71c4;
+ font-weight: bold;
+ }
+ .highlight .comment {
+- color: green;
++ color: #586e75;
+ font-style: italic;
+ }
+ .highlight .cdata {
+@@ -76,11 +77,11 @@
+ font-weight: normal;
+ }
+ .highlight .attribute-name {
+- color: black;
++ color: #cb4b16;
+ font-weight: bold;
+ }
+ .highlight .attribute-value {
+- color: blue;
++ color: #2aa198;
+ font-weight: normal;
+ }
+ .highlight .markupdeclaration {
+@@ -96,6 +97,6 @@
+ .highlight .error,
+ .highlight .error > :-moz-any(.start-tag, .end-tag, .comment, .cdata, .doctype,
+ .pi, .entity, .attribute-name, .attribute-value) {
+- color: red;
++ color: #dc322f;
+ font-weight: bold;
+ }
diff --git a/patches/www-servers/nginx/00 no bgwhite.patch b/patches/www-servers/nginx/00 no bgwhite.patch
@@ -0,0 +1,11 @@
+--- nginx-1.12.1/src/http/modules/ngx_http_autoindex_module.c.old 2017-08-12 17:03:38.956602736 +0200
++++ nginx-1.12.1/src/http/modules/ngx_http_autoindex_module.c 2017-08-12 17:04:06.514291803 +0200
+@@ -446,7 +446,7 @@
+
+ static u_char header[] =
+ "</title></head>" CRLF
+- "<body bgcolor=\"white\">" CRLF
++ "<body>" CRLF
+ "<h1>Index of "
+ ;
+
diff --git a/patches/www-servers/nginx/01 ISO 8601.patch b/patches/www-servers/nginx/01 ISO 8601.patch
@@ -0,0 +1,24 @@
+--- nginx-1.12.1/src/http/modules/ngx_http_autoindex_module.c.old 2017-08-12 17:06:14.873525862 +0200
++++ nginx-1.12.1/src/http/modules/ngx_http_autoindex_module.c 2017-08-12 17:07:32.167042961 +0200
+@@ -455,9 +455,6 @@
+ "</html>" CRLF
+ ;
+
+- static char *months[] = { "Jan", "Feb", "Mar", "Apr", "May", "Jun",
+- "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" };
+-
+ if (r->headers_out.charset.len == 5
+ && ngx_strncasecmp(r->headers_out.charset.data, (u_char *) "utf-8", 5)
+ == 0)
+@@ -617,9 +614,9 @@
+
+ ngx_gmtime(entry[i].mtime + tp->gmtoff * 60 * alcf->localtime, &tm);
+
+- b->last = ngx_sprintf(b->last, "%02d-%s-%d %02d:%02d ",
++ b->last = ngx_sprintf(b->last, "%02d-%02d-%02d %02d:%02d ",
+ tm.ngx_tm_mday,
+- months[tm.ngx_tm_mon - 1],
++ tm.ngx_tm_mon,
+ tm.ngx_tm_year,
+ tm.ngx_tm_hour,
+ tm.ngx_tm_min);
diff --git a/patches/www-servers/nginx/02 custom autoindex.patch b/patches/www-servers/nginx/02 custom autoindex.patch
@@ -0,0 +1,185 @@
+diff --git a/src/http/modules/ngx_http_autoindex_module.c.old b/src/http/modules/ngx_http_autoindex_module.c
+index 2af88a0..18c7570 100644
+--- a/src/http/modules/ngx_http_autoindex_module.c.old
++++ b/src/http/modules/ngx_http_autoindex_module.c
+@@ -52,9 +52,6 @@ typedef struct {
+
+ #define NGX_HTTP_AUTOINDEX_PREALLOCATE 50
+
+-#define NGX_HTTP_AUTOINDEX_NAME_LEN 50
+-
+-
+ static ngx_buf_t *ngx_http_autoindex_html(ngx_http_request_t *r,
+ ngx_array_t *entries);
+ static ngx_buf_t *ngx_http_autoindex_json(ngx_http_request_t *r,
+@@ -478,7 +475,8 @@ ngx_http_autoindex_html(ngx_http_request_t *r, ngx_array_t *entries)
+ + sizeof(header) - 1
+ + r->uri.len + escape_html
+ + sizeof("</h1>") - 1
+- + sizeof("<hr><pre><a href=\"../\">../</a>" CRLF) - 1
++ + sizeof("<table><tr><th>Name</th><th>Date</th><th>Size</th></tr>" CRLF) - 1
++ + sizeof("<tr><td><a href=\"../\">../</a></td></tr>" CRLF) - 1
+ + sizeof("</pre><hr>") - 1
+ + sizeof(tail) - 1;
+
+@@ -499,15 +497,13 @@ ngx_http_autoindex_html(ngx_http_request_t *r, ngx_array_t *entries)
+ }
+
+ len += sizeof("<a href=\"") - 1
+- + entry[i].name.len + entry[i].escape
++ + entry[i].name.len
+ + 1 /* 1 is for "/" */
+ + sizeof("\">") - 1
+- + entry[i].name.len - entry[i].utf_len
+- + entry[i].escape_html
+- + NGX_HTTP_AUTOINDEX_NAME_LEN + sizeof(">") - 2
++ + entry[i].utf_len
+ + sizeof("</a>") - 1
+ + sizeof(" 28-Sep-1970 12:00 ") - 1
+- + 20 /* the file size */
++ + 256 /* the file size */
+ + 2;
+ }
+
+@@ -531,14 +527,14 @@ ngx_http_autoindex_html(ngx_http_request_t *r, ngx_array_t *entries)
+
+ b->last = ngx_cpymem(b->last, "</h1>", sizeof("</h1>") - 1);
+
+- b->last = ngx_cpymem(b->last, "<hr><pre><a href=\"../\">../</a>" CRLF,
+- sizeof("<hr><pre><a href=\"../\">../</a>" CRLF) - 1);
++ b->last = ngx_cpymem(b->last, "<hr><table><tr><th>Name</th><th>Date</th><th>Size</th></tr>" CRLF "<tr><td><a href=\"../\">../</a></td></tr>" CRLF,
++ sizeof("<hr><table><tr><th>Name</th><th>Date</th><th>Size</th></tr>" CRLF "<tr><td><a href=\"../\">../</a></td></tr>" CRLF) - 1);
+
+ alcf = ngx_http_get_module_loc_conf(r, ngx_http_autoindex_module);
+ tp = ngx_timeofday();
+
+ for (i = 0; i < entries->nelts; i++) {
+- b->last = ngx_cpymem(b->last, "<a href=\"", sizeof("<a href=\"") - 1);
++ b->last = ngx_cpymem(b->last, "<tr><td><a href=\"", sizeof("<tr><td><a href=\"") - 1);
+
+ if (entry[i].escape) {
+ ngx_escape_uri(b->last, entry[i].name.data, entry[i].name.len,
+@@ -558,69 +554,19 @@ ngx_http_autoindex_html(ngx_http_request_t *r, ngx_array_t *entries)
+ *b->last++ = '"';
+ *b->last++ = '>';
+
+- len = entry[i].utf_len;
+-
+- if (entry[i].name.len != len) {
+- if (len > NGX_HTTP_AUTOINDEX_NAME_LEN) {
+- char_len = NGX_HTTP_AUTOINDEX_NAME_LEN - 3 + 1;
+-
+- } else {
+- char_len = NGX_HTTP_AUTOINDEX_NAME_LEN + 1;
+- }
+-
+- last = b->last;
+- b->last = ngx_utf8_cpystrn(b->last, entry[i].name.data,
+- char_len, entry[i].name.len + 1);
++ b->last = ngx_cpymem(b->last, entry[i].name.data,
++ entry[i].name.len);
+
+- if (entry[i].escape_html) {
+- b->last = (u_char *) ngx_escape_html(last, entry[i].name.data,
+- b->last - last);
+- }
+-
+- last = b->last;
+-
+- } else {
+- if (entry[i].escape_html) {
+- if (len > NGX_HTTP_AUTOINDEX_NAME_LEN) {
+- char_len = NGX_HTTP_AUTOINDEX_NAME_LEN - 3;
+-
+- } else {
+- char_len = len;
+- }
+-
+- b->last = (u_char *) ngx_escape_html(b->last,
+- entry[i].name.data, char_len);
+- last = b->last;
+-
+- } else {
+- b->last = ngx_cpystrn(b->last, entry[i].name.data,
+- NGX_HTTP_AUTOINDEX_NAME_LEN + 1);
+- last = b->last - 3;
+- }
+- }
+-
+- if (len > NGX_HTTP_AUTOINDEX_NAME_LEN) {
+- b->last = ngx_cpymem(last, "..></a>", sizeof("..></a>") - 1);
+-
+- } else {
+- if (entry[i].dir && NGX_HTTP_AUTOINDEX_NAME_LEN - len > 0) {
+- *b->last++ = '/';
+- len++;
+- }
+-
+- b->last = ngx_cpymem(b->last, "</a>", sizeof("</a>") - 1);
+-
+- if (NGX_HTTP_AUTOINDEX_NAME_LEN - len > 0) {
+- ngx_memset(b->last, ' ', NGX_HTTP_AUTOINDEX_NAME_LEN - len);
+- b->last += NGX_HTTP_AUTOINDEX_NAME_LEN - len;
+- }
++ if (entry[i].dir) {
++ *b->last++ = '/';
++ len++;
+ }
+
+- *b->last++ = ' ';
++ b->last = ngx_cpymem(b->last, "</a></td>", sizeof("</a></td>") - 1);
+
+ ngx_gmtime(entry[i].mtime + tp->gmtoff * 60 * alcf->localtime, &tm);
+
+- b->last = ngx_sprintf(b->last, "%02d-%02d-%02d %02d:%02d ",
++ b->last = ngx_sprintf(b->last, "<td>%02d-%02d-%02d %02d:%02d</td>",
+ tm.ngx_tm_mday,
+ tm.ngx_tm_mon,
+ tm.ngx_tm_year,
+@@ -628,19 +574,12 @@ ngx_http_autoindex_html(ngx_http_request_t *r, ngx_array_t *entries)
+ tm.ngx_tm_min);
+
+ if (alcf->exact_size) {
+- if (entry[i].dir) {
+- b->last = ngx_cpymem(b->last, " -",
+- sizeof(" -") - 1);
+- } else {
+- b->last = ngx_sprintf(b->last, "%19O", entry[i].size);
++ if (!entry[i].dir) {
++ b->last = ngx_sprintf(b->last, "<td>%O</td>", entry[i].size);
+ }
+
+ } else {
+- if (entry[i].dir) {
+- b->last = ngx_cpymem(b->last, " -",
+- sizeof(" -") - 1);
+-
+- } else {
++ if (!entry[i].dir) {
+ length = entry[i].size;
+
+ if (length > 1024 * 1024 * 1024 - 1) {
+@@ -672,19 +611,18 @@ ngx_http_autoindex_html(ngx_http_request_t *r, ngx_array_t *entries)
+ }
+
+ if (scale) {
+- b->last = ngx_sprintf(b->last, "%6i%c", size, scale);
++ b->last = ngx_sprintf(b->last, "<td>%i%c</td>", size, scale);
+
+ } else {
+- b->last = ngx_sprintf(b->last, " %6i", size);
++ b->last = ngx_sprintf(b->last, "<td>%i</td>", size);
+ }
+ }
+ }
+
+- *b->last++ = CR;
+- *b->last++ = LF;
++ b->last = ngx_sprintf(b->last, "</tr>" CRLF);
+ }
+
+- b->last = ngx_cpymem(b->last, "</pre><hr>", sizeof("</pre><hr>") - 1);
++ b->last = ngx_cpymem(b->last, "</table>", sizeof("</table>") - 1);
+
+ b->last = ngx_cpymem(b->last, tail, sizeof(tail) - 1);
+
diff --git a/patches/www-servers/nginx/03 autoindex styling.patch b/patches/www-servers/nginx/03 autoindex styling.patch
@@ -0,0 +1,16 @@
+diff --git a/src/http/modules/ngx_http_autoindex_module.c.old b/src/http/modules/ngx_http_autoindex_module.c
+index 18c7570..94176b4 100644
+--- a/src/http/modules/ngx_http_autoindex_module.c.old
++++ b/src/http/modules/ngx_http_autoindex_module.c
+@@ -448,8 +448,9 @@ ngx_http_autoindex_html(ngx_http_request_t *r, ngx_array_t *entries)
+ ;
+
+ static u_char header[] =
+- "</title></head>" CRLF
+- "<body>" CRLF
++ "</title>" CRLF
++ "<style>td{font-family:monospace;}td:nth-child(3){text-align:right;}</style>" CRLF
++ "</head><body>" CRLF
+ "<h1>Index of "
+ ;
+
diff --git a/patches/x11-libs/cairo-1.14.12/cairo-1.14.6-macos.patch b/patches/x11-libs/cairo-1.14.12/cairo-1.14.6-macos.patch
@@ -0,0 +1,103 @@
+diff --git a/configure b/configure
+index 6476db0..e1cbe17 100755
+--- a/configure
++++ b/configure
+@@ -19177,7 +19177,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
+@@ -19224,7 +19224,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
+@@ -19275,7 +19275,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
+@@ -19322,7 +19322,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
+@@ -19391,7 +19391,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
+@@ -19447,7 +19447,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
+@@ -20920,7 +20920,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
+@@ -20967,7 +20967,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
+@@ -34129,7 +34129,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
+@@ -34248,7 +34248,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
+@@ -34329,7 +34329,7 @@ fi
+ rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+- if test "x$cairo_cc_stderr" != "x"; then
++ if false; then
+ cairo_cc_flag=no
+ fi
+
diff --git a/patches/x11-terms/st-0.8.1/0001-apply-01b-my-config.diff.patch b/patches/x11-terms/st-0.8.1/0001-apply-01b-my-config.diff.patch
@@ -0,0 +1,34 @@
+From 170a93a33ba5545aaab2d0a5b7aefe084b4af3cd Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Mon, 1 Oct 2018 01:08:20 +0200
+Subject: [PATCH 1/3] apply: 01b-my-config.diff
+
+---
+ config.def.h | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/config.def.h b/config.def.h
+index 82b1b09..3c587e2 100644
+--- a/config.def.h
++++ b/config.def.h
+@@ -5,7 +5,7 @@
+ *
+ * font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html
+ */
+-static char *font = "Liberation Mono:pixelsize=12:antialias=true:autohint=true";
++static char *font = "monospace-7";
+ static int borderpx = 2;
+
+ /*
+@@ -32,7 +32,7 @@ static float chscale = 1.0;
+ *
+ * More advanced example: " `'\"()[]{}"
+ */
+-char *worddelimiters = " ";
++char *worddelimiters = " │`'\"()[]{}“”<>‘’\~\;";
+
+ /* selection timeouts (in milliseconds) */
+ static unsigned int doubleclicktimeout = 300;
+--
+2.19.1
+
diff --git a/patches/x11-terms/st-0.8.1/0002-Fix-keyboard-input-on-terminal.patch b/patches/x11-terms/st-0.8.1/0002-Fix-keyboard-input-on-terminal.patch
@@ -0,0 +1,770 @@
+From fa87c7afac1f0f1a866d7b7e1bb6f9d28ba97d37 Mon Sep 17 00:00:00 2001
+From: Jan Christoph Ebersbach <jceb@e-jc.de>
+Date: Mon, 1 Oct 2018 01:38:52 +0200
+Subject: [PATCH 2/3] Fix keyboard input on terminal
+
+URL: http://st.suckless.org/patches/fix_keyboard_input
+---
+ config.def.h | 691 +++++++++++++++++++++++++++++++++++++++++++++++----
+ 1 file changed, 641 insertions(+), 50 deletions(-)
+
+diff --git a/config.def.h b/config.def.h
+index 3c587e2..1ea6902 100644
+--- a/config.def.h
++++ b/config.def.h
+@@ -209,7 +209,80 @@ static Shortcut shortcuts[] = {
+ * If you want keys other than the X11 function keys (0xFD00 - 0xFFFF)
+ * to be mapped below, add them to this array.
+ */
+-static KeySym mappedkeys[] = { -1 };
++static KeySym mappedkeys[] = {
++ XK_space,
++ XK_m,
++ XK_i,
++ XK_A,
++ XK_B,
++ XK_C,
++ XK_D,
++ XK_E,
++ XK_F,
++ XK_G,
++ XK_H,
++ XK_I,
++ XK_K,
++ XK_J,
++ XK_L,
++ XK_M,
++ XK_N,
++ XK_O,
++ XK_P,
++ XK_Q,
++ XK_R,
++ XK_S,
++ XK_T,
++ XK_U,
++ XK_V,
++ XK_W,
++ XK_X,
++ XK_Y,
++ XK_Z,
++ XK_Z,
++ XK_0,
++ XK_1,
++ XK_2,
++ XK_3,
++ XK_4,
++ XK_5,
++ XK_6,
++ XK_7,
++ XK_8,
++ XK_9,
++ XK_exclam,
++ XK_quotedbl,
++ XK_numbersign,
++ XK_dollar,
++ XK_percent,
++ XK_ampersand,
++ XK_apostrophe,
++ XK_parenleft,
++ XK_parenright,
++ XK_asterisk,
++ XK_plus,
++ XK_comma,
++ XK_minus,
++ XK_period,
++ XK_slash,
++ XK_colon,
++ XK_semicolon,
++ XK_less,
++ XK_equal,
++ XK_greater,
++ XK_question,
++ XK_at,
++ XK_bracketleft,
++ XK_backslash,
++ XK_bracketright,
++ XK_asciicircum,
++ XK_underscore,
++ XK_grave,
++ XK_braceleft,
++ XK_bar,
++ XK_braceright,
++ XK_asciitilde,
++};
+
+ /*
+ * State bits to ignore when matching key or button events. By default,
+@@ -232,59 +305,20 @@ static Key key[] = {
+ /* keysym mask string appkey appcursor */
+ { XK_KP_Home, ShiftMask, "\033[2J", 0, -1},
+ { XK_KP_Home, ShiftMask, "\033[1;2H", 0, +1},
+- { XK_KP_Home, XK_ANY_MOD, "\033[H", 0, -1},
+- { XK_KP_Home, XK_ANY_MOD, "\033[1~", 0, +1},
+- { XK_KP_Up, XK_ANY_MOD, "\033Ox", +1, 0},
+- { XK_KP_Up, XK_ANY_MOD, "\033[A", 0, -1},
+- { XK_KP_Up, XK_ANY_MOD, "\033OA", 0, +1},
+- { XK_KP_Down, XK_ANY_MOD, "\033Or", +1, 0},
+- { XK_KP_Down, XK_ANY_MOD, "\033[B", 0, -1},
+- { XK_KP_Down, XK_ANY_MOD, "\033OB", 0, +1},
+- { XK_KP_Left, XK_ANY_MOD, "\033Ot", +1, 0},
+- { XK_KP_Left, XK_ANY_MOD, "\033[D", 0, -1},
+- { XK_KP_Left, XK_ANY_MOD, "\033OD", 0, +1},
+- { XK_KP_Right, XK_ANY_MOD, "\033Ov", +1, 0},
+- { XK_KP_Right, XK_ANY_MOD, "\033[C", 0, -1},
+- { XK_KP_Right, XK_ANY_MOD, "\033OC", 0, +1},
+ { XK_KP_Prior, ShiftMask, "\033[5;2~", 0, 0},
+- { XK_KP_Prior, XK_ANY_MOD, "\033[5~", 0, 0},
+- { XK_KP_Begin, XK_ANY_MOD, "\033[E", 0, 0},
+ { XK_KP_End, ControlMask, "\033[J", -1, 0},
+ { XK_KP_End, ControlMask, "\033[1;5F", +1, 0},
+ { XK_KP_End, ShiftMask, "\033[K", -1, 0},
+ { XK_KP_End, ShiftMask, "\033[1;2F", +1, 0},
+- { XK_KP_End, XK_ANY_MOD, "\033[4~", 0, 0},
+ { XK_KP_Next, ShiftMask, "\033[6;2~", 0, 0},
+- { XK_KP_Next, XK_ANY_MOD, "\033[6~", 0, 0},
+ { XK_KP_Insert, ShiftMask, "\033[2;2~", +1, 0},
+ { XK_KP_Insert, ShiftMask, "\033[4l", -1, 0},
+ { XK_KP_Insert, ControlMask, "\033[L", -1, 0},
+ { XK_KP_Insert, ControlMask, "\033[2;5~", +1, 0},
+- { XK_KP_Insert, XK_ANY_MOD, "\033[4h", -1, 0},
+- { XK_KP_Insert, XK_ANY_MOD, "\033[2~", +1, 0},
+ { XK_KP_Delete, ControlMask, "\033[M", -1, 0},
+ { XK_KP_Delete, ControlMask, "\033[3;5~", +1, 0},
+ { XK_KP_Delete, ShiftMask, "\033[2K", -1, 0},
+ { XK_KP_Delete, ShiftMask, "\033[3;2~", +1, 0},
+- { XK_KP_Delete, XK_ANY_MOD, "\033[P", -1, 0},
+- { XK_KP_Delete, XK_ANY_MOD, "\033[3~", +1, 0},
+- { XK_KP_Multiply, XK_ANY_MOD, "\033Oj", +2, 0},
+- { XK_KP_Add, XK_ANY_MOD, "\033Ok", +2, 0},
+- { XK_KP_Enter, XK_ANY_MOD, "\033OM", +2, 0},
+- { XK_KP_Enter, XK_ANY_MOD, "\r", -1, 0},
+- { XK_KP_Subtract, XK_ANY_MOD, "\033Om", +2, 0},
+- { XK_KP_Decimal, XK_ANY_MOD, "\033On", +2, 0},
+- { XK_KP_Divide, XK_ANY_MOD, "\033Oo", +2, 0},
+- { XK_KP_0, XK_ANY_MOD, "\033Op", +2, 0},
+- { XK_KP_1, XK_ANY_MOD, "\033Oq", +2, 0},
+- { XK_KP_2, XK_ANY_MOD, "\033Or", +2, 0},
+- { XK_KP_3, XK_ANY_MOD, "\033Os", +2, 0},
+- { XK_KP_4, XK_ANY_MOD, "\033Ot", +2, 0},
+- { XK_KP_5, XK_ANY_MOD, "\033Ou", +2, 0},
+- { XK_KP_6, XK_ANY_MOD, "\033Ov", +2, 0},
+- { XK_KP_7, XK_ANY_MOD, "\033Ow", +2, 0},
+- { XK_KP_8, XK_ANY_MOD, "\033Ox", +2, 0},
+- { XK_KP_9, XK_ANY_MOD, "\033Oy", +2, 0},
+ { XK_Up, ShiftMask, "\033[1;2A", 0, 0},
+ { XK_Up, Mod1Mask, "\033[1;3A", 0, 0},
+ { XK_Up, ShiftMask|Mod1Mask,"\033[1;4A", 0, 0},
+@@ -323,36 +357,27 @@ static Key key[] = {
+ { XK_Right, XK_ANY_MOD, "\033OC", 0, +1},
+ { XK_ISO_Left_Tab, ShiftMask, "\033[Z", 0, 0},
+ { XK_Return, Mod1Mask, "\033\r", 0, 0},
+- { XK_Return, XK_ANY_MOD, "\r", 0, 0},
++ { XK_Return, XK_NO_MOD, "\r", 0, 0},
+ { XK_Insert, ShiftMask, "\033[4l", -1, 0},
+ { XK_Insert, ShiftMask, "\033[2;2~", +1, 0},
+ { XK_Insert, ControlMask, "\033[L", -1, 0},
+ { XK_Insert, ControlMask, "\033[2;5~", +1, 0},
+- { XK_Insert, XK_ANY_MOD, "\033[4h", -1, 0},
+- { XK_Insert, XK_ANY_MOD, "\033[2~", +1, 0},
+ { XK_Delete, ControlMask, "\033[M", -1, 0},
+ { XK_Delete, ControlMask, "\033[3;5~", +1, 0},
+ { XK_Delete, ShiftMask, "\033[2K", -1, 0},
+ { XK_Delete, ShiftMask, "\033[3;2~", +1, 0},
+- { XK_Delete, XK_ANY_MOD, "\033[P", -1, 0},
+- { XK_Delete, XK_ANY_MOD, "\033[3~", +1, 0},
+ { XK_BackSpace, XK_NO_MOD, "\177", 0, 0},
+ { XK_BackSpace, Mod1Mask, "\033\177", 0, 0},
+ { XK_Home, ShiftMask, "\033[2J", 0, -1},
+ { XK_Home, ShiftMask, "\033[1;2H", 0, +1},
+- { XK_Home, XK_ANY_MOD, "\033[H", 0, -1},
+- { XK_Home, XK_ANY_MOD, "\033[1~", 0, +1},
+ { XK_End, ControlMask, "\033[J", -1, 0},
+ { XK_End, ControlMask, "\033[1;5F", +1, 0},
+ { XK_End, ShiftMask, "\033[K", -1, 0},
+ { XK_End, ShiftMask, "\033[1;2F", +1, 0},
+- { XK_End, XK_ANY_MOD, "\033[4~", 0, 0},
+ { XK_Prior, ControlMask, "\033[5;5~", 0, 0},
+ { XK_Prior, ShiftMask, "\033[5;2~", 0, 0},
+- { XK_Prior, XK_ANY_MOD, "\033[5~", 0, 0},
+ { XK_Next, ControlMask, "\033[6;5~", 0, 0},
+ { XK_Next, ShiftMask, "\033[6;2~", 0, 0},
+- { XK_Next, XK_ANY_MOD, "\033[6~", 0, 0},
+ { XK_F1, XK_NO_MOD, "\033OP" , 0, 0},
+ { XK_F1, /* F13 */ ShiftMask, "\033[1;2P", 0, 0},
+ { XK_F1, /* F25 */ ControlMask, "\033[1;5P", 0, 0},
+@@ -439,6 +464,572 @@ static Key key[] = {
+ { XK_F33, XK_NO_MOD, "\033[20;5~", 0, 0},
+ { XK_F34, XK_NO_MOD, "\033[21;5~", 0, 0},
+ { XK_F35, XK_NO_MOD, "\033[23;5~", 0, 0},
++
++ // libtermkey compatible keyboard input
++ { XK_KP_Home, XK_NO_MOD, "\033[H", 0, -1},
++ { XK_KP_Home, XK_NO_MOD, "\033[1~", 0, +1},
++ { XK_KP_Home, ControlMask, "\033[149;5u", 0, 0},
++ { XK_KP_Home, ControlMask|ShiftMask, "\033[149;6u", 0, 0},
++ { XK_KP_Home, Mod1Mask, "\033[149;3u", 0, 0},
++ { XK_KP_Home, Mod1Mask|ControlMask, "\033[149;7u", 0, 0},
++ { XK_KP_Home, Mod1Mask|ControlMask|ShiftMask, "\033[149;8u", 0, 0},
++ { XK_KP_Home, Mod1Mask|ShiftMask, "\033[149;4u", 0, 0},
++ { XK_KP_Home, ShiftMask, "\033[149;2u", 0, 0},
++ { XK_KP_Up, XK_NO_MOD, "\033Ox", +1, 0},
++ { XK_KP_Up, XK_NO_MOD, "\033[A", 0, -1},
++ { XK_KP_Up, XK_NO_MOD, "\033OA", 0, +1},
++ { XK_KP_Up, ControlMask, "\033[151;5u", 0, 0},
++ { XK_KP_Up, ControlMask|ShiftMask, "\033[151;6u", 0, 0},
++ { XK_KP_Up, Mod1Mask, "\033[151;3u", 0, 0},
++ { XK_KP_Up, Mod1Mask|ControlMask, "\033[151;7u", 0, 0},
++ { XK_KP_Up, Mod1Mask|ControlMask|ShiftMask, "\033[151;8u", 0, 0},
++ { XK_KP_Up, Mod1Mask|ShiftMask, "\033[151;4u", 0, 0},
++ { XK_KP_Up, ShiftMask, "\033[151;2u", 0, 0},
++ { XK_KP_Down, XK_NO_MOD, "\033Or", +1, 0},
++ { XK_KP_Down, XK_NO_MOD, "\033[B", 0, -1},
++ { XK_KP_Down, XK_NO_MOD, "\033OB", 0, +1},
++ { XK_KP_Down, ControlMask, "\033[153;5u", 0, 0},
++ { XK_KP_Down, ControlMask|ShiftMask, "\033[153;6u", 0, 0},
++ { XK_KP_Down, Mod1Mask, "\033[153;3u", 0, 0},
++ { XK_KP_Down, Mod1Mask|ControlMask, "\033[153;7u", 0, 0},
++ { XK_KP_Down, Mod1Mask|ControlMask|ShiftMask, "\033[153;8u", 0, 0},
++ { XK_KP_Down, Mod1Mask|ShiftMask, "\033[153;4u", 0, 0},
++ { XK_KP_Down, ShiftMask, "\033[153;2u", 0, 0},
++ { XK_KP_Left, XK_NO_MOD, "\033Ot", +1, 0},
++ { XK_KP_Left, XK_NO_MOD, "\033[D", 0, -1},
++ { XK_KP_Left, XK_NO_MOD, "\033OD", 0, +1},
++ { XK_KP_Left, ControlMask, "\033[150;5u", 0, 0},
++ { XK_KP_Left, ControlMask|ShiftMask, "\033[150;6u", 0, 0},
++ { XK_KP_Left, Mod1Mask, "\033[150;3u", 0, 0},
++ { XK_KP_Left, Mod1Mask|ControlMask, "\033[150;7u", 0, 0},
++ { XK_KP_Left, Mod1Mask|ControlMask|ShiftMask, "\033[150;8u", 0, 0},
++ { XK_KP_Left, Mod1Mask|ShiftMask, "\033[150;4u", 0, 0},
++ { XK_KP_Left, ShiftMask, "\033[150;2u", 0, 0},
++ { XK_KP_Right, XK_NO_MOD, "\033Ov", +1, 0},
++ { XK_KP_Right, XK_NO_MOD, "\033[C", 0, -1},
++ { XK_KP_Right, XK_NO_MOD, "\033OC", 0, +1},
++ { XK_KP_Right, ControlMask, "\033[152;5u", 0, 0},
++ { XK_KP_Right, ControlMask|ShiftMask, "\033[152;6u", 0, 0},
++ { XK_KP_Right, Mod1Mask, "\033[152;3u", 0, 0},
++ { XK_KP_Right, Mod1Mask|ControlMask, "\033[152;7u", 0, 0},
++ { XK_KP_Right, Mod1Mask|ControlMask|ShiftMask, "\033[152;8u", 0, 0},
++ { XK_KP_Right, Mod1Mask|ShiftMask, "\033[152;4u", 0, 0},
++ { XK_KP_Right, ShiftMask, "\033[152;2u", 0, 0},
++ { XK_KP_Prior, XK_NO_MOD, "\033[5~", 0, 0},
++ { XK_KP_Prior, ControlMask, "\033[154;5u", 0, 0},
++ { XK_KP_Prior, ControlMask|ShiftMask, "\033[154;6u", 0, 0},
++ { XK_KP_Prior, Mod1Mask, "\033[154;3u", 0, 0},
++ { XK_KP_Prior, Mod1Mask|ControlMask, "\033[154;7u", 0, 0},
++ { XK_KP_Prior, Mod1Mask|ControlMask|ShiftMask, "\033[154;8u", 0, 0},
++ { XK_KP_Prior, Mod1Mask|ShiftMask, "\033[154;4u", 0, 0},
++ { XK_KP_Begin, XK_NO_MOD, "\033[E", 0, 0},
++ { XK_KP_Begin, ControlMask, "\033[157;5u", 0, 0},
++ { XK_KP_Begin, ControlMask|ShiftMask, "\033[157;6u", 0, 0},
++ { XK_KP_Begin, Mod1Mask, "\033[157;3u", 0, 0},
++ { XK_KP_Begin, Mod1Mask|ControlMask, "\033[157;7u", 0, 0},
++ { XK_KP_Begin, Mod1Mask|ControlMask|ShiftMask, "\033[157;8u", 0, 0},
++ { XK_KP_Begin, Mod1Mask|ShiftMask, "\033[157;4u", 0, 0},
++ { XK_KP_Begin, ShiftMask, "\033[157;2u", 0, 0},
++ { XK_KP_End, XK_NO_MOD, "\033[4~", 0, 0},
++ { XK_KP_End, ControlMask|ShiftMask, "\033[156;6u", 0, 0},
++ { XK_KP_End, Mod1Mask, "\033[156;3u", 0, 0},
++ { XK_KP_End, Mod1Mask|ControlMask, "\033[156;7u", 0, 0},
++ { XK_KP_End, Mod1Mask|ControlMask|ShiftMask, "\033[156;8u", 0, 0},
++ { XK_KP_End, Mod1Mask|ShiftMask, "\033[156;4u", 0, 0},
++ { XK_KP_Next, XK_NO_MOD, "\033[6~", 0, 0},
++ { XK_KP_Next, ControlMask, "\033[155;5u", 0, 0},
++ { XK_KP_Next, ControlMask|ShiftMask, "\033[155;6u", 0, 0},
++ { XK_KP_Next, Mod1Mask, "\033[155;3u", 0, 0},
++ { XK_KP_Next, Mod1Mask|ControlMask, "\033[155;7u", 0, 0},
++ { XK_KP_Next, Mod1Mask|ControlMask|ShiftMask, "\033[155;8u", 0, 0},
++ { XK_KP_Next, Mod1Mask|ShiftMask, "\033[155;4u", 0, 0},
++ { XK_KP_Insert, XK_NO_MOD, "\033[4h", -1, 0},
++ { XK_KP_Insert, XK_NO_MOD, "\033[2~", +1, 0},
++ { XK_KP_Insert, ControlMask|ShiftMask, "\033[158;6u", 0, 0},
++ { XK_KP_Insert, Mod1Mask, "\033[158;3u", 0, 0},
++ { XK_KP_Insert, Mod1Mask|ControlMask, "\033[158;7u", 0, 0},
++ { XK_KP_Insert, Mod1Mask|ControlMask|ShiftMask, "\033[158;8u", 0, 0},
++ { XK_KP_Insert, Mod1Mask|ShiftMask, "\033[158;4u", 0, 0},
++ { XK_KP_Delete, XK_NO_MOD, "\033[P", -1, 0},
++ { XK_KP_Delete, XK_NO_MOD, "\033[3~", +1, 0},
++ { XK_KP_Delete, ControlMask|ShiftMask, "\033[159;6u", 0, 0},
++ { XK_KP_Delete, Mod1Mask, "\033[159;3u", 0, 0},
++ { XK_KP_Delete, Mod1Mask|ControlMask, "\033[159;7u", 0, 0},
++ { XK_KP_Delete, Mod1Mask|ControlMask|ShiftMask, "\033[159;8u", 0, 0},
++ { XK_KP_Delete, Mod1Mask|ShiftMask, "\033[159;4u", 0, 0},
++ { XK_KP_Multiply, XK_NO_MOD, "\033Oj", +2, 0},
++ { XK_KP_Multiply, ControlMask, "\033[170;5u", 0, 0},
++ { XK_KP_Multiply, ControlMask|ShiftMask, "\033[170;6u", 0, 0},
++ { XK_KP_Multiply, Mod1Mask, "\033[170;3u", 0, 0},
++ { XK_KP_Multiply, Mod1Mask|ControlMask, "\033[170;7u", 0, 0},
++ { XK_KP_Multiply, Mod1Mask|ControlMask|ShiftMask, "\033[170;8u", 0, 0},
++ { XK_KP_Multiply, Mod1Mask|ShiftMask, "\033[170;4u", 0, 0},
++ { XK_KP_Multiply, ShiftMask, "\033[170;2u", 0, 0},
++ { XK_KP_Add, XK_NO_MOD, "\033Ok", +2, 0},
++ { XK_KP_Add, ControlMask, "\033[171;5u", 0, 0},
++ { XK_KP_Add, ControlMask|ShiftMask, "\033[171;6u", 0, 0},
++ { XK_KP_Add, Mod1Mask, "\033[171;3u", 0, 0},
++ { XK_KP_Add, Mod1Mask|ControlMask, "\033[171;7u", 0, 0},
++ { XK_KP_Add, Mod1Mask|ControlMask|ShiftMask, "\033[171;8u", 0, 0},
++ { XK_KP_Add, Mod1Mask|ShiftMask, "\033[171;4u", 0, 0},
++ { XK_KP_Add, ShiftMask, "\033[171;2u", 0, 0},
++ { XK_KP_Enter, XK_NO_MOD, "\033OM", +2, 0},
++ { XK_KP_Enter, XK_NO_MOD, "\r", -1, 0},
++ { XK_KP_Enter, XK_NO_MOD, "\r\n", -1, 0},
++ { XK_KP_Enter, ControlMask, "\033[141;5u", 0, 0},
++ { XK_KP_Enter, ControlMask|ShiftMask, "\033[141;6u", 0, 0},
++ { XK_KP_Enter, Mod1Mask, "\033[141;3u", 0, 0},
++ { XK_KP_Enter, Mod1Mask|ControlMask, "\033[141;7u", 0, 0},
++ { XK_KP_Enter, Mod1Mask|ControlMask|ShiftMask, "\033[141;8u", 0, 0},
++ { XK_KP_Enter, Mod1Mask|ShiftMask, "\033[141;4u", 0, 0},
++ { XK_KP_Enter, ShiftMask, "\033[141;2u", 0, 0},
++ { XK_KP_Subtract, XK_NO_MOD, "\033Om", +2, 0},
++ { XK_KP_Subtract, ControlMask, "\033[173;5u", 0, 0},
++ { XK_KP_Subtract, ControlMask|ShiftMask, "\033[173;6u", 0, 0},
++ { XK_KP_Subtract, Mod1Mask, "\033[173;3u", 0, 0},
++ { XK_KP_Subtract, Mod1Mask|ControlMask, "\033[173;7u", 0, 0},
++ { XK_KP_Subtract, Mod1Mask|ControlMask|ShiftMask, "\033[173;8u", 0, 0},
++ { XK_KP_Subtract, Mod1Mask|ShiftMask, "\033[173;4u", 0, 0},
++ { XK_KP_Subtract, ShiftMask, "\033[173;2u", 0, 0},
++ { XK_KP_Decimal, XK_NO_MOD, "\033On", +2, 0},
++ { XK_KP_Decimal, ControlMask, "\033[174;5u", 0, 0},
++ { XK_KP_Decimal, ControlMask|ShiftMask, "\033[174;6u", 0, 0},
++ { XK_KP_Decimal, Mod1Mask, "\033[174;3u", 0, 0},
++ { XK_KP_Decimal, Mod1Mask|ControlMask, "\033[174;7u", 0, 0},
++ { XK_KP_Decimal, Mod1Mask|ControlMask|ShiftMask, "\033[174;8u", 0, 0},
++ { XK_KP_Decimal, Mod1Mask|ShiftMask, "\033[174;4u", 0, 0},
++ { XK_KP_Decimal, ShiftMask, "\033[174;2u", 0, 0},
++ { XK_KP_Divide, XK_NO_MOD, "\033Oo", +2, 0},
++ { XK_KP_Divide, ControlMask, "\033[175;5u", 0, 0},
++ { XK_KP_Divide, ControlMask|ShiftMask, "\033[175;6u", 0, 0},
++ { XK_KP_Divide, Mod1Mask, "\033[175;3u", 0, 0},
++ { XK_KP_Divide, Mod1Mask|ControlMask, "\033[175;7u", 0, 0},
++ { XK_KP_Divide, Mod1Mask|ControlMask|ShiftMask, "\033[175;8u", 0, 0},
++ { XK_KP_Divide, Mod1Mask|ShiftMask, "\033[175;4u", 0, 0},
++ { XK_KP_Divide, ShiftMask, "\033[175;2u", 0, 0},
++ { XK_KP_0, XK_NO_MOD, "\033Op", +2, 0},
++ { XK_KP_0, ControlMask, "\033[176;5u", 0, 0},
++ { XK_KP_0, ControlMask|ShiftMask, "\033[176;6u", 0, 0},
++ { XK_KP_0, Mod1Mask, "\033[176;3u", 0, 0},
++ { XK_KP_0, Mod1Mask|ControlMask, "\033[176;7u", 0, 0},
++ { XK_KP_0, Mod1Mask|ControlMask|ShiftMask, "\033[176;8u", 0, 0},
++ { XK_KP_0, Mod1Mask|ShiftMask, "\033[176;4u", 0, 0},
++ { XK_KP_0, ShiftMask, "\033[176;2u", 0, 0},
++ { XK_KP_1, XK_NO_MOD, "\033Oq", +2, 0},
++ { XK_KP_0, ControlMask, "\033[177;5u", 0, 0},
++ { XK_KP_0, ControlMask|ShiftMask, "\033[177;6u", 0, 0},
++ { XK_KP_0, Mod1Mask, "\033[177;3u", 0, 0},
++ { XK_KP_0, Mod1Mask|ControlMask, "\033[177;7u", 0, 0},
++ { XK_KP_0, Mod1Mask|ControlMask|ShiftMask, "\033[177;8u", 0, 0},
++ { XK_KP_0, Mod1Mask|ShiftMask, "\033[177;4u", 0, 0},
++ { XK_KP_0, ShiftMask, "\033[177;2u", 0, 0},
++ { XK_KP_2, XK_NO_MOD, "\033Or", +2, 0},
++ { XK_KP_2, ControlMask, "\033[178;5u", 0, 0},
++ { XK_KP_2, ControlMask|ShiftMask, "\033[178;6u", 0, 0},
++ { XK_KP_2, Mod1Mask, "\033[178;3u", 0, 0},
++ { XK_KP_2, Mod1Mask|ControlMask, "\033[178;7u", 0, 0},
++ { XK_KP_2, Mod1Mask|ControlMask|ShiftMask, "\033[178;8u", 0, 0},
++ { XK_KP_2, Mod1Mask|ShiftMask, "\033[178;4u", 0, 0},
++ { XK_KP_2, ShiftMask, "\033[178;2u", 0, 0},
++ { XK_KP_3, XK_NO_MOD, "\033Os", +2, 0},
++ { XK_KP_3, ControlMask, "\033[179;5u", 0, 0},
++ { XK_KP_3, ControlMask|ShiftMask, "\033[179;6u", 0, 0},
++ { XK_KP_3, Mod1Mask, "\033[179;3u", 0, 0},
++ { XK_KP_3, Mod1Mask|ControlMask, "\033[179;7u", 0, 0},
++ { XK_KP_3, Mod1Mask|ControlMask|ShiftMask, "\033[179;8u", 0, 0},
++ { XK_KP_3, Mod1Mask|ShiftMask, "\033[179;4u", 0, 0},
++ { XK_KP_3, ShiftMask, "\033[179;2u", 0, 0},
++ { XK_KP_4, XK_NO_MOD, "\033Ot", +2, 0},
++ { XK_KP_4, ControlMask, "\033[180;5u", 0, 0},
++ { XK_KP_4, ControlMask|ShiftMask, "\033[180;6u", 0, 0},
++ { XK_KP_4, Mod1Mask, "\033[180;3u", 0, 0},
++ { XK_KP_4, Mod1Mask|ControlMask, "\033[180;7u", 0, 0},
++ { XK_KP_4, Mod1Mask|ControlMask|ShiftMask, "\033[180;8u", 0, 0},
++ { XK_KP_4, Mod1Mask|ShiftMask, "\033[180;4u", 0, 0},
++ { XK_KP_4, ShiftMask, "\033[180;2u", 0, 0},
++ { XK_KP_5, XK_NO_MOD, "\033Ou", +2, 0},
++ { XK_KP_5, ControlMask, "\033[181;5u", 0, 0},
++ { XK_KP_5, ControlMask|ShiftMask, "\033[181;6u", 0, 0},
++ { XK_KP_5, Mod1Mask, "\033[181;3u", 0, 0},
++ { XK_KP_5, Mod1Mask|ControlMask, "\033[181;7u", 0, 0},
++ { XK_KP_5, Mod1Mask|ControlMask|ShiftMask, "\033[181;8u", 0, 0},
++ { XK_KP_5, Mod1Mask|ShiftMask, "\033[181;4u", 0, 0},
++ { XK_KP_5, ShiftMask, "\033[181;2u", 0, 0},
++ { XK_KP_6, XK_NO_MOD, "\033Ov", +2, 0},
++ { XK_KP_6, ControlMask, "\033[182;5u", 0, 0},
++ { XK_KP_6, ControlMask|ShiftMask, "\033[182;6u", 0, 0},
++ { XK_KP_6, Mod1Mask, "\033[182;3u", 0, 0},
++ { XK_KP_6, Mod1Mask|ControlMask, "\033[182;7u", 0, 0},
++ { XK_KP_6, Mod1Mask|ControlMask|ShiftMask, "\033[182;8u", 0, 0},
++ { XK_KP_6, Mod1Mask|ShiftMask, "\033[182;4u", 0, 0},
++ { XK_KP_6, ShiftMask, "\033[182;2u", 0, 0},
++ { XK_KP_7, XK_NO_MOD, "\033Ow", +2, 0},
++ { XK_KP_7, ControlMask, "\033[183;5u", 0, 0},
++ { XK_KP_7, ControlMask|ShiftMask, "\033[183;6u", 0, 0},
++ { XK_KP_7, Mod1Mask, "\033[183;3u", 0, 0},
++ { XK_KP_7, Mod1Mask|ControlMask, "\033[183;7u", 0, 0},
++ { XK_KP_7, Mod1Mask|ControlMask|ShiftMask, "\033[183;8u", 0, 0},
++ { XK_KP_7, Mod1Mask|ShiftMask, "\033[183;4u", 0, 0},
++ { XK_KP_7, ShiftMask, "\033[183;2u", 0, 0},
++ { XK_KP_8, XK_NO_MOD, "\033Ox", +2, 0},
++ { XK_KP_8, ControlMask, "\033[184;5u", 0, 0},
++ { XK_KP_8, ControlMask|ShiftMask, "\033[184;6u", 0, 0},
++ { XK_KP_8, Mod1Mask, "\033[184;3u", 0, 0},
++ { XK_KP_8, Mod1Mask|ControlMask, "\033[184;7u", 0, 0},
++ { XK_KP_8, Mod1Mask|ControlMask|ShiftMask, "\033[184;8u", 0, 0},
++ { XK_KP_8, Mod1Mask|ShiftMask, "\033[184;4u", 0, 0},
++ { XK_KP_8, ShiftMask, "\033[184;2u", 0, 0},
++ { XK_KP_9, XK_NO_MOD, "\033Oy", +2, 0},
++ { XK_KP_9, ControlMask, "\033[185;5u", 0, 0},
++ { XK_KP_9, ControlMask|ShiftMask, "\033[185;6u", 0, 0},
++ { XK_KP_9, Mod1Mask, "\033[185;3u", 0, 0},
++ { XK_KP_9, Mod1Mask|ControlMask, "\033[185;7u", 0, 0},
++ { XK_KP_9, Mod1Mask|ControlMask|ShiftMask, "\033[185;8u", 0, 0},
++ { XK_KP_9, Mod1Mask|ShiftMask, "\033[185;4u", 0, 0},
++ { XK_KP_9, ShiftMask, "\033[185;2u", 0, 0},
++ { XK_BackSpace, ControlMask, "\033[127;5u", 0, 0},
++ { XK_BackSpace, ControlMask|ShiftMask, "\033[127;6u", 0, 0},
++ { XK_BackSpace, Mod1Mask, "\033[127;3u", 0, 0},
++ { XK_BackSpace, Mod1Mask|ControlMask, "\033[127;7u", 0, 0},
++ { XK_BackSpace, Mod1Mask|ControlMask|ShiftMask, "\033[127;8u", 0, 0},
++ { XK_BackSpace, Mod1Mask|ShiftMask, "\033[127;4u", 0, 0},
++ { XK_BackSpace, ShiftMask, "\033[127;2u", 0, 0},
++ { XK_Tab, ControlMask, "\033[9;5u", 0, 0},
++ { XK_Tab, ControlMask|ShiftMask, "\033[1;5Z", 0, 0},
++ { XK_Tab, Mod1Mask, "\033[1;3Z", 0, 0},
++ { XK_Tab, Mod1Mask|ControlMask, "\033[1;7Z", 0, 0},
++ { XK_Tab, Mod1Mask|ControlMask|ShiftMask, "\033[1;8Z", 0, 0},
++ { XK_Tab, Mod1Mask|ShiftMask, "\033[1;4Z", 0, 0},
++ { XK_Return, ControlMask, "\033[13;5u", 0, 0},
++ { XK_Return, ControlMask|ShiftMask, "\033[13;6u", 0, 0},
++ { XK_Return, Mod1Mask, "\033[13;3u", 0, 0},
++ { XK_Return, Mod1Mask|ControlMask, "\033[13;7u", 0, 0},
++ { XK_Return, Mod1Mask|ControlMask|ShiftMask, "\033[13;8u", 0, 0},
++ { XK_Return, Mod1Mask|ShiftMask, "\033[13;4u", 0, 0},
++ { XK_Return, ShiftMask, "\033[13;2u", 0, 0},
++ { XK_Pause, ControlMask, "\033[18;5u", 0, 0},
++ { XK_Pause, ControlMask|ShiftMask, "\033[18;6u", 0, 0},
++ { XK_Pause, Mod1Mask, "\033[18;3u", 0, 0},
++ { XK_Pause, Mod1Mask|ControlMask, "\033[18;7u", 0, 0},
++ { XK_Pause, Mod1Mask|ControlMask|ShiftMask, "\033[18;8u", 0, 0},
++ { XK_Pause, Mod1Mask|ShiftMask, "\033[18;4u", 0, 0},
++ { XK_Pause, ShiftMask, "\033[18;2u", 0, 0},
++ { XK_Scroll_Lock, ControlMask, "\033[20;5u", 0, 0},
++ { XK_Scroll_Lock, ControlMask|ShiftMask, "\033[20;6u", 0, 0},
++ { XK_Scroll_Lock, Mod1Mask, "\033[20;3u", 0, 0},
++ { XK_Scroll_Lock, Mod1Mask|ControlMask, "\033[20;7u", 0, 0},
++ { XK_Scroll_Lock, Mod1Mask|ControlMask|ShiftMask, "\033[20;8u", 0, 0},
++ { XK_Scroll_Lock, Mod1Mask|ShiftMask, "\033[20;4u", 0, 0},
++ { XK_Scroll_Lock, ShiftMask, "\033[20;2u", 0, 0},
++ { XK_Escape, ControlMask, "\033[27;5u", 0, 0},
++ { XK_Escape, ControlMask|ShiftMask, "\033[27;6u", 0, 0},
++ { XK_Escape, Mod1Mask, "\033[27;3u", 0, 0},
++ { XK_Escape, Mod1Mask|ControlMask, "\033[27;7u", 0, 0},
++ { XK_Escape, Mod1Mask|ControlMask|ShiftMask, "\033[27;8u", 0, 0},
++ { XK_Escape, Mod1Mask|ShiftMask, "\033[27;4u", 0, 0},
++ { XK_Escape, ShiftMask, "\033[27;2u", 0, 0},
++ { XK_Home, XK_NO_MOD, "\033[H", 0, -1},
++ { XK_Home, XK_NO_MOD, "\033[1~", 0, +1},
++ { XK_Home, ControlMask|ShiftMask, "\033[80;6u", 0, 0},
++ { XK_Home, Mod1Mask, "\033[80;3u", 0, 0},
++ { XK_Home, Mod1Mask|ControlMask, "\033[80;7u", 0, 0},
++ { XK_Home, Mod1Mask|ControlMask|ShiftMask, "\033[80;8u", 0, 0},
++ { XK_Home, Mod1Mask|ShiftMask, "\033[80;4u", 0, 0},
++ { XK_End, XK_NO_MOD, "\033[4~", 0, 0},
++ { XK_End, ControlMask|ShiftMask, "\033[87;6u", 0, 0},
++ { XK_End, Mod1Mask, "\033[87;3u", 0, 0},
++ { XK_End, Mod1Mask|ControlMask, "\033[87;7u", 0, 0},
++ { XK_End, Mod1Mask|ControlMask|ShiftMask, "\033[87;8u", 0, 0},
++ { XK_End, Mod1Mask|ShiftMask, "\033[87;4u", 0, 0},
++ { XK_Prior, XK_NO_MOD, "\033[5~", 0, 0},
++ { XK_Prior, ControlMask|ShiftMask, "\033[85;6u", 0, 0},
++ { XK_Prior, Mod1Mask, "\033[85;3u", 0, 0},
++ { XK_Prior, Mod1Mask|ControlMask, "\033[85;7u", 0, 0},
++ { XK_Prior, Mod1Mask|ControlMask|ShiftMask, "\033[85;8u", 0, 0},
++ { XK_Prior, Mod1Mask|ShiftMask, "\033[85;4u", 0, 0},
++ { XK_Next, XK_NO_MOD, "\033[6~", 0, 0},
++ { XK_Next, ControlMask|ShiftMask, "\033[86;6u", 0, 0},
++ { XK_Next, Mod1Mask, "\033[86;3u", 0, 0},
++ { XK_Next, Mod1Mask|ControlMask, "\033[86;7u", 0, 0},
++ { XK_Next, Mod1Mask|ControlMask|ShiftMask, "\033[86;8u", 0, 0},
++ { XK_Next, Mod1Mask|ShiftMask, "\033[86;4u", 0, 0},
++ { XK_Print, ControlMask, "\033[97;5u", 0, 0},
++ { XK_Print, ControlMask|ShiftMask, "\033[97;6u", 0, 0},
++ { XK_Print, Mod1Mask, "\033[97;3u", 0, 0},
++ { XK_Print, Mod1Mask|ControlMask, "\033[97;7u", 0, 0},
++ { XK_Print, Mod1Mask|ControlMask|ShiftMask, "\033[97;8u", 0, 0},
++ { XK_Print, Mod1Mask|ShiftMask, "\033[97;4u", 0, 0},
++ { XK_Print, ShiftMask, "\033[97;2u", 0, 0},
++ { XK_Insert, XK_NO_MOD, "\033[4h", -1, 0},
++ { XK_Insert, XK_NO_MOD, "\033[2~", +1, 0},
++ { XK_Insert, ControlMask|ShiftMask, "\033[99;6u", 0, 0},
++ { XK_Insert, Mod1Mask, "\033[99;3u", 0, 0},
++ { XK_Insert, Mod1Mask|ControlMask, "\033[99;7u", 0, 0},
++ { XK_Insert, Mod1Mask|ControlMask|ShiftMask, "\033[99;8u", 0, 0},
++ { XK_Insert, Mod1Mask|ShiftMask, "\033[99;4u", 0, 0},
++ { XK_Menu, ControlMask, "\033[103;5u", 0, 0},
++ { XK_Menu, ControlMask|ShiftMask, "\033[103;6u", 0, 0},
++ { XK_Menu, Mod1Mask, "\033[103;3u", 0, 0},
++ { XK_Menu, Mod1Mask|ControlMask, "\033[103;7u", 0, 0},
++ { XK_Menu, Mod1Mask|ControlMask|ShiftMask, "\033[103;8u", 0, 0},
++ { XK_Menu, Mod1Mask|ShiftMask, "\033[103;4u", 0, 0},
++ { XK_Menu, ShiftMask, "\033[103;2u", 0, 0},
++ { XK_Delete, XK_NO_MOD, "\033[P", -1, 0},
++ { XK_Delete, XK_NO_MOD, "\033[3~", +1, 0},
++ { XK_Delete, ControlMask|ShiftMask, "\033[255;6u", 0, 0},
++ { XK_Delete, Mod1Mask, "\033[255;3u", 0, 0},
++ { XK_Delete, Mod1Mask|ControlMask, "\033[255;7u", 0, 0},
++ { XK_Delete, Mod1Mask|ControlMask|ShiftMask, "\033[255;8u", 0, 0},
++ { XK_Delete, Mod1Mask|ShiftMask, "\033[255;4u", 0, 0},
++ { XK_i, ControlMask, "\033[105;5u", 0, 0},
++ { XK_i, Mod1Mask|ControlMask, "\033[105;7u", 0, 0},
++ { XK_m, ControlMask, "\033[109;5u", 0, 0},
++ { XK_m, Mod1Mask|ControlMask, "\033[109;7u", 0, 0},
++ { XK_space, ControlMask|ShiftMask, "\033[32;6u", 0, 0},
++ { XK_space, Mod1Mask, "\033[32;3u", 0, 0},
++ { XK_space, Mod1Mask|ControlMask, "\033[32;7u", 0, 0},
++ { XK_space, Mod1Mask|ControlMask|ShiftMask, "\033[32;8u", 0, 0},
++ { XK_space, Mod1Mask|ShiftMask, "\033[32;4u", 0, 0},
++ { XK_space, ShiftMask, "\033[32;2u", 0, 0},
++ { XK_0, ControlMask, "\033[48;5u", 0, 0},
++ { XK_A, ControlMask|ShiftMask, "\033[65;6u", 0, 0},
++ { XK_B, ControlMask|ShiftMask, "\033[66;6u", 0, 0},
++ { XK_C, ControlMask|ShiftMask, "\033[67;6u", 0, 0},
++ { XK_D, ControlMask|ShiftMask, "\033[68;6u", 0, 0},
++ { XK_E, ControlMask|ShiftMask, "\033[69;6u", 0, 0},
++ { XK_F, ControlMask|ShiftMask, "\033[70;6u", 0, 0},
++ { XK_G, ControlMask|ShiftMask, "\033[71;6u", 0, 0},
++ { XK_H, ControlMask|ShiftMask, "\033[72;6u", 0, 0},
++ { XK_I, ControlMask|ShiftMask, "\033[73;6u", 0, 0},
++ { XK_I, Mod1Mask|ControlMask|ShiftMask, "\033[73;8u", 0, 0},
++ { XK_J, ControlMask|ShiftMask, "\033[75;6u", 0, 0},
++ { XK_K, ControlMask|ShiftMask, "\033[74;6u", 0, 0},
++ { XK_L, ControlMask|ShiftMask, "\033[76;6u", 0, 0},
++ { XK_M, ControlMask|ShiftMask, "\033[77;6u", 0, 0},
++ { XK_M, Mod1Mask|ControlMask|ShiftMask, "\033[77;8u", 0, 0},
++ { XK_N, ControlMask|ShiftMask, "\033[78;6u", 0, 0},
++ { XK_O, ControlMask|ShiftMask, "\033[79;6u", 0, 0},
++ { XK_P, ControlMask|ShiftMask, "\033[80;6u", 0, 0},
++ { XK_Q, ControlMask|ShiftMask, "\033[81;6u", 0, 0},
++ { XK_R, ControlMask|ShiftMask, "\033[82;6u", 0, 0},
++ { XK_S, ControlMask|ShiftMask, "\033[83;6u", 0, 0},
++ { XK_T, ControlMask|ShiftMask, "\033[84;6u", 0, 0},
++ { XK_U, ControlMask|ShiftMask, "\033[85;6u", 0, 0},
++ { XK_V, ControlMask|ShiftMask, "\033[86;6u", 0, 0},
++ { XK_W, ControlMask|ShiftMask, "\033[87;6u", 0, 0},
++ { XK_X, ControlMask|ShiftMask, "\033[88;6u", 0, 0},
++ { XK_Y, ControlMask|ShiftMask, "\033[89;6u", 0, 0},
++ { XK_Z, ControlMask|ShiftMask, "\033[90;6u", 0, 0},
++ { XK_Z, ControlMask|ShiftMask, "\033[90;6u", 0, 0},
++ { XK_0, Mod1Mask|ControlMask, "\033[48;7u", 0, 0},
++ { XK_1, ControlMask, "\033[49;5u", 0, 0},
++ { XK_1, Mod1Mask|ControlMask, "\033[49;7u", 0, 0},
++ { XK_2, ControlMask, "\033[50;5u", 0, 0},
++ { XK_2, Mod1Mask|ControlMask, "\033[50;7u", 0, 0},
++ { XK_3, ControlMask, "\033[51;5u", 0, 0},
++ { XK_3, Mod1Mask|ControlMask, "\033[51;7u", 0, 0},
++ { XK_4, ControlMask, "\033[52;5u", 0, 0},
++ { XK_4, Mod1Mask|ControlMask, "\033[52;7u", 0, 0},
++ { XK_5, ControlMask, "\033[53;5u", 0, 0},
++ { XK_5, Mod1Mask|ControlMask, "\033[53;7u", 0, 0},
++ { XK_6, ControlMask, "\033[54;5u", 0, 0},
++ { XK_6, Mod1Mask|ControlMask, "\033[54;7u", 0, 0},
++ { XK_7, ControlMask, "\033[55;5u", 0, 0},
++ { XK_7, Mod1Mask|ControlMask, "\033[55;7u", 0, 0},
++ { XK_8, ControlMask, "\033[56;5u", 0, 0},
++ { XK_8, Mod1Mask|ControlMask, "\033[56;7u", 0, 0},
++ { XK_9, ControlMask, "\033[57;5u", 0, 0},
++ { XK_9, Mod1Mask|ControlMask, "\033[57;7u", 0, 0},
++ { XK_ampersand, ControlMask, "\033[38;5u", 0, 0},
++ { XK_ampersand, ControlMask|ShiftMask, "\033[38;6u", 0, 0},
++ { XK_ampersand, Mod1Mask, "\033[38;3u", 0, 0},
++ { XK_ampersand, Mod1Mask|ControlMask, "\033[38;7u", 0, 0},
++ { XK_ampersand, Mod1Mask|ControlMask|ShiftMask, "\033[38;8u", 0, 0},
++ { XK_ampersand, Mod1Mask|ShiftMask, "\033[38;4u", 0, 0},
++ { XK_apostrophe, ControlMask, "\033[39;5u", 0, 0},
++ { XK_apostrophe, ControlMask|ShiftMask, "\033[39;6u", 0, 0},
++ { XK_apostrophe, Mod1Mask, "\033[39;3u", 0, 0},
++ { XK_apostrophe, Mod1Mask|ControlMask, "\033[39;7u", 0, 0},
++ { XK_apostrophe, Mod1Mask|ControlMask|ShiftMask, "\033[39;8u", 0, 0},
++ { XK_apostrophe, Mod1Mask|ShiftMask, "\033[39;4u", 0, 0},
++ { XK_asciicircum, ControlMask, "\033[94;5u", 0, 0},
++ { XK_asciicircum, ControlMask|ShiftMask, "\033[94;6u", 0, 0},
++ { XK_asciicircum, Mod1Mask, "\033[94;3u", 0, 0},
++ { XK_asciicircum, Mod1Mask|ControlMask, "\033[94;7u", 0, 0},
++ { XK_asciicircum, Mod1Mask|ControlMask|ShiftMask, "\033[94;8u", 0, 0},
++ { XK_asciicircum, Mod1Mask|ShiftMask, "\033[94;4u", 0, 0},
++ { XK_asciitilde, ControlMask, "\033[126;5u", 0, 0},
++ { XK_asciitilde, ControlMask|ShiftMask, "\033[126;6u", 0, 0},
++ { XK_asciitilde, Mod1Mask, "\033[126;3u", 0, 0},
++ { XK_asciitilde, Mod1Mask|ControlMask, "\033[126;7u", 0, 0},
++ { XK_asciitilde, Mod1Mask|ControlMask|ShiftMask, "\033[126;8u", 0, 0},
++ { XK_asciitilde, Mod1Mask|ShiftMask, "\033[126;4u", 0, 0},
++ { XK_asterisk, ControlMask, "\033[42;5u", 0, 0},
++ { XK_asterisk, ControlMask|ShiftMask, "\033[42;6u", 0, 0},
++ { XK_asterisk, Mod1Mask, "\033[42;3u", 0, 0},
++ { XK_asterisk, Mod1Mask|ControlMask, "\033[42;7u", 0, 0},
++ { XK_asterisk, Mod1Mask|ControlMask|ShiftMask, "\033[42;8u", 0, 0},
++ { XK_asterisk, Mod1Mask|ShiftMask, "\033[42;4u", 0, 0},
++ { XK_at, ControlMask, "\033[64;5u", 0, 0},
++ { XK_at, ControlMask|ShiftMask, "\033[64;6u", 0, 0},
++ { XK_at, Mod1Mask, "\033[64;3u", 0, 0},
++ { XK_at, Mod1Mask|ControlMask, "\033[64;7u", 0, 0},
++ { XK_at, Mod1Mask|ControlMask|ShiftMask, "\033[64;8u", 0, 0},
++ { XK_at, Mod1Mask|ShiftMask, "\033[64;4u", 0, 0},
++ { XK_backslash, ControlMask, "\033[92;5u", 0, 0},
++ { XK_backslash, ControlMask|ShiftMask, "\033[92;6u", 0, 0},
++ { XK_backslash, Mod1Mask, "\033[92;3u", 0, 0},
++ { XK_backslash, Mod1Mask|ControlMask, "\033[92;7u", 0, 0},
++ { XK_backslash, Mod1Mask|ControlMask|ShiftMask, "\033[92;8u", 0, 0},
++ { XK_backslash, Mod1Mask|ShiftMask, "\033[92;4u", 0, 0},
++ { XK_bar, ControlMask, "\033[124;5u", 0, 0},
++ { XK_bar, ControlMask|ShiftMask, "\033[124;6u", 0, 0},
++ { XK_bar, Mod1Mask, "\033[124;3u", 0, 0},
++ { XK_bar, Mod1Mask|ControlMask, "\033[124;7u", 0, 0},
++ { XK_bar, Mod1Mask|ControlMask|ShiftMask, "\033[124;8u", 0, 0},
++ { XK_bar, Mod1Mask|ShiftMask, "\033[124;4u", 0, 0},
++ { XK_braceleft, ControlMask, "\033[123;5u", 0, 0},
++ { XK_braceleft, ControlMask|ShiftMask, "\033[123;6u", 0, 0},
++ { XK_braceleft, Mod1Mask, "\033[123;3u", 0, 0},
++ { XK_braceleft, Mod1Mask|ControlMask, "\033[123;7u", 0, 0},
++ { XK_braceleft, Mod1Mask|ControlMask|ShiftMask, "\033[123;8u", 0, 0},
++ { XK_braceleft, Mod1Mask|ShiftMask, "\033[123;4u", 0, 0},
++ { XK_braceright, ControlMask, "\033[125;5u", 0, 0},
++ { XK_braceright, ControlMask|ShiftMask, "\033[125;6u", 0, 0},
++ { XK_braceright, Mod1Mask, "\033[125;3u", 0, 0},
++ { XK_braceright, Mod1Mask|ControlMask, "\033[125;7u", 0, 0},
++ { XK_braceright, Mod1Mask|ControlMask|ShiftMask, "\033[125;8u", 0, 0},
++ { XK_braceright, Mod1Mask|ShiftMask, "\033[125;4u", 0, 0},
++ { XK_bracketleft, ControlMask, "\033[91;5u", 0, 0},
++ { XK_bracketleft, ControlMask|ShiftMask, "\033[91;6u", 0, 0},
++ { XK_bracketleft, Mod1Mask, "\033[91;3u", 0, 0},
++ { XK_bracketleft, Mod1Mask|ControlMask, "\033[91;7u", 0, 0},
++ { XK_bracketleft, Mod1Mask|ControlMask|ShiftMask, "\033[91;8u", 0, 0},
++ { XK_bracketleft, Mod1Mask|ShiftMask, "\033[91;4u", 0, 0},
++ { XK_bracketright, ControlMask, "\033[93;5u", 0, 0},
++ { XK_bracketright, ControlMask|ShiftMask, "\033[93;6u", 0, 0},
++ { XK_bracketright, Mod1Mask, "\033[93;3u", 0, 0},
++ { XK_bracketright, Mod1Mask|ControlMask, "\033[93;7u", 0, 0},
++ { XK_bracketright, Mod1Mask|ControlMask|ShiftMask, "\033[93;8u", 0, 0},
++ { XK_bracketright, Mod1Mask|ShiftMask, "\033[93;4u", 0, 0},
++ { XK_colon, ControlMask, "\033[58;5u", 0, 0},
++ { XK_colon, ControlMask|ShiftMask, "\033[58;6u", 0, 0},
++ { XK_colon, Mod1Mask, "\033[58;3u", 0, 0},
++ { XK_colon, Mod1Mask|ControlMask, "\033[58;7u", 0, 0},
++ { XK_colon, Mod1Mask|ControlMask|ShiftMask, "\033[58;8u", 0, 0},
++ { XK_colon, Mod1Mask|ShiftMask, "\033[58;4u", 0, 0},
++ { XK_comma, ControlMask, "\033[44;5u", 0, 0},
++ { XK_comma, ControlMask|ShiftMask, "\033[44;6u", 0, 0},
++ { XK_comma, Mod1Mask, "\033[44;3u", 0, 0},
++ { XK_comma, Mod1Mask|ControlMask, "\033[44;7u", 0, 0},
++ { XK_comma, Mod1Mask|ControlMask|ShiftMask, "\033[44;8u", 0, 0},
++ { XK_comma, Mod1Mask|ShiftMask, "\033[44;4u", 0, 0},
++ { XK_dollar, ControlMask, "\033[36;5u", 0, 0},
++ { XK_dollar, ControlMask|ShiftMask, "\033[36;6u", 0, 0},
++ { XK_dollar, Mod1Mask, "\033[36;3u", 0, 0},
++ { XK_dollar, Mod1Mask|ControlMask, "\033[36;7u", 0, 0},
++ { XK_dollar, Mod1Mask|ControlMask|ShiftMask, "\033[36;8u", 0, 0},
++ { XK_dollar, Mod1Mask|ShiftMask, "\033[36;4u", 0, 0},
++ { XK_equal, ControlMask, "\033[61;5u", 0, 0},
++ { XK_equal, ControlMask|ShiftMask, "\033[61;6u", 0, 0},
++ { XK_equal, Mod1Mask, "\033[61;3u", 0, 0},
++ { XK_equal, Mod1Mask|ControlMask, "\033[61;7u", 0, 0},
++ { XK_equal, Mod1Mask|ControlMask|ShiftMask, "\033[61;8u", 0, 0},
++ { XK_equal, Mod1Mask|ShiftMask, "\033[61;4u", 0, 0},
++ { XK_exclam, ControlMask, "\033[33;5u", 0, 0},
++ { XK_exclam, ControlMask|ShiftMask, "\033[33;6u", 0, 0},
++ { XK_exclam, Mod1Mask, "\033[33;3u", 0, 0},
++ { XK_exclam, Mod1Mask|ControlMask, "\033[33;7u", 0, 0},
++ { XK_exclam, Mod1Mask|ControlMask|ShiftMask, "\033[33;8u", 0, 0},
++ { XK_exclam, Mod1Mask|ShiftMask, "\033[33;4u", 0, 0},
++ { XK_grave, ControlMask, "\033[96;5u", 0, 0},
++ { XK_grave, ControlMask|ShiftMask, "\033[96;6u", 0, 0},
++ { XK_grave, Mod1Mask, "\033[96;3u", 0, 0},
++ { XK_grave, Mod1Mask|ControlMask, "\033[96;7u", 0, 0},
++ { XK_grave, Mod1Mask|ControlMask|ShiftMask, "\033[96;8u", 0, 0},
++ { XK_grave, Mod1Mask|ShiftMask, "\033[96;4u", 0, 0},
++ { XK_greater, ControlMask, "\033[62;5u", 0, 0},
++ { XK_greater, ControlMask|ShiftMask, "\033[62;6u", 0, 0},
++ { XK_greater, Mod1Mask, "\033[62;3u", 0, 0},
++ { XK_greater, Mod1Mask|ControlMask, "\033[62;7u", 0, 0},
++ { XK_greater, Mod1Mask|ControlMask|ShiftMask, "\033[62;8u", 0, 0},
++ { XK_greater, Mod1Mask|ShiftMask, "\033[62;4u", 0, 0},
++ { XK_less, ControlMask, "\033[60;5u", 0, 0},
++ { XK_less, ControlMask|ShiftMask, "\033[60;6u", 0, 0},
++ { XK_less, Mod1Mask, "\033[60;3u", 0, 0},
++ { XK_less, Mod1Mask|ControlMask, "\033[60;7u", 0, 0},
++ { XK_less, Mod1Mask|ControlMask|ShiftMask, "\033[60;8u", 0, 0},
++ { XK_less, Mod1Mask|ShiftMask, "\033[60;4u", 0, 0},
++ { XK_minus, ControlMask, "\033[45;5u", 0, 0},
++ { XK_minus, ControlMask|ShiftMask, "\033[45;6u", 0, 0},
++ { XK_minus, Mod1Mask, "\033[45;3u", 0, 0},
++ { XK_minus, Mod1Mask|ControlMask, "\033[45;7u", 0, 0},
++ { XK_minus, Mod1Mask|ControlMask|ShiftMask, "\033[45;8u", 0, 0},
++ { XK_minus, Mod1Mask|ShiftMask, "\033[45;4u", 0, 0},
++ { XK_numbersign, ControlMask, "\033[35;5u", 0, 0},
++ { XK_numbersign, ControlMask|ShiftMask, "\033[35;6u", 0, 0},
++ { XK_numbersign, Mod1Mask, "\033[35;3u", 0, 0},
++ { XK_numbersign, Mod1Mask|ControlMask, "\033[35;7u", 0, 0},
++ { XK_numbersign, Mod1Mask|ControlMask|ShiftMask, "\033[35;8u", 0, 0},
++ { XK_numbersign, Mod1Mask|ShiftMask, "\033[35;4u", 0, 0},
++ { XK_parenleft, ControlMask, "\033[40;5u", 0, 0},
++ { XK_parenleft, ControlMask|ShiftMask, "\033[40;6u", 0, 0},
++ { XK_parenleft, Mod1Mask, "\033[40;3u", 0, 0},
++ { XK_parenleft, Mod1Mask|ControlMask, "\033[40;7u", 0, 0},
++ { XK_parenleft, Mod1Mask|ControlMask|ShiftMask, "\033[40;8u", 0, 0},
++ { XK_parenleft, Mod1Mask|ShiftMask, "\033[40;4u", 0, 0},
++ { XK_parenright, ControlMask, "\033[41;5u", 0, 0},
++ { XK_parenright, ControlMask|ShiftMask, "\033[41;6u", 0, 0},
++ { XK_parenright, Mod1Mask, "\033[41;3u", 0, 0},
++ { XK_parenright, Mod1Mask|ControlMask, "\033[41;7u", 0, 0},
++ { XK_parenright, Mod1Mask|ControlMask|ShiftMask, "\033[41;8u", 0, 0},
++ { XK_parenright, Mod1Mask|ShiftMask, "\033[41;4u", 0, 0},
++ { XK_percent, ControlMask, "\033[37;5u", 0, 0},
++ { XK_percent, ControlMask|ShiftMask, "\033[37;6u", 0, 0},
++ { XK_percent, Mod1Mask, "\033[37;3u", 0, 0},
++ { XK_percent, Mod1Mask|ControlMask, "\033[37;7u", 0, 0},
++ { XK_percent, Mod1Mask|ControlMask|ShiftMask, "\033[37;8u", 0, 0},
++ { XK_percent, Mod1Mask|ShiftMask, "\033[37;4u", 0, 0},
++ { XK_period, ControlMask, "\033[46;5u", 0, 0},
++ { XK_period, ControlMask|ShiftMask, "\033[46;6u", 0, 0},
++ { XK_period, Mod1Mask|ControlMask, "\033[46;7u", 0, 0},
++ { XK_period, Mod1Mask|ControlMask|ShiftMask, "\033[46;8u", 0, 0},
++ { XK_period, Mod1Mask|ShiftMask, "\033[46;4u", 0, 0},
++ { XK_plus, ControlMask, "\033[43;5u", 0, 0},
++ { XK_plus, ControlMask|ShiftMask, "\033[43;6u", 0, 0},
++ { XK_plus, Mod1Mask, "\033[43;3u", 0, 0},
++ { XK_plus, Mod1Mask|ControlMask, "\033[43;7u", 0, 0},
++ { XK_plus, Mod1Mask|ControlMask|ShiftMask, "\033[43;8u", 0, 0},
++ { XK_plus, Mod1Mask|ShiftMask, "\033[43;4u", 0, 0},
++ { XK_question, ControlMask, "\033[63;5u", 0, 0},
++ { XK_question, ControlMask|ShiftMask, "\033[63;6u", 0, 0},
++ { XK_question, Mod1Mask, "\033[63;3u", 0, 0},
++ { XK_question, Mod1Mask|ControlMask, "\033[63;7u", 0, 0},
++ { XK_question, Mod1Mask|ControlMask|ShiftMask, "\033[63;8u", 0, 0},
++ { XK_question, Mod1Mask|ShiftMask, "\033[63;4u", 0, 0},
++ { XK_quotedbl, ControlMask, "\033[34;5u", 0, 0},
++ { XK_quotedbl, ControlMask|ShiftMask, "\033[34;6u", 0, 0},
++ { XK_quotedbl, Mod1Mask, "\033[34;3u", 0, 0},
++ { XK_quotedbl, Mod1Mask|ControlMask, "\033[34;7u", 0, 0},
++ { XK_quotedbl, Mod1Mask|ControlMask|ShiftMask, "\033[34;8u", 0, 0},
++ { XK_quotedbl, Mod1Mask|ShiftMask, "\033[34;4u", 0, 0},
++ { XK_semicolon, ControlMask, "\033[59;5u", 0, 0},
++ { XK_semicolon, ControlMask|ShiftMask, "\033[59;6u", 0, 0},
++ { XK_semicolon, Mod1Mask, "\033[59;3u", 0, 0},
++ { XK_semicolon, Mod1Mask|ControlMask, "\033[59;7u", 0, 0},
++ { XK_semicolon, Mod1Mask|ControlMask|ShiftMask, "\033[59;8u", 0, 0},
++ { XK_semicolon, Mod1Mask|ShiftMask, "\033[59;4u", 0, 0},
++ { XK_slash, ControlMask|ShiftMask, "\033[47;6u", 0, 0},
++ { XK_slash, Mod1Mask, "\033[47;3u", 0, 0},
++ { XK_slash, Mod1Mask|ControlMask, "\033[47;7u", 0, 0},
++ { XK_slash, Mod1Mask|ControlMask|ShiftMask, "\033[47;8u", 0, 0},
++ { XK_slash, Mod1Mask|ShiftMask, "\033[47;4u", 0, 0},
++ { XK_underscore, ControlMask, "\033[95;5u", 0, 0},
++ { XK_underscore, ControlMask|ShiftMask, "\033[95;6u", 0, 0},
++ { XK_underscore, Mod1Mask, "\033[95;3u", 0, 0},
++ { XK_underscore, Mod1Mask|ControlMask, "\033[95;7u", 0, 0},
++ { XK_underscore, Mod1Mask|ControlMask|ShiftMask, "\033[95;8u", 0, 0},
++ { XK_underscore, Mod1Mask|ShiftMask, "\033[95;4u", 0, 0},
+ };
+
+ /*
+--
+2.19.1
+
diff --git a/patches/x11-terms/st-0.8.1/0003-apply-st-gruvbox-both-0.8.1.diff.patch b/patches/x11-terms/st-0.8.1/0003-apply-st-gruvbox-both-0.8.1.diff.patch
@@ -0,0 +1,216 @@
+From e61affc3317385cdee0e749da20a2fbb22acb0f3 Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Tue, 23 Oct 2018 02:39:08 +0200
+Subject: [PATCH 3/3] apply st-gruvbox-both-0.8.1.diff
+
+---
+ config.def.h | 68 +++++++++++++++++++++++++++++++++-------------------
+ st.h | 1 +
+ x.c | 28 +++++++++++++++++-----
+ 3 files changed, 66 insertions(+), 31 deletions(-)
+
+diff --git a/config.def.h b/config.def.h
+index 1ea6902..e1587ba 100644
+--- a/config.def.h
++++ b/config.def.h
+@@ -84,31 +84,48 @@ unsigned int tabspaces = 8;
+
+ /* Terminal colors (16 first used in escape sequence) */
+ static const char *colorname[] = {
+- /* 8 normal colors */
+- "black",
+- "red3",
+- "green3",
+- "yellow3",
+- "blue2",
+- "magenta3",
+- "cyan3",
+- "gray90",
+-
+- /* 8 bright colors */
+- "gray50",
+- "red",
+- "green",
+- "yellow",
+- "#5c5cff",
+- "magenta",
+- "cyan",
+- "white",
++ /* gruvbox dark */
++ "#282828", /* hard contrast: #1d2021 / soft contrast: #32302f / normal: #282828 */
++ "#cc241d",
++ "#98971a",
++ "#d79921",
++ "#458588",
++ "#b16286",
++ "#689d6a",
++ "#a89984",
++ "#928374",
++ "#fb4934",
++ "#b8bb26",
++ "#fabd2f",
++ "#83a598",
++ "#d3869b",
++ "#8ec07c",
++ "#ebdbb2",
+
+ [255] = 0,
++};
+
+- /* more colors can be added after 255 to use with DefaultXX */
+- "#cccccc",
+- "#555555",
++/* Terminal colors for alternate (light) palette */
++static const char *altcolorname[] = {
++ /* gruvbox light */
++ "#fbf1c7", /* hard contrast: #f9f5d7 / soft contrast: #f2e5bc / normal: #fbf1c7 */
++ "#cc241d",
++ "#98971a",
++ "#d79921",
++ "#458588",
++ "#b16286",
++ "#689d6a",
++ "#7c6f64",
++ "#928374",
++ "#9d0006",
++ "#79740e",
++ "#b57614",
++ "#076678",
++ "#8f3f71",
++ "#427b58",
++ "#3c3836",
++
++ [255] = 0,
+ };
+
+
+@@ -116,10 +133,10 @@ static const char *colorname[] = {
+ * Default colors (colorname index)
+ * foreground, background, cursor, reverse cursor
+ */
+-unsigned int defaultfg = 7;
++unsigned int defaultfg = 15;
+ unsigned int defaultbg = 0;
+-static unsigned int defaultcs = 256;
+-static unsigned int defaultrcs = 257;
++static unsigned int defaultcs = 15;
++static unsigned int defaultrcs = 0;
+
+ /*
+ * Default shape of cursor
+@@ -178,6 +195,7 @@ static Shortcut shortcuts[] = {
+ { TERMMOD, XK_Y, selpaste, {.i = 0} },
+ { TERMMOD, XK_Num_Lock, numlock, {.i = 0} },
+ { TERMMOD, XK_I, iso14755, {.i = 0} },
++ { XK_ANY_MOD, XK_F6, swapcolors, {.i = 0} },
+ };
+
+ /*
+diff --git a/st.h b/st.h
+index dac64d8..7b0159d 100644
+--- a/st.h
++++ b/st.h
+@@ -118,6 +118,7 @@ extern char *vtiden;
+ extern char *worddelimiters;
+ extern int allowaltscreen;
+ extern char *termname;
++extern int usealtcolors;
+ extern unsigned int tabspaces;
+ extern unsigned int defaultfg;
+ extern unsigned int defaultbg;
+diff --git a/x.c b/x.c
+index c343ba2..47ef3e9 100644
+--- a/x.c
++++ b/x.c
+@@ -53,6 +53,7 @@ static void clipcopy(const Arg *);
+ static void clippaste(const Arg *);
+ static void numlock(const Arg *);
+ static void selpaste(const Arg *);
++static void swapcolors(const Arg *);
+ static void zoom(const Arg *);
+ static void zoomabs(const Arg *);
+ static void zoomreset(const Arg *);
+@@ -240,6 +241,8 @@ static char *opt_title = NULL;
+
+ static int oldbutton = 3; /* button event on startup: 3 = release */
+
++int usealtcolors = 0; /* 1 to use alternate palette */
++
+ void
+ clipcopy(const Arg *dummy)
+ {
+@@ -278,6 +281,14 @@ numlock(const Arg *dummy)
+ win.mode ^= MODE_NUMLOCK;
+ }
+
++void
++swapcolors(const Arg *dummy)
++{
++ usealtcolors = !usealtcolors;
++ xloadcols();
++ redraw();
++}
++
+ void
+ zoom(const Arg *arg)
+ {
+@@ -700,6 +711,11 @@ sixd_to_16bit(int x)
+ return x == 0 ? 0 : 0x3737 + 0x2828 * x;
+ }
+
++const char* getcolorname(int i)
++{
++ return (usealtcolors) ? altcolorname[i] : colorname[i];
++}
++
+ int
+ xloadcolor(int i, const char *name, Color *ncolor)
+ {
+@@ -718,7 +734,7 @@ xloadcolor(int i, const char *name, Color *ncolor)
+ return XftColorAllocValue(xw.dpy, xw.vis,
+ xw.cmap, &color, ncolor);
+ } else
+- name = colorname[i];
++ name = getcolorname(i);
+ }
+
+ return XftColorAllocName(xw.dpy, xw.vis, xw.cmap, name, ncolor);
+@@ -731,7 +747,7 @@ xloadcols(void)
+ static int loaded;
+ Color *cp;
+
+- dc.collen = MAX(LEN(colorname), 256);
++ dc.collen = MAX(LEN(colorname), LEN(altcolorname));
+ dc.col = xmalloc(dc.collen * sizeof(Color));
+
+ if (loaded) {
+@@ -741,8 +757,8 @@ xloadcols(void)
+
+ for (i = 0; i < dc.collen; i++)
+ if (!xloadcolor(i, NULL, &dc.col[i])) {
+- if (colorname[i])
+- die("Could not allocate color '%s'\n", colorname[i]);
++ if (getcolorname(i))
++ die("Could not allocate color '%s'\n", getcolorname(i));
+ else
+ die("Could not allocate color %d\n", i);
+ }
+@@ -1079,13 +1095,13 @@ xinit(int cols, int rows)
+ cursor = XCreateFontCursor(xw.dpy, mouseshape);
+ XDefineCursor(xw.dpy, xw.win, cursor);
+
+- if (XParseColor(xw.dpy, xw.cmap, colorname[mousefg], &xmousefg) == 0) {
++ if (XParseColor(xw.dpy, xw.cmap, getcolorname(mousefg), &xmousefg) == 0) {
+ xmousefg.red = 0xffff;
+ xmousefg.green = 0xffff;
+ xmousefg.blue = 0xffff;
+ }
+
+- if (XParseColor(xw.dpy, xw.cmap, colorname[mousebg], &xmousebg) == 0) {
++ if (XParseColor(xw.dpy, xw.cmap, getcolorname(mousebg), &xmousebg) == 0) {
+ xmousebg.red = 0x0000;
+ xmousebg.green = 0x0000;
+ xmousebg.blue = 0x0000;
+--
+2.19.1
+
diff --git a/patches/x11-terms/st-0.8.2/0001-better-Input-Method-Editor-IME-support.patch b/patches/x11-terms/st-0.8.2/0001-better-Input-Method-Editor-IME-support.patch
@@ -0,0 +1,152 @@
+From e85b6b64660214121164ea97fb098eaa4935f7db Mon Sep 17 00:00:00 2001
+From: Ivan Tham <pickfire@riseup.net>
+Date: Tue, 12 Feb 2019 18:41:41 +0100
+Subject: [PATCH 1/5] better Input Method Editor (IME) support
+
+Features:
+
+- Allow input methods swap with hotkey (E.g. left ctrl + left shift).
+- Over-the-spot pre-editing style, pre-edit data placed over insertion point.
+- Restart IME without segmentation fault.
+
+TODO:
+
+- Automatically pickup IME if st started before IME
+---
+ st.c | 1 +
+ win.h | 1 +
+ x.c | 69 ++++++++++++++++++++++++++++++++++++++++++++---------------
+ 3 files changed, 54 insertions(+), 17 deletions(-)
+
+diff --git a/st.c b/st.c
+index b8e6077..cf8687e 100644
+--- a/st.c
++++ b/st.c
+@@ -2594,6 +2594,7 @@ draw(void)
+ term.ocx, term.ocy, term.line[term.ocy][term.ocx]);
+ term.ocx = cx, term.ocy = term.c.y;
+ xfinishdraw();
++ xximspot(term.ocx, term.ocy);
+ }
+
+ void
+diff --git a/win.h b/win.h
+index 31f327d..a6ef1b9 100644
+--- a/win.h
++++ b/win.h
+@@ -36,3 +36,4 @@ void xsetmode(int, unsigned int);
+ void xsetpointermotion(int);
+ void xsetsel(char *);
+ int xstartdraw(void);
++void xximspot(int, int);
+diff --git a/x.c b/x.c
+index 0422421..865dacc 100644
+--- a/x.c
++++ b/x.c
+@@ -139,6 +139,9 @@ static void xdrawglyphfontspecs(const XftGlyphFontSpec *, Glyph, int, int, int);
+ static void xdrawglyph(Glyph, int, int);
+ static void xclear(int, int, int, int);
+ static int xgeommasktogravity(int);
++static void ximopen(Display *);
++static void ximinstantiate(Display *, XPointer, XPointer);
++static void ximdestroy(XIM, XPointer, XPointer);
+ static void xinit(int, int);
+ static void cresize(int, int);
+ static void xresize(int, int);
+@@ -996,6 +999,43 @@ xunloadfonts(void)
+ xunloadfont(&dc.ibfont);
+ }
+
++void
++ximopen(Display *dpy)
++{
++ XIMCallback destroy = { .client_data = NULL, .callback = ximdestroy };
++
++ if ((xw.xim = XOpenIM(xw.dpy, NULL, NULL, NULL)) == NULL) {
++ XSetLocaleModifiers("@im=local");
++ if ((xw.xim = XOpenIM(xw.dpy, NULL, NULL, NULL)) == NULL) {
++ XSetLocaleModifiers("@im=");
++ if ((xw.xim = XOpenIM(xw.dpy, NULL, NULL, NULL)) == NULL)
++ die("XOpenIM failed. Could not open input device.\n");
++ }
++ }
++ if (XSetIMValues(xw.xim, XNDestroyCallback, &destroy, NULL) != NULL)
++ die("XSetIMValues failed. Could not set input method value.\n");
++ xw.xic = XCreateIC(xw.xim, XNInputStyle, XIMPreeditNothing | XIMStatusNothing,
++ XNClientWindow, xw.win, XNFocusWindow, xw.win, NULL);
++ if (xw.xic == NULL)
++ die("XCreateIC failed. Could not obtain input method.\n");
++}
++
++void
++ximinstantiate(Display *dpy, XPointer client, XPointer call)
++{
++ ximopen(dpy);
++ XUnregisterIMInstantiateCallback(xw.dpy, NULL, NULL, NULL,
++ ximinstantiate, NULL);
++}
++
++void
++ximdestroy(XIM xim, XPointer client, XPointer call)
++{
++ xw.xim = NULL;
++ XRegisterIMInstantiateCallback(xw.dpy, NULL, NULL, NULL,
++ ximinstantiate, NULL);
++}
++
+ void
+ xinit(int cols, int rows)
+ {
+@@ -1033,7 +1073,7 @@ xinit(int cols, int rows)
+ xw.attrs.background_pixel = dc.col[defaultbg].pixel;
+ xw.attrs.border_pixel = dc.col[defaultbg].pixel;
+ xw.attrs.bit_gravity = NorthWestGravity;
+- xw.attrs.event_mask = FocusChangeMask | KeyPressMask
++ xw.attrs.event_mask = FocusChangeMask | KeyPressMask | KeyReleaseMask
+ | ExposureMask | VisibilityChangeMask | StructureNotifyMask
+ | ButtonMotionMask | ButtonPressMask | ButtonReleaseMask;
+ xw.attrs.colormap = xw.cmap;
+@@ -1061,22 +1101,7 @@ xinit(int cols, int rows)
+ xw.draw = XftDrawCreate(xw.dpy, xw.buf, xw.vis, xw.cmap);
+
+ /* input methods */
+- if ((xw.xim = XOpenIM(xw.dpy, NULL, NULL, NULL)) == NULL) {
+- XSetLocaleModifiers("@im=local");
+- if ((xw.xim = XOpenIM(xw.dpy, NULL, NULL, NULL)) == NULL) {
+- XSetLocaleModifiers("@im=");
+- if ((xw.xim = XOpenIM(xw.dpy,
+- NULL, NULL, NULL)) == NULL) {
+- die("XOpenIM failed. Could not open input"
+- " device.\n");
+- }
+- }
+- }
+- xw.xic = XCreateIC(xw.xim, XNInputStyle, XIMPreeditNothing
+- | XIMStatusNothing, XNClientWindow, xw.win,
+- XNFocusWindow, xw.win, NULL);
+- if (xw.xic == NULL)
+- die("XCreateIC failed. Could not obtain input method.\n");
++ ximopen(xw.dpy);
+
+ /* white cursor, black outline */
+ cursor = XCreateFontCursor(xw.dpy, mouseshape);
+@@ -1554,6 +1579,16 @@ xfinishdraw(void)
+ defaultfg : defaultbg].pixel);
+ }
+
++void
++xximspot(int x, int y)
++{
++ XPoint spot = { borderpx + x * win.cw, borderpx + (y + 1) * win.ch };
++ XVaNestedList attr = XVaCreateNestedList(0, XNSpotLocation, &spot, NULL);
++
++ XSetICValues(xw.xic, XNPreeditAttributes, attr, NULL);
++ XFree(attr);
++}
++
+ void
+ expose(XEvent *ev)
+ {
+--
+2.21.0
+
diff --git a/patches/x11-terms/st-0.8.2/0002-fix-use-after-free-in-font-caching-algorithm.patch b/patches/x11-terms/st-0.8.2/0002-fix-use-after-free-in-font-caching-algorithm.patch
@@ -0,0 +1,62 @@
+From a8cb8e94547d7e31441d2444e8a196415e3e4c1f Mon Sep 17 00:00:00 2001
+From: magras <dr.magras@gmail.com>
+Date: Thu, 28 Feb 2019 04:56:01 +0300
+Subject: [PATCH 2/5] fix use after free in font caching algorithm
+
+Current font caching algorithm contains a use after free error. A font
+removed from `frc` might be still listed in `wx.specbuf`. It will lead
+to a crash inside `XftDrawGlyphFontSpec()`.
+
+Steps to reproduce:
+$ st -f 'Misc Tamsyn:scalable=false'
+$ curl https://www.cl.cam.ac.uk/~mgk25/ucs/examples/UTF-8-demo.txt
+
+Of course, result depends on fonts installed on a system and fontconfig.
+In my case, I'm getting consistent segfaults with different fonts.
+
+I replaced a fixed array with a simple unbounded buffer with a constant
+growth rate. Cache starts with a capacity of 0, gets increments by 16,
+and never shrinks. On my machine after `cat UTF-8-demo.txt` buffer
+reaches a capacity of 192. During casual use capacity stays at 0.
+---
+ x.c | 15 +++++++++------
+ 1 file changed, 9 insertions(+), 6 deletions(-)
+
+diff --git a/x.c b/x.c
+index 865dacc..2cd76d0 100644
+--- a/x.c
++++ b/x.c
+@@ -226,8 +226,9 @@ typedef struct {
+ } Fontcache;
+
+ /* Fontcache is an array now. A new font will be appended to the array. */
+-static Fontcache frc[16];
++static Fontcache *frc = NULL;
+ static int frclen = 0;
++static int frccap = 0;
+ static char *usedfont = NULL;
+ static double usedfontsize = 0;
+ static double defaultfontsize = 0;
+@@ -1244,12 +1245,14 @@ xmakeglyphfontspecs(XftGlyphFontSpec *specs, const Glyph *glyphs, int len, int x
+ fcpattern, &fcres);
+
+ /*
+- * Overwrite or create the new cache entry.
++ * Allocate memory for the new cache entry.
+ */
+- if (frclen >= LEN(frc)) {
+- frclen = LEN(frc) - 1;
+- XftFontClose(xw.dpy, frc[frclen].font);
+- frc[frclen].unicodep = 0;
++ if (frclen >= frccap) {
++ frccap += 16;
++ if (!frc)
++ frc = xmalloc(frccap * sizeof(Fontcache));
++ else
++ frc = xrealloc(frc, frccap * sizeof(Fontcache));
+ }
+
+ frc[frclen].font = XftFontOpenPattern(xw.dpy,
+--
+2.21.0
+
diff --git a/patches/x11-terms/st-0.8.2/0003-apply-01b-my-config.diff.patch b/patches/x11-terms/st-0.8.2/0003-apply-01b-my-config.diff.patch
@@ -0,0 +1,34 @@
+From abeb13a8d0de88b7790d2f8343e83509eae404f8 Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Mon, 1 Oct 2018 01:08:20 +0200
+Subject: [PATCH 3/5] apply: 01b-my-config.diff
+
+---
+ config.def.h | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/config.def.h b/config.def.h
+index 0e01717..5c6944c 100644
+--- a/config.def.h
++++ b/config.def.h
+@@ -5,7 +5,7 @@
+ *
+ * font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html
+ */
+-static char *font = "Liberation Mono:pixelsize=12:antialias=true:autohint=true";
++static char *font = "monospace-7";
+ static int borderpx = 2;
+
+ /*
+@@ -32,7 +32,7 @@ static float chscale = 1.0;
+ *
+ * More advanced example: " `'\"()[]{}"
+ */
+-char *worddelimiters = " ";
++char *worddelimiters = " │`'\"()[]{}“”<>‘’\~\;";
+
+ /* selection timeouts (in milliseconds) */
+ static unsigned int doubleclicktimeout = 300;
+--
+2.21.0
+
diff --git a/patches/x11-terms/st-0.8.2/0004-Fix-keyboard-input-on-terminal.patch b/patches/x11-terms/st-0.8.2/0004-Fix-keyboard-input-on-terminal.patch
@@ -0,0 +1,770 @@
+From 9b5498f1f279bf8c509939aa1bd460e5e325e41d Mon Sep 17 00:00:00 2001
+From: Jan Christoph Ebersbach <jceb@e-jc.de>
+Date: Mon, 1 Oct 2018 01:38:52 +0200
+Subject: [PATCH 4/5] Fix keyboard input on terminal
+
+URL: http://st.suckless.org/patches/fix_keyboard_input
+---
+ config.def.h | 691 +++++++++++++++++++++++++++++++++++++++++++++++----
+ 1 file changed, 641 insertions(+), 50 deletions(-)
+
+diff --git a/config.def.h b/config.def.h
+index 5c6944c..78ebbc5 100644
+--- a/config.def.h
++++ b/config.def.h
+@@ -209,7 +209,80 @@ static Shortcut shortcuts[] = {
+ * If you want keys other than the X11 function keys (0xFD00 - 0xFFFF)
+ * to be mapped below, add them to this array.
+ */
+-static KeySym mappedkeys[] = { -1 };
++static KeySym mappedkeys[] = {
++ XK_space,
++ XK_m,
++ XK_i,
++ XK_A,
++ XK_B,
++ XK_C,
++ XK_D,
++ XK_E,
++ XK_F,
++ XK_G,
++ XK_H,
++ XK_I,
++ XK_K,
++ XK_J,
++ XK_L,
++ XK_M,
++ XK_N,
++ XK_O,
++ XK_P,
++ XK_Q,
++ XK_R,
++ XK_S,
++ XK_T,
++ XK_U,
++ XK_V,
++ XK_W,
++ XK_X,
++ XK_Y,
++ XK_Z,
++ XK_Z,
++ XK_0,
++ XK_1,
++ XK_2,
++ XK_3,
++ XK_4,
++ XK_5,
++ XK_6,
++ XK_7,
++ XK_8,
++ XK_9,
++ XK_exclam,
++ XK_quotedbl,
++ XK_numbersign,
++ XK_dollar,
++ XK_percent,
++ XK_ampersand,
++ XK_apostrophe,
++ XK_parenleft,
++ XK_parenright,
++ XK_asterisk,
++ XK_plus,
++ XK_comma,
++ XK_minus,
++ XK_period,
++ XK_slash,
++ XK_colon,
++ XK_semicolon,
++ XK_less,
++ XK_equal,
++ XK_greater,
++ XK_question,
++ XK_at,
++ XK_bracketleft,
++ XK_backslash,
++ XK_bracketright,
++ XK_asciicircum,
++ XK_underscore,
++ XK_grave,
++ XK_braceleft,
++ XK_bar,
++ XK_braceright,
++ XK_asciitilde,
++};
+
+ /*
+ * State bits to ignore when matching key or button events. By default,
+@@ -232,59 +305,20 @@ static Key key[] = {
+ /* keysym mask string appkey appcursor */
+ { XK_KP_Home, ShiftMask, "\033[2J", 0, -1},
+ { XK_KP_Home, ShiftMask, "\033[1;2H", 0, +1},
+- { XK_KP_Home, XK_ANY_MOD, "\033[H", 0, -1},
+- { XK_KP_Home, XK_ANY_MOD, "\033[1~", 0, +1},
+- { XK_KP_Up, XK_ANY_MOD, "\033Ox", +1, 0},
+- { XK_KP_Up, XK_ANY_MOD, "\033[A", 0, -1},
+- { XK_KP_Up, XK_ANY_MOD, "\033OA", 0, +1},
+- { XK_KP_Down, XK_ANY_MOD, "\033Or", +1, 0},
+- { XK_KP_Down, XK_ANY_MOD, "\033[B", 0, -1},
+- { XK_KP_Down, XK_ANY_MOD, "\033OB", 0, +1},
+- { XK_KP_Left, XK_ANY_MOD, "\033Ot", +1, 0},
+- { XK_KP_Left, XK_ANY_MOD, "\033[D", 0, -1},
+- { XK_KP_Left, XK_ANY_MOD, "\033OD", 0, +1},
+- { XK_KP_Right, XK_ANY_MOD, "\033Ov", +1, 0},
+- { XK_KP_Right, XK_ANY_MOD, "\033[C", 0, -1},
+- { XK_KP_Right, XK_ANY_MOD, "\033OC", 0, +1},
+ { XK_KP_Prior, ShiftMask, "\033[5;2~", 0, 0},
+- { XK_KP_Prior, XK_ANY_MOD, "\033[5~", 0, 0},
+- { XK_KP_Begin, XK_ANY_MOD, "\033[E", 0, 0},
+ { XK_KP_End, ControlMask, "\033[J", -1, 0},
+ { XK_KP_End, ControlMask, "\033[1;5F", +1, 0},
+ { XK_KP_End, ShiftMask, "\033[K", -1, 0},
+ { XK_KP_End, ShiftMask, "\033[1;2F", +1, 0},
+- { XK_KP_End, XK_ANY_MOD, "\033[4~", 0, 0},
+ { XK_KP_Next, ShiftMask, "\033[6;2~", 0, 0},
+- { XK_KP_Next, XK_ANY_MOD, "\033[6~", 0, 0},
+ { XK_KP_Insert, ShiftMask, "\033[2;2~", +1, 0},
+ { XK_KP_Insert, ShiftMask, "\033[4l", -1, 0},
+ { XK_KP_Insert, ControlMask, "\033[L", -1, 0},
+ { XK_KP_Insert, ControlMask, "\033[2;5~", +1, 0},
+- { XK_KP_Insert, XK_ANY_MOD, "\033[4h", -1, 0},
+- { XK_KP_Insert, XK_ANY_MOD, "\033[2~", +1, 0},
+ { XK_KP_Delete, ControlMask, "\033[M", -1, 0},
+ { XK_KP_Delete, ControlMask, "\033[3;5~", +1, 0},
+ { XK_KP_Delete, ShiftMask, "\033[2K", -1, 0},
+ { XK_KP_Delete, ShiftMask, "\033[3;2~", +1, 0},
+- { XK_KP_Delete, XK_ANY_MOD, "\033[P", -1, 0},
+- { XK_KP_Delete, XK_ANY_MOD, "\033[3~", +1, 0},
+- { XK_KP_Multiply, XK_ANY_MOD, "\033Oj", +2, 0},
+- { XK_KP_Add, XK_ANY_MOD, "\033Ok", +2, 0},
+- { XK_KP_Enter, XK_ANY_MOD, "\033OM", +2, 0},
+- { XK_KP_Enter, XK_ANY_MOD, "\r", -1, 0},
+- { XK_KP_Subtract, XK_ANY_MOD, "\033Om", +2, 0},
+- { XK_KP_Decimal, XK_ANY_MOD, "\033On", +2, 0},
+- { XK_KP_Divide, XK_ANY_MOD, "\033Oo", +2, 0},
+- { XK_KP_0, XK_ANY_MOD, "\033Op", +2, 0},
+- { XK_KP_1, XK_ANY_MOD, "\033Oq", +2, 0},
+- { XK_KP_2, XK_ANY_MOD, "\033Or", +2, 0},
+- { XK_KP_3, XK_ANY_MOD, "\033Os", +2, 0},
+- { XK_KP_4, XK_ANY_MOD, "\033Ot", +2, 0},
+- { XK_KP_5, XK_ANY_MOD, "\033Ou", +2, 0},
+- { XK_KP_6, XK_ANY_MOD, "\033Ov", +2, 0},
+- { XK_KP_7, XK_ANY_MOD, "\033Ow", +2, 0},
+- { XK_KP_8, XK_ANY_MOD, "\033Ox", +2, 0},
+- { XK_KP_9, XK_ANY_MOD, "\033Oy", +2, 0},
+ { XK_Up, ShiftMask, "\033[1;2A", 0, 0},
+ { XK_Up, Mod1Mask, "\033[1;3A", 0, 0},
+ { XK_Up, ShiftMask|Mod1Mask,"\033[1;4A", 0, 0},
+@@ -323,36 +357,27 @@ static Key key[] = {
+ { XK_Right, XK_ANY_MOD, "\033OC", 0, +1},
+ { XK_ISO_Left_Tab, ShiftMask, "\033[Z", 0, 0},
+ { XK_Return, Mod1Mask, "\033\r", 0, 0},
+- { XK_Return, XK_ANY_MOD, "\r", 0, 0},
++ { XK_Return, XK_NO_MOD, "\r", 0, 0},
+ { XK_Insert, ShiftMask, "\033[4l", -1, 0},
+ { XK_Insert, ShiftMask, "\033[2;2~", +1, 0},
+ { XK_Insert, ControlMask, "\033[L", -1, 0},
+ { XK_Insert, ControlMask, "\033[2;5~", +1, 0},
+- { XK_Insert, XK_ANY_MOD, "\033[4h", -1, 0},
+- { XK_Insert, XK_ANY_MOD, "\033[2~", +1, 0},
+ { XK_Delete, ControlMask, "\033[M", -1, 0},
+ { XK_Delete, ControlMask, "\033[3;5~", +1, 0},
+ { XK_Delete, ShiftMask, "\033[2K", -1, 0},
+ { XK_Delete, ShiftMask, "\033[3;2~", +1, 0},
+- { XK_Delete, XK_ANY_MOD, "\033[P", -1, 0},
+- { XK_Delete, XK_ANY_MOD, "\033[3~", +1, 0},
+ { XK_BackSpace, XK_NO_MOD, "\177", 0, 0},
+ { XK_BackSpace, Mod1Mask, "\033\177", 0, 0},
+ { XK_Home, ShiftMask, "\033[2J", 0, -1},
+ { XK_Home, ShiftMask, "\033[1;2H", 0, +1},
+- { XK_Home, XK_ANY_MOD, "\033[H", 0, -1},
+- { XK_Home, XK_ANY_MOD, "\033[1~", 0, +1},
+ { XK_End, ControlMask, "\033[J", -1, 0},
+ { XK_End, ControlMask, "\033[1;5F", +1, 0},
+ { XK_End, ShiftMask, "\033[K", -1, 0},
+ { XK_End, ShiftMask, "\033[1;2F", +1, 0},
+- { XK_End, XK_ANY_MOD, "\033[4~", 0, 0},
+ { XK_Prior, ControlMask, "\033[5;5~", 0, 0},
+ { XK_Prior, ShiftMask, "\033[5;2~", 0, 0},
+- { XK_Prior, XK_ANY_MOD, "\033[5~", 0, 0},
+ { XK_Next, ControlMask, "\033[6;5~", 0, 0},
+ { XK_Next, ShiftMask, "\033[6;2~", 0, 0},
+- { XK_Next, XK_ANY_MOD, "\033[6~", 0, 0},
+ { XK_F1, XK_NO_MOD, "\033OP" , 0, 0},
+ { XK_F1, /* F13 */ ShiftMask, "\033[1;2P", 0, 0},
+ { XK_F1, /* F25 */ ControlMask, "\033[1;5P", 0, 0},
+@@ -439,6 +464,572 @@ static Key key[] = {
+ { XK_F33, XK_NO_MOD, "\033[20;5~", 0, 0},
+ { XK_F34, XK_NO_MOD, "\033[21;5~", 0, 0},
+ { XK_F35, XK_NO_MOD, "\033[23;5~", 0, 0},
++
++ // libtermkey compatible keyboard input
++ { XK_KP_Home, XK_NO_MOD, "\033[H", 0, -1},
++ { XK_KP_Home, XK_NO_MOD, "\033[1~", 0, +1},
++ { XK_KP_Home, ControlMask, "\033[149;5u", 0, 0},
++ { XK_KP_Home, ControlMask|ShiftMask, "\033[149;6u", 0, 0},
++ { XK_KP_Home, Mod1Mask, "\033[149;3u", 0, 0},
++ { XK_KP_Home, Mod1Mask|ControlMask, "\033[149;7u", 0, 0},
++ { XK_KP_Home, Mod1Mask|ControlMask|ShiftMask, "\033[149;8u", 0, 0},
++ { XK_KP_Home, Mod1Mask|ShiftMask, "\033[149;4u", 0, 0},
++ { XK_KP_Home, ShiftMask, "\033[149;2u", 0, 0},
++ { XK_KP_Up, XK_NO_MOD, "\033Ox", +1, 0},
++ { XK_KP_Up, XK_NO_MOD, "\033[A", 0, -1},
++ { XK_KP_Up, XK_NO_MOD, "\033OA", 0, +1},
++ { XK_KP_Up, ControlMask, "\033[151;5u", 0, 0},
++ { XK_KP_Up, ControlMask|ShiftMask, "\033[151;6u", 0, 0},
++ { XK_KP_Up, Mod1Mask, "\033[151;3u", 0, 0},
++ { XK_KP_Up, Mod1Mask|ControlMask, "\033[151;7u", 0, 0},
++ { XK_KP_Up, Mod1Mask|ControlMask|ShiftMask, "\033[151;8u", 0, 0},
++ { XK_KP_Up, Mod1Mask|ShiftMask, "\033[151;4u", 0, 0},
++ { XK_KP_Up, ShiftMask, "\033[151;2u", 0, 0},
++ { XK_KP_Down, XK_NO_MOD, "\033Or", +1, 0},
++ { XK_KP_Down, XK_NO_MOD, "\033[B", 0, -1},
++ { XK_KP_Down, XK_NO_MOD, "\033OB", 0, +1},
++ { XK_KP_Down, ControlMask, "\033[153;5u", 0, 0},
++ { XK_KP_Down, ControlMask|ShiftMask, "\033[153;6u", 0, 0},
++ { XK_KP_Down, Mod1Mask, "\033[153;3u", 0, 0},
++ { XK_KP_Down, Mod1Mask|ControlMask, "\033[153;7u", 0, 0},
++ { XK_KP_Down, Mod1Mask|ControlMask|ShiftMask, "\033[153;8u", 0, 0},
++ { XK_KP_Down, Mod1Mask|ShiftMask, "\033[153;4u", 0, 0},
++ { XK_KP_Down, ShiftMask, "\033[153;2u", 0, 0},
++ { XK_KP_Left, XK_NO_MOD, "\033Ot", +1, 0},
++ { XK_KP_Left, XK_NO_MOD, "\033[D", 0, -1},
++ { XK_KP_Left, XK_NO_MOD, "\033OD", 0, +1},
++ { XK_KP_Left, ControlMask, "\033[150;5u", 0, 0},
++ { XK_KP_Left, ControlMask|ShiftMask, "\033[150;6u", 0, 0},
++ { XK_KP_Left, Mod1Mask, "\033[150;3u", 0, 0},
++ { XK_KP_Left, Mod1Mask|ControlMask, "\033[150;7u", 0, 0},
++ { XK_KP_Left, Mod1Mask|ControlMask|ShiftMask, "\033[150;8u", 0, 0},
++ { XK_KP_Left, Mod1Mask|ShiftMask, "\033[150;4u", 0, 0},
++ { XK_KP_Left, ShiftMask, "\033[150;2u", 0, 0},
++ { XK_KP_Right, XK_NO_MOD, "\033Ov", +1, 0},
++ { XK_KP_Right, XK_NO_MOD, "\033[C", 0, -1},
++ { XK_KP_Right, XK_NO_MOD, "\033OC", 0, +1},
++ { XK_KP_Right, ControlMask, "\033[152;5u", 0, 0},
++ { XK_KP_Right, ControlMask|ShiftMask, "\033[152;6u", 0, 0},
++ { XK_KP_Right, Mod1Mask, "\033[152;3u", 0, 0},
++ { XK_KP_Right, Mod1Mask|ControlMask, "\033[152;7u", 0, 0},
++ { XK_KP_Right, Mod1Mask|ControlMask|ShiftMask, "\033[152;8u", 0, 0},
++ { XK_KP_Right, Mod1Mask|ShiftMask, "\033[152;4u", 0, 0},
++ { XK_KP_Right, ShiftMask, "\033[152;2u", 0, 0},
++ { XK_KP_Prior, XK_NO_MOD, "\033[5~", 0, 0},
++ { XK_KP_Prior, ControlMask, "\033[154;5u", 0, 0},
++ { XK_KP_Prior, ControlMask|ShiftMask, "\033[154;6u", 0, 0},
++ { XK_KP_Prior, Mod1Mask, "\033[154;3u", 0, 0},
++ { XK_KP_Prior, Mod1Mask|ControlMask, "\033[154;7u", 0, 0},
++ { XK_KP_Prior, Mod1Mask|ControlMask|ShiftMask, "\033[154;8u", 0, 0},
++ { XK_KP_Prior, Mod1Mask|ShiftMask, "\033[154;4u", 0, 0},
++ { XK_KP_Begin, XK_NO_MOD, "\033[E", 0, 0},
++ { XK_KP_Begin, ControlMask, "\033[157;5u", 0, 0},
++ { XK_KP_Begin, ControlMask|ShiftMask, "\033[157;6u", 0, 0},
++ { XK_KP_Begin, Mod1Mask, "\033[157;3u", 0, 0},
++ { XK_KP_Begin, Mod1Mask|ControlMask, "\033[157;7u", 0, 0},
++ { XK_KP_Begin, Mod1Mask|ControlMask|ShiftMask, "\033[157;8u", 0, 0},
++ { XK_KP_Begin, Mod1Mask|ShiftMask, "\033[157;4u", 0, 0},
++ { XK_KP_Begin, ShiftMask, "\033[157;2u", 0, 0},
++ { XK_KP_End, XK_NO_MOD, "\033[4~", 0, 0},
++ { XK_KP_End, ControlMask|ShiftMask, "\033[156;6u", 0, 0},
++ { XK_KP_End, Mod1Mask, "\033[156;3u", 0, 0},
++ { XK_KP_End, Mod1Mask|ControlMask, "\033[156;7u", 0, 0},
++ { XK_KP_End, Mod1Mask|ControlMask|ShiftMask, "\033[156;8u", 0, 0},
++ { XK_KP_End, Mod1Mask|ShiftMask, "\033[156;4u", 0, 0},
++ { XK_KP_Next, XK_NO_MOD, "\033[6~", 0, 0},
++ { XK_KP_Next, ControlMask, "\033[155;5u", 0, 0},
++ { XK_KP_Next, ControlMask|ShiftMask, "\033[155;6u", 0, 0},
++ { XK_KP_Next, Mod1Mask, "\033[155;3u", 0, 0},
++ { XK_KP_Next, Mod1Mask|ControlMask, "\033[155;7u", 0, 0},
++ { XK_KP_Next, Mod1Mask|ControlMask|ShiftMask, "\033[155;8u", 0, 0},
++ { XK_KP_Next, Mod1Mask|ShiftMask, "\033[155;4u", 0, 0},
++ { XK_KP_Insert, XK_NO_MOD, "\033[4h", -1, 0},
++ { XK_KP_Insert, XK_NO_MOD, "\033[2~", +1, 0},
++ { XK_KP_Insert, ControlMask|ShiftMask, "\033[158;6u", 0, 0},
++ { XK_KP_Insert, Mod1Mask, "\033[158;3u", 0, 0},
++ { XK_KP_Insert, Mod1Mask|ControlMask, "\033[158;7u", 0, 0},
++ { XK_KP_Insert, Mod1Mask|ControlMask|ShiftMask, "\033[158;8u", 0, 0},
++ { XK_KP_Insert, Mod1Mask|ShiftMask, "\033[158;4u", 0, 0},
++ { XK_KP_Delete, XK_NO_MOD, "\033[P", -1, 0},
++ { XK_KP_Delete, XK_NO_MOD, "\033[3~", +1, 0},
++ { XK_KP_Delete, ControlMask|ShiftMask, "\033[159;6u", 0, 0},
++ { XK_KP_Delete, Mod1Mask, "\033[159;3u", 0, 0},
++ { XK_KP_Delete, Mod1Mask|ControlMask, "\033[159;7u", 0, 0},
++ { XK_KP_Delete, Mod1Mask|ControlMask|ShiftMask, "\033[159;8u", 0, 0},
++ { XK_KP_Delete, Mod1Mask|ShiftMask, "\033[159;4u", 0, 0},
++ { XK_KP_Multiply, XK_NO_MOD, "\033Oj", +2, 0},
++ { XK_KP_Multiply, ControlMask, "\033[170;5u", 0, 0},
++ { XK_KP_Multiply, ControlMask|ShiftMask, "\033[170;6u", 0, 0},
++ { XK_KP_Multiply, Mod1Mask, "\033[170;3u", 0, 0},
++ { XK_KP_Multiply, Mod1Mask|ControlMask, "\033[170;7u", 0, 0},
++ { XK_KP_Multiply, Mod1Mask|ControlMask|ShiftMask, "\033[170;8u", 0, 0},
++ { XK_KP_Multiply, Mod1Mask|ShiftMask, "\033[170;4u", 0, 0},
++ { XK_KP_Multiply, ShiftMask, "\033[170;2u", 0, 0},
++ { XK_KP_Add, XK_NO_MOD, "\033Ok", +2, 0},
++ { XK_KP_Add, ControlMask, "\033[171;5u", 0, 0},
++ { XK_KP_Add, ControlMask|ShiftMask, "\033[171;6u", 0, 0},
++ { XK_KP_Add, Mod1Mask, "\033[171;3u", 0, 0},
++ { XK_KP_Add, Mod1Mask|ControlMask, "\033[171;7u", 0, 0},
++ { XK_KP_Add, Mod1Mask|ControlMask|ShiftMask, "\033[171;8u", 0, 0},
++ { XK_KP_Add, Mod1Mask|ShiftMask, "\033[171;4u", 0, 0},
++ { XK_KP_Add, ShiftMask, "\033[171;2u", 0, 0},
++ { XK_KP_Enter, XK_NO_MOD, "\033OM", +2, 0},
++ { XK_KP_Enter, XK_NO_MOD, "\r", -1, 0},
++ { XK_KP_Enter, XK_NO_MOD, "\r\n", -1, 0},
++ { XK_KP_Enter, ControlMask, "\033[141;5u", 0, 0},
++ { XK_KP_Enter, ControlMask|ShiftMask, "\033[141;6u", 0, 0},
++ { XK_KP_Enter, Mod1Mask, "\033[141;3u", 0, 0},
++ { XK_KP_Enter, Mod1Mask|ControlMask, "\033[141;7u", 0, 0},
++ { XK_KP_Enter, Mod1Mask|ControlMask|ShiftMask, "\033[141;8u", 0, 0},
++ { XK_KP_Enter, Mod1Mask|ShiftMask, "\033[141;4u", 0, 0},
++ { XK_KP_Enter, ShiftMask, "\033[141;2u", 0, 0},
++ { XK_KP_Subtract, XK_NO_MOD, "\033Om", +2, 0},
++ { XK_KP_Subtract, ControlMask, "\033[173;5u", 0, 0},
++ { XK_KP_Subtract, ControlMask|ShiftMask, "\033[173;6u", 0, 0},
++ { XK_KP_Subtract, Mod1Mask, "\033[173;3u", 0, 0},
++ { XK_KP_Subtract, Mod1Mask|ControlMask, "\033[173;7u", 0, 0},
++ { XK_KP_Subtract, Mod1Mask|ControlMask|ShiftMask, "\033[173;8u", 0, 0},
++ { XK_KP_Subtract, Mod1Mask|ShiftMask, "\033[173;4u", 0, 0},
++ { XK_KP_Subtract, ShiftMask, "\033[173;2u", 0, 0},
++ { XK_KP_Decimal, XK_NO_MOD, "\033On", +2, 0},
++ { XK_KP_Decimal, ControlMask, "\033[174;5u", 0, 0},
++ { XK_KP_Decimal, ControlMask|ShiftMask, "\033[174;6u", 0, 0},
++ { XK_KP_Decimal, Mod1Mask, "\033[174;3u", 0, 0},
++ { XK_KP_Decimal, Mod1Mask|ControlMask, "\033[174;7u", 0, 0},
++ { XK_KP_Decimal, Mod1Mask|ControlMask|ShiftMask, "\033[174;8u", 0, 0},
++ { XK_KP_Decimal, Mod1Mask|ShiftMask, "\033[174;4u", 0, 0},
++ { XK_KP_Decimal, ShiftMask, "\033[174;2u", 0, 0},
++ { XK_KP_Divide, XK_NO_MOD, "\033Oo", +2, 0},
++ { XK_KP_Divide, ControlMask, "\033[175;5u", 0, 0},
++ { XK_KP_Divide, ControlMask|ShiftMask, "\033[175;6u", 0, 0},
++ { XK_KP_Divide, Mod1Mask, "\033[175;3u", 0, 0},
++ { XK_KP_Divide, Mod1Mask|ControlMask, "\033[175;7u", 0, 0},
++ { XK_KP_Divide, Mod1Mask|ControlMask|ShiftMask, "\033[175;8u", 0, 0},
++ { XK_KP_Divide, Mod1Mask|ShiftMask, "\033[175;4u", 0, 0},
++ { XK_KP_Divide, ShiftMask, "\033[175;2u", 0, 0},
++ { XK_KP_0, XK_NO_MOD, "\033Op", +2, 0},
++ { XK_KP_0, ControlMask, "\033[176;5u", 0, 0},
++ { XK_KP_0, ControlMask|ShiftMask, "\033[176;6u", 0, 0},
++ { XK_KP_0, Mod1Mask, "\033[176;3u", 0, 0},
++ { XK_KP_0, Mod1Mask|ControlMask, "\033[176;7u", 0, 0},
++ { XK_KP_0, Mod1Mask|ControlMask|ShiftMask, "\033[176;8u", 0, 0},
++ { XK_KP_0, Mod1Mask|ShiftMask, "\033[176;4u", 0, 0},
++ { XK_KP_0, ShiftMask, "\033[176;2u", 0, 0},
++ { XK_KP_1, XK_NO_MOD, "\033Oq", +2, 0},
++ { XK_KP_0, ControlMask, "\033[177;5u", 0, 0},
++ { XK_KP_0, ControlMask|ShiftMask, "\033[177;6u", 0, 0},
++ { XK_KP_0, Mod1Mask, "\033[177;3u", 0, 0},
++ { XK_KP_0, Mod1Mask|ControlMask, "\033[177;7u", 0, 0},
++ { XK_KP_0, Mod1Mask|ControlMask|ShiftMask, "\033[177;8u", 0, 0},
++ { XK_KP_0, Mod1Mask|ShiftMask, "\033[177;4u", 0, 0},
++ { XK_KP_0, ShiftMask, "\033[177;2u", 0, 0},
++ { XK_KP_2, XK_NO_MOD, "\033Or", +2, 0},
++ { XK_KP_2, ControlMask, "\033[178;5u", 0, 0},
++ { XK_KP_2, ControlMask|ShiftMask, "\033[178;6u", 0, 0},
++ { XK_KP_2, Mod1Mask, "\033[178;3u", 0, 0},
++ { XK_KP_2, Mod1Mask|ControlMask, "\033[178;7u", 0, 0},
++ { XK_KP_2, Mod1Mask|ControlMask|ShiftMask, "\033[178;8u", 0, 0},
++ { XK_KP_2, Mod1Mask|ShiftMask, "\033[178;4u", 0, 0},
++ { XK_KP_2, ShiftMask, "\033[178;2u", 0, 0},
++ { XK_KP_3, XK_NO_MOD, "\033Os", +2, 0},
++ { XK_KP_3, ControlMask, "\033[179;5u", 0, 0},
++ { XK_KP_3, ControlMask|ShiftMask, "\033[179;6u", 0, 0},
++ { XK_KP_3, Mod1Mask, "\033[179;3u", 0, 0},
++ { XK_KP_3, Mod1Mask|ControlMask, "\033[179;7u", 0, 0},
++ { XK_KP_3, Mod1Mask|ControlMask|ShiftMask, "\033[179;8u", 0, 0},
++ { XK_KP_3, Mod1Mask|ShiftMask, "\033[179;4u", 0, 0},
++ { XK_KP_3, ShiftMask, "\033[179;2u", 0, 0},
++ { XK_KP_4, XK_NO_MOD, "\033Ot", +2, 0},
++ { XK_KP_4, ControlMask, "\033[180;5u", 0, 0},
++ { XK_KP_4, ControlMask|ShiftMask, "\033[180;6u", 0, 0},
++ { XK_KP_4, Mod1Mask, "\033[180;3u", 0, 0},
++ { XK_KP_4, Mod1Mask|ControlMask, "\033[180;7u", 0, 0},
++ { XK_KP_4, Mod1Mask|ControlMask|ShiftMask, "\033[180;8u", 0, 0},
++ { XK_KP_4, Mod1Mask|ShiftMask, "\033[180;4u", 0, 0},
++ { XK_KP_4, ShiftMask, "\033[180;2u", 0, 0},
++ { XK_KP_5, XK_NO_MOD, "\033Ou", +2, 0},
++ { XK_KP_5, ControlMask, "\033[181;5u", 0, 0},
++ { XK_KP_5, ControlMask|ShiftMask, "\033[181;6u", 0, 0},
++ { XK_KP_5, Mod1Mask, "\033[181;3u", 0, 0},
++ { XK_KP_5, Mod1Mask|ControlMask, "\033[181;7u", 0, 0},
++ { XK_KP_5, Mod1Mask|ControlMask|ShiftMask, "\033[181;8u", 0, 0},
++ { XK_KP_5, Mod1Mask|ShiftMask, "\033[181;4u", 0, 0},
++ { XK_KP_5, ShiftMask, "\033[181;2u", 0, 0},
++ { XK_KP_6, XK_NO_MOD, "\033Ov", +2, 0},
++ { XK_KP_6, ControlMask, "\033[182;5u", 0, 0},
++ { XK_KP_6, ControlMask|ShiftMask, "\033[182;6u", 0, 0},
++ { XK_KP_6, Mod1Mask, "\033[182;3u", 0, 0},
++ { XK_KP_6, Mod1Mask|ControlMask, "\033[182;7u", 0, 0},
++ { XK_KP_6, Mod1Mask|ControlMask|ShiftMask, "\033[182;8u", 0, 0},
++ { XK_KP_6, Mod1Mask|ShiftMask, "\033[182;4u", 0, 0},
++ { XK_KP_6, ShiftMask, "\033[182;2u", 0, 0},
++ { XK_KP_7, XK_NO_MOD, "\033Ow", +2, 0},
++ { XK_KP_7, ControlMask, "\033[183;5u", 0, 0},
++ { XK_KP_7, ControlMask|ShiftMask, "\033[183;6u", 0, 0},
++ { XK_KP_7, Mod1Mask, "\033[183;3u", 0, 0},
++ { XK_KP_7, Mod1Mask|ControlMask, "\033[183;7u", 0, 0},
++ { XK_KP_7, Mod1Mask|ControlMask|ShiftMask, "\033[183;8u", 0, 0},
++ { XK_KP_7, Mod1Mask|ShiftMask, "\033[183;4u", 0, 0},
++ { XK_KP_7, ShiftMask, "\033[183;2u", 0, 0},
++ { XK_KP_8, XK_NO_MOD, "\033Ox", +2, 0},
++ { XK_KP_8, ControlMask, "\033[184;5u", 0, 0},
++ { XK_KP_8, ControlMask|ShiftMask, "\033[184;6u", 0, 0},
++ { XK_KP_8, Mod1Mask, "\033[184;3u", 0, 0},
++ { XK_KP_8, Mod1Mask|ControlMask, "\033[184;7u", 0, 0},
++ { XK_KP_8, Mod1Mask|ControlMask|ShiftMask, "\033[184;8u", 0, 0},
++ { XK_KP_8, Mod1Mask|ShiftMask, "\033[184;4u", 0, 0},
++ { XK_KP_8, ShiftMask, "\033[184;2u", 0, 0},
++ { XK_KP_9, XK_NO_MOD, "\033Oy", +2, 0},
++ { XK_KP_9, ControlMask, "\033[185;5u", 0, 0},
++ { XK_KP_9, ControlMask|ShiftMask, "\033[185;6u", 0, 0},
++ { XK_KP_9, Mod1Mask, "\033[185;3u", 0, 0},
++ { XK_KP_9, Mod1Mask|ControlMask, "\033[185;7u", 0, 0},
++ { XK_KP_9, Mod1Mask|ControlMask|ShiftMask, "\033[185;8u", 0, 0},
++ { XK_KP_9, Mod1Mask|ShiftMask, "\033[185;4u", 0, 0},
++ { XK_KP_9, ShiftMask, "\033[185;2u", 0, 0},
++ { XK_BackSpace, ControlMask, "\033[127;5u", 0, 0},
++ { XK_BackSpace, ControlMask|ShiftMask, "\033[127;6u", 0, 0},
++ { XK_BackSpace, Mod1Mask, "\033[127;3u", 0, 0},
++ { XK_BackSpace, Mod1Mask|ControlMask, "\033[127;7u", 0, 0},
++ { XK_BackSpace, Mod1Mask|ControlMask|ShiftMask, "\033[127;8u", 0, 0},
++ { XK_BackSpace, Mod1Mask|ShiftMask, "\033[127;4u", 0, 0},
++ { XK_BackSpace, ShiftMask, "\033[127;2u", 0, 0},
++ { XK_Tab, ControlMask, "\033[9;5u", 0, 0},
++ { XK_Tab, ControlMask|ShiftMask, "\033[1;5Z", 0, 0},
++ { XK_Tab, Mod1Mask, "\033[1;3Z", 0, 0},
++ { XK_Tab, Mod1Mask|ControlMask, "\033[1;7Z", 0, 0},
++ { XK_Tab, Mod1Mask|ControlMask|ShiftMask, "\033[1;8Z", 0, 0},
++ { XK_Tab, Mod1Mask|ShiftMask, "\033[1;4Z", 0, 0},
++ { XK_Return, ControlMask, "\033[13;5u", 0, 0},
++ { XK_Return, ControlMask|ShiftMask, "\033[13;6u", 0, 0},
++ { XK_Return, Mod1Mask, "\033[13;3u", 0, 0},
++ { XK_Return, Mod1Mask|ControlMask, "\033[13;7u", 0, 0},
++ { XK_Return, Mod1Mask|ControlMask|ShiftMask, "\033[13;8u", 0, 0},
++ { XK_Return, Mod1Mask|ShiftMask, "\033[13;4u", 0, 0},
++ { XK_Return, ShiftMask, "\033[13;2u", 0, 0},
++ { XK_Pause, ControlMask, "\033[18;5u", 0, 0},
++ { XK_Pause, ControlMask|ShiftMask, "\033[18;6u", 0, 0},
++ { XK_Pause, Mod1Mask, "\033[18;3u", 0, 0},
++ { XK_Pause, Mod1Mask|ControlMask, "\033[18;7u", 0, 0},
++ { XK_Pause, Mod1Mask|ControlMask|ShiftMask, "\033[18;8u", 0, 0},
++ { XK_Pause, Mod1Mask|ShiftMask, "\033[18;4u", 0, 0},
++ { XK_Pause, ShiftMask, "\033[18;2u", 0, 0},
++ { XK_Scroll_Lock, ControlMask, "\033[20;5u", 0, 0},
++ { XK_Scroll_Lock, ControlMask|ShiftMask, "\033[20;6u", 0, 0},
++ { XK_Scroll_Lock, Mod1Mask, "\033[20;3u", 0, 0},
++ { XK_Scroll_Lock, Mod1Mask|ControlMask, "\033[20;7u", 0, 0},
++ { XK_Scroll_Lock, Mod1Mask|ControlMask|ShiftMask, "\033[20;8u", 0, 0},
++ { XK_Scroll_Lock, Mod1Mask|ShiftMask, "\033[20;4u", 0, 0},
++ { XK_Scroll_Lock, ShiftMask, "\033[20;2u", 0, 0},
++ { XK_Escape, ControlMask, "\033[27;5u", 0, 0},
++ { XK_Escape, ControlMask|ShiftMask, "\033[27;6u", 0, 0},
++ { XK_Escape, Mod1Mask, "\033[27;3u", 0, 0},
++ { XK_Escape, Mod1Mask|ControlMask, "\033[27;7u", 0, 0},
++ { XK_Escape, Mod1Mask|ControlMask|ShiftMask, "\033[27;8u", 0, 0},
++ { XK_Escape, Mod1Mask|ShiftMask, "\033[27;4u", 0, 0},
++ { XK_Escape, ShiftMask, "\033[27;2u", 0, 0},
++ { XK_Home, XK_NO_MOD, "\033[H", 0, -1},
++ { XK_Home, XK_NO_MOD, "\033[1~", 0, +1},
++ { XK_Home, ControlMask|ShiftMask, "\033[80;6u", 0, 0},
++ { XK_Home, Mod1Mask, "\033[80;3u", 0, 0},
++ { XK_Home, Mod1Mask|ControlMask, "\033[80;7u", 0, 0},
++ { XK_Home, Mod1Mask|ControlMask|ShiftMask, "\033[80;8u", 0, 0},
++ { XK_Home, Mod1Mask|ShiftMask, "\033[80;4u", 0, 0},
++ { XK_End, XK_NO_MOD, "\033[4~", 0, 0},
++ { XK_End, ControlMask|ShiftMask, "\033[87;6u", 0, 0},
++ { XK_End, Mod1Mask, "\033[87;3u", 0, 0},
++ { XK_End, Mod1Mask|ControlMask, "\033[87;7u", 0, 0},
++ { XK_End, Mod1Mask|ControlMask|ShiftMask, "\033[87;8u", 0, 0},
++ { XK_End, Mod1Mask|ShiftMask, "\033[87;4u", 0, 0},
++ { XK_Prior, XK_NO_MOD, "\033[5~", 0, 0},
++ { XK_Prior, ControlMask|ShiftMask, "\033[85;6u", 0, 0},
++ { XK_Prior, Mod1Mask, "\033[85;3u", 0, 0},
++ { XK_Prior, Mod1Mask|ControlMask, "\033[85;7u", 0, 0},
++ { XK_Prior, Mod1Mask|ControlMask|ShiftMask, "\033[85;8u", 0, 0},
++ { XK_Prior, Mod1Mask|ShiftMask, "\033[85;4u", 0, 0},
++ { XK_Next, XK_NO_MOD, "\033[6~", 0, 0},
++ { XK_Next, ControlMask|ShiftMask, "\033[86;6u", 0, 0},
++ { XK_Next, Mod1Mask, "\033[86;3u", 0, 0},
++ { XK_Next, Mod1Mask|ControlMask, "\033[86;7u", 0, 0},
++ { XK_Next, Mod1Mask|ControlMask|ShiftMask, "\033[86;8u", 0, 0},
++ { XK_Next, Mod1Mask|ShiftMask, "\033[86;4u", 0, 0},
++ { XK_Print, ControlMask, "\033[97;5u", 0, 0},
++ { XK_Print, ControlMask|ShiftMask, "\033[97;6u", 0, 0},
++ { XK_Print, Mod1Mask, "\033[97;3u", 0, 0},
++ { XK_Print, Mod1Mask|ControlMask, "\033[97;7u", 0, 0},
++ { XK_Print, Mod1Mask|ControlMask|ShiftMask, "\033[97;8u", 0, 0},
++ { XK_Print, Mod1Mask|ShiftMask, "\033[97;4u", 0, 0},
++ { XK_Print, ShiftMask, "\033[97;2u", 0, 0},
++ { XK_Insert, XK_NO_MOD, "\033[4h", -1, 0},
++ { XK_Insert, XK_NO_MOD, "\033[2~", +1, 0},
++ { XK_Insert, ControlMask|ShiftMask, "\033[99;6u", 0, 0},
++ { XK_Insert, Mod1Mask, "\033[99;3u", 0, 0},
++ { XK_Insert, Mod1Mask|ControlMask, "\033[99;7u", 0, 0},
++ { XK_Insert, Mod1Mask|ControlMask|ShiftMask, "\033[99;8u", 0, 0},
++ { XK_Insert, Mod1Mask|ShiftMask, "\033[99;4u", 0, 0},
++ { XK_Menu, ControlMask, "\033[103;5u", 0, 0},
++ { XK_Menu, ControlMask|ShiftMask, "\033[103;6u", 0, 0},
++ { XK_Menu, Mod1Mask, "\033[103;3u", 0, 0},
++ { XK_Menu, Mod1Mask|ControlMask, "\033[103;7u", 0, 0},
++ { XK_Menu, Mod1Mask|ControlMask|ShiftMask, "\033[103;8u", 0, 0},
++ { XK_Menu, Mod1Mask|ShiftMask, "\033[103;4u", 0, 0},
++ { XK_Menu, ShiftMask, "\033[103;2u", 0, 0},
++ { XK_Delete, XK_NO_MOD, "\033[P", -1, 0},
++ { XK_Delete, XK_NO_MOD, "\033[3~", +1, 0},
++ { XK_Delete, ControlMask|ShiftMask, "\033[255;6u", 0, 0},
++ { XK_Delete, Mod1Mask, "\033[255;3u", 0, 0},
++ { XK_Delete, Mod1Mask|ControlMask, "\033[255;7u", 0, 0},
++ { XK_Delete, Mod1Mask|ControlMask|ShiftMask, "\033[255;8u", 0, 0},
++ { XK_Delete, Mod1Mask|ShiftMask, "\033[255;4u", 0, 0},
++ { XK_i, ControlMask, "\033[105;5u", 0, 0},
++ { XK_i, Mod1Mask|ControlMask, "\033[105;7u", 0, 0},
++ { XK_m, ControlMask, "\033[109;5u", 0, 0},
++ { XK_m, Mod1Mask|ControlMask, "\033[109;7u", 0, 0},
++ { XK_space, ControlMask|ShiftMask, "\033[32;6u", 0, 0},
++ { XK_space, Mod1Mask, "\033[32;3u", 0, 0},
++ { XK_space, Mod1Mask|ControlMask, "\033[32;7u", 0, 0},
++ { XK_space, Mod1Mask|ControlMask|ShiftMask, "\033[32;8u", 0, 0},
++ { XK_space, Mod1Mask|ShiftMask, "\033[32;4u", 0, 0},
++ { XK_space, ShiftMask, "\033[32;2u", 0, 0},
++ { XK_0, ControlMask, "\033[48;5u", 0, 0},
++ { XK_A, ControlMask|ShiftMask, "\033[65;6u", 0, 0},
++ { XK_B, ControlMask|ShiftMask, "\033[66;6u", 0, 0},
++ { XK_C, ControlMask|ShiftMask, "\033[67;6u", 0, 0},
++ { XK_D, ControlMask|ShiftMask, "\033[68;6u", 0, 0},
++ { XK_E, ControlMask|ShiftMask, "\033[69;6u", 0, 0},
++ { XK_F, ControlMask|ShiftMask, "\033[70;6u", 0, 0},
++ { XK_G, ControlMask|ShiftMask, "\033[71;6u", 0, 0},
++ { XK_H, ControlMask|ShiftMask, "\033[72;6u", 0, 0},
++ { XK_I, ControlMask|ShiftMask, "\033[73;6u", 0, 0},
++ { XK_I, Mod1Mask|ControlMask|ShiftMask, "\033[73;8u", 0, 0},
++ { XK_J, ControlMask|ShiftMask, "\033[75;6u", 0, 0},
++ { XK_K, ControlMask|ShiftMask, "\033[74;6u", 0, 0},
++ { XK_L, ControlMask|ShiftMask, "\033[76;6u", 0, 0},
++ { XK_M, ControlMask|ShiftMask, "\033[77;6u", 0, 0},
++ { XK_M, Mod1Mask|ControlMask|ShiftMask, "\033[77;8u", 0, 0},
++ { XK_N, ControlMask|ShiftMask, "\033[78;6u", 0, 0},
++ { XK_O, ControlMask|ShiftMask, "\033[79;6u", 0, 0},
++ { XK_P, ControlMask|ShiftMask, "\033[80;6u", 0, 0},
++ { XK_Q, ControlMask|ShiftMask, "\033[81;6u", 0, 0},
++ { XK_R, ControlMask|ShiftMask, "\033[82;6u", 0, 0},
++ { XK_S, ControlMask|ShiftMask, "\033[83;6u", 0, 0},
++ { XK_T, ControlMask|ShiftMask, "\033[84;6u", 0, 0},
++ { XK_U, ControlMask|ShiftMask, "\033[85;6u", 0, 0},
++ { XK_V, ControlMask|ShiftMask, "\033[86;6u", 0, 0},
++ { XK_W, ControlMask|ShiftMask, "\033[87;6u", 0, 0},
++ { XK_X, ControlMask|ShiftMask, "\033[88;6u", 0, 0},
++ { XK_Y, ControlMask|ShiftMask, "\033[89;6u", 0, 0},
++ { XK_Z, ControlMask|ShiftMask, "\033[90;6u", 0, 0},
++ { XK_Z, ControlMask|ShiftMask, "\033[90;6u", 0, 0},
++ { XK_0, Mod1Mask|ControlMask, "\033[48;7u", 0, 0},
++ { XK_1, ControlMask, "\033[49;5u", 0, 0},
++ { XK_1, Mod1Mask|ControlMask, "\033[49;7u", 0, 0},
++ { XK_2, ControlMask, "\033[50;5u", 0, 0},
++ { XK_2, Mod1Mask|ControlMask, "\033[50;7u", 0, 0},
++ { XK_3, ControlMask, "\033[51;5u", 0, 0},
++ { XK_3, Mod1Mask|ControlMask, "\033[51;7u", 0, 0},
++ { XK_4, ControlMask, "\033[52;5u", 0, 0},
++ { XK_4, Mod1Mask|ControlMask, "\033[52;7u", 0, 0},
++ { XK_5, ControlMask, "\033[53;5u", 0, 0},
++ { XK_5, Mod1Mask|ControlMask, "\033[53;7u", 0, 0},
++ { XK_6, ControlMask, "\033[54;5u", 0, 0},
++ { XK_6, Mod1Mask|ControlMask, "\033[54;7u", 0, 0},
++ { XK_7, ControlMask, "\033[55;5u", 0, 0},
++ { XK_7, Mod1Mask|ControlMask, "\033[55;7u", 0, 0},
++ { XK_8, ControlMask, "\033[56;5u", 0, 0},
++ { XK_8, Mod1Mask|ControlMask, "\033[56;7u", 0, 0},
++ { XK_9, ControlMask, "\033[57;5u", 0, 0},
++ { XK_9, Mod1Mask|ControlMask, "\033[57;7u", 0, 0},
++ { XK_ampersand, ControlMask, "\033[38;5u", 0, 0},
++ { XK_ampersand, ControlMask|ShiftMask, "\033[38;6u", 0, 0},
++ { XK_ampersand, Mod1Mask, "\033[38;3u", 0, 0},
++ { XK_ampersand, Mod1Mask|ControlMask, "\033[38;7u", 0, 0},
++ { XK_ampersand, Mod1Mask|ControlMask|ShiftMask, "\033[38;8u", 0, 0},
++ { XK_ampersand, Mod1Mask|ShiftMask, "\033[38;4u", 0, 0},
++ { XK_apostrophe, ControlMask, "\033[39;5u", 0, 0},
++ { XK_apostrophe, ControlMask|ShiftMask, "\033[39;6u", 0, 0},
++ { XK_apostrophe, Mod1Mask, "\033[39;3u", 0, 0},
++ { XK_apostrophe, Mod1Mask|ControlMask, "\033[39;7u", 0, 0},
++ { XK_apostrophe, Mod1Mask|ControlMask|ShiftMask, "\033[39;8u", 0, 0},
++ { XK_apostrophe, Mod1Mask|ShiftMask, "\033[39;4u", 0, 0},
++ { XK_asciicircum, ControlMask, "\033[94;5u", 0, 0},
++ { XK_asciicircum, ControlMask|ShiftMask, "\033[94;6u", 0, 0},
++ { XK_asciicircum, Mod1Mask, "\033[94;3u", 0, 0},
++ { XK_asciicircum, Mod1Mask|ControlMask, "\033[94;7u", 0, 0},
++ { XK_asciicircum, Mod1Mask|ControlMask|ShiftMask, "\033[94;8u", 0, 0},
++ { XK_asciicircum, Mod1Mask|ShiftMask, "\033[94;4u", 0, 0},
++ { XK_asciitilde, ControlMask, "\033[126;5u", 0, 0},
++ { XK_asciitilde, ControlMask|ShiftMask, "\033[126;6u", 0, 0},
++ { XK_asciitilde, Mod1Mask, "\033[126;3u", 0, 0},
++ { XK_asciitilde, Mod1Mask|ControlMask, "\033[126;7u", 0, 0},
++ { XK_asciitilde, Mod1Mask|ControlMask|ShiftMask, "\033[126;8u", 0, 0},
++ { XK_asciitilde, Mod1Mask|ShiftMask, "\033[126;4u", 0, 0},
++ { XK_asterisk, ControlMask, "\033[42;5u", 0, 0},
++ { XK_asterisk, ControlMask|ShiftMask, "\033[42;6u", 0, 0},
++ { XK_asterisk, Mod1Mask, "\033[42;3u", 0, 0},
++ { XK_asterisk, Mod1Mask|ControlMask, "\033[42;7u", 0, 0},
++ { XK_asterisk, Mod1Mask|ControlMask|ShiftMask, "\033[42;8u", 0, 0},
++ { XK_asterisk, Mod1Mask|ShiftMask, "\033[42;4u", 0, 0},
++ { XK_at, ControlMask, "\033[64;5u", 0, 0},
++ { XK_at, ControlMask|ShiftMask, "\033[64;6u", 0, 0},
++ { XK_at, Mod1Mask, "\033[64;3u", 0, 0},
++ { XK_at, Mod1Mask|ControlMask, "\033[64;7u", 0, 0},
++ { XK_at, Mod1Mask|ControlMask|ShiftMask, "\033[64;8u", 0, 0},
++ { XK_at, Mod1Mask|ShiftMask, "\033[64;4u", 0, 0},
++ { XK_backslash, ControlMask, "\033[92;5u", 0, 0},
++ { XK_backslash, ControlMask|ShiftMask, "\033[92;6u", 0, 0},
++ { XK_backslash, Mod1Mask, "\033[92;3u", 0, 0},
++ { XK_backslash, Mod1Mask|ControlMask, "\033[92;7u", 0, 0},
++ { XK_backslash, Mod1Mask|ControlMask|ShiftMask, "\033[92;8u", 0, 0},
++ { XK_backslash, Mod1Mask|ShiftMask, "\033[92;4u", 0, 0},
++ { XK_bar, ControlMask, "\033[124;5u", 0, 0},
++ { XK_bar, ControlMask|ShiftMask, "\033[124;6u", 0, 0},
++ { XK_bar, Mod1Mask, "\033[124;3u", 0, 0},
++ { XK_bar, Mod1Mask|ControlMask, "\033[124;7u", 0, 0},
++ { XK_bar, Mod1Mask|ControlMask|ShiftMask, "\033[124;8u", 0, 0},
++ { XK_bar, Mod1Mask|ShiftMask, "\033[124;4u", 0, 0},
++ { XK_braceleft, ControlMask, "\033[123;5u", 0, 0},
++ { XK_braceleft, ControlMask|ShiftMask, "\033[123;6u", 0, 0},
++ { XK_braceleft, Mod1Mask, "\033[123;3u", 0, 0},
++ { XK_braceleft, Mod1Mask|ControlMask, "\033[123;7u", 0, 0},
++ { XK_braceleft, Mod1Mask|ControlMask|ShiftMask, "\033[123;8u", 0, 0},
++ { XK_braceleft, Mod1Mask|ShiftMask, "\033[123;4u", 0, 0},
++ { XK_braceright, ControlMask, "\033[125;5u", 0, 0},
++ { XK_braceright, ControlMask|ShiftMask, "\033[125;6u", 0, 0},
++ { XK_braceright, Mod1Mask, "\033[125;3u", 0, 0},
++ { XK_braceright, Mod1Mask|ControlMask, "\033[125;7u", 0, 0},
++ { XK_braceright, Mod1Mask|ControlMask|ShiftMask, "\033[125;8u", 0, 0},
++ { XK_braceright, Mod1Mask|ShiftMask, "\033[125;4u", 0, 0},
++ { XK_bracketleft, ControlMask, "\033[91;5u", 0, 0},
++ { XK_bracketleft, ControlMask|ShiftMask, "\033[91;6u", 0, 0},
++ { XK_bracketleft, Mod1Mask, "\033[91;3u", 0, 0},
++ { XK_bracketleft, Mod1Mask|ControlMask, "\033[91;7u", 0, 0},
++ { XK_bracketleft, Mod1Mask|ControlMask|ShiftMask, "\033[91;8u", 0, 0},
++ { XK_bracketleft, Mod1Mask|ShiftMask, "\033[91;4u", 0, 0},
++ { XK_bracketright, ControlMask, "\033[93;5u", 0, 0},
++ { XK_bracketright, ControlMask|ShiftMask, "\033[93;6u", 0, 0},
++ { XK_bracketright, Mod1Mask, "\033[93;3u", 0, 0},
++ { XK_bracketright, Mod1Mask|ControlMask, "\033[93;7u", 0, 0},
++ { XK_bracketright, Mod1Mask|ControlMask|ShiftMask, "\033[93;8u", 0, 0},
++ { XK_bracketright, Mod1Mask|ShiftMask, "\033[93;4u", 0, 0},
++ { XK_colon, ControlMask, "\033[58;5u", 0, 0},
++ { XK_colon, ControlMask|ShiftMask, "\033[58;6u", 0, 0},
++ { XK_colon, Mod1Mask, "\033[58;3u", 0, 0},
++ { XK_colon, Mod1Mask|ControlMask, "\033[58;7u", 0, 0},
++ { XK_colon, Mod1Mask|ControlMask|ShiftMask, "\033[58;8u", 0, 0},
++ { XK_colon, Mod1Mask|ShiftMask, "\033[58;4u", 0, 0},
++ { XK_comma, ControlMask, "\033[44;5u", 0, 0},
++ { XK_comma, ControlMask|ShiftMask, "\033[44;6u", 0, 0},
++ { XK_comma, Mod1Mask, "\033[44;3u", 0, 0},
++ { XK_comma, Mod1Mask|ControlMask, "\033[44;7u", 0, 0},
++ { XK_comma, Mod1Mask|ControlMask|ShiftMask, "\033[44;8u", 0, 0},
++ { XK_comma, Mod1Mask|ShiftMask, "\033[44;4u", 0, 0},
++ { XK_dollar, ControlMask, "\033[36;5u", 0, 0},
++ { XK_dollar, ControlMask|ShiftMask, "\033[36;6u", 0, 0},
++ { XK_dollar, Mod1Mask, "\033[36;3u", 0, 0},
++ { XK_dollar, Mod1Mask|ControlMask, "\033[36;7u", 0, 0},
++ { XK_dollar, Mod1Mask|ControlMask|ShiftMask, "\033[36;8u", 0, 0},
++ { XK_dollar, Mod1Mask|ShiftMask, "\033[36;4u", 0, 0},
++ { XK_equal, ControlMask, "\033[61;5u", 0, 0},
++ { XK_equal, ControlMask|ShiftMask, "\033[61;6u", 0, 0},
++ { XK_equal, Mod1Mask, "\033[61;3u", 0, 0},
++ { XK_equal, Mod1Mask|ControlMask, "\033[61;7u", 0, 0},
++ { XK_equal, Mod1Mask|ControlMask|ShiftMask, "\033[61;8u", 0, 0},
++ { XK_equal, Mod1Mask|ShiftMask, "\033[61;4u", 0, 0},
++ { XK_exclam, ControlMask, "\033[33;5u", 0, 0},
++ { XK_exclam, ControlMask|ShiftMask, "\033[33;6u", 0, 0},
++ { XK_exclam, Mod1Mask, "\033[33;3u", 0, 0},
++ { XK_exclam, Mod1Mask|ControlMask, "\033[33;7u", 0, 0},
++ { XK_exclam, Mod1Mask|ControlMask|ShiftMask, "\033[33;8u", 0, 0},
++ { XK_exclam, Mod1Mask|ShiftMask, "\033[33;4u", 0, 0},
++ { XK_grave, ControlMask, "\033[96;5u", 0, 0},
++ { XK_grave, ControlMask|ShiftMask, "\033[96;6u", 0, 0},
++ { XK_grave, Mod1Mask, "\033[96;3u", 0, 0},
++ { XK_grave, Mod1Mask|ControlMask, "\033[96;7u", 0, 0},
++ { XK_grave, Mod1Mask|ControlMask|ShiftMask, "\033[96;8u", 0, 0},
++ { XK_grave, Mod1Mask|ShiftMask, "\033[96;4u", 0, 0},
++ { XK_greater, ControlMask, "\033[62;5u", 0, 0},
++ { XK_greater, ControlMask|ShiftMask, "\033[62;6u", 0, 0},
++ { XK_greater, Mod1Mask, "\033[62;3u", 0, 0},
++ { XK_greater, Mod1Mask|ControlMask, "\033[62;7u", 0, 0},
++ { XK_greater, Mod1Mask|ControlMask|ShiftMask, "\033[62;8u", 0, 0},
++ { XK_greater, Mod1Mask|ShiftMask, "\033[62;4u", 0, 0},
++ { XK_less, ControlMask, "\033[60;5u", 0, 0},
++ { XK_less, ControlMask|ShiftMask, "\033[60;6u", 0, 0},
++ { XK_less, Mod1Mask, "\033[60;3u", 0, 0},
++ { XK_less, Mod1Mask|ControlMask, "\033[60;7u", 0, 0},
++ { XK_less, Mod1Mask|ControlMask|ShiftMask, "\033[60;8u", 0, 0},
++ { XK_less, Mod1Mask|ShiftMask, "\033[60;4u", 0, 0},
++ { XK_minus, ControlMask, "\033[45;5u", 0, 0},
++ { XK_minus, ControlMask|ShiftMask, "\033[45;6u", 0, 0},
++ { XK_minus, Mod1Mask, "\033[45;3u", 0, 0},
++ { XK_minus, Mod1Mask|ControlMask, "\033[45;7u", 0, 0},
++ { XK_minus, Mod1Mask|ControlMask|ShiftMask, "\033[45;8u", 0, 0},
++ { XK_minus, Mod1Mask|ShiftMask, "\033[45;4u", 0, 0},
++ { XK_numbersign, ControlMask, "\033[35;5u", 0, 0},
++ { XK_numbersign, ControlMask|ShiftMask, "\033[35;6u", 0, 0},
++ { XK_numbersign, Mod1Mask, "\033[35;3u", 0, 0},
++ { XK_numbersign, Mod1Mask|ControlMask, "\033[35;7u", 0, 0},
++ { XK_numbersign, Mod1Mask|ControlMask|ShiftMask, "\033[35;8u", 0, 0},
++ { XK_numbersign, Mod1Mask|ShiftMask, "\033[35;4u", 0, 0},
++ { XK_parenleft, ControlMask, "\033[40;5u", 0, 0},
++ { XK_parenleft, ControlMask|ShiftMask, "\033[40;6u", 0, 0},
++ { XK_parenleft, Mod1Mask, "\033[40;3u", 0, 0},
++ { XK_parenleft, Mod1Mask|ControlMask, "\033[40;7u", 0, 0},
++ { XK_parenleft, Mod1Mask|ControlMask|ShiftMask, "\033[40;8u", 0, 0},
++ { XK_parenleft, Mod1Mask|ShiftMask, "\033[40;4u", 0, 0},
++ { XK_parenright, ControlMask, "\033[41;5u", 0, 0},
++ { XK_parenright, ControlMask|ShiftMask, "\033[41;6u", 0, 0},
++ { XK_parenright, Mod1Mask, "\033[41;3u", 0, 0},
++ { XK_parenright, Mod1Mask|ControlMask, "\033[41;7u", 0, 0},
++ { XK_parenright, Mod1Mask|ControlMask|ShiftMask, "\033[41;8u", 0, 0},
++ { XK_parenright, Mod1Mask|ShiftMask, "\033[41;4u", 0, 0},
++ { XK_percent, ControlMask, "\033[37;5u", 0, 0},
++ { XK_percent, ControlMask|ShiftMask, "\033[37;6u", 0, 0},
++ { XK_percent, Mod1Mask, "\033[37;3u", 0, 0},
++ { XK_percent, Mod1Mask|ControlMask, "\033[37;7u", 0, 0},
++ { XK_percent, Mod1Mask|ControlMask|ShiftMask, "\033[37;8u", 0, 0},
++ { XK_percent, Mod1Mask|ShiftMask, "\033[37;4u", 0, 0},
++ { XK_period, ControlMask, "\033[46;5u", 0, 0},
++ { XK_period, ControlMask|ShiftMask, "\033[46;6u", 0, 0},
++ { XK_period, Mod1Mask|ControlMask, "\033[46;7u", 0, 0},
++ { XK_period, Mod1Mask|ControlMask|ShiftMask, "\033[46;8u", 0, 0},
++ { XK_period, Mod1Mask|ShiftMask, "\033[46;4u", 0, 0},
++ { XK_plus, ControlMask, "\033[43;5u", 0, 0},
++ { XK_plus, ControlMask|ShiftMask, "\033[43;6u", 0, 0},
++ { XK_plus, Mod1Mask, "\033[43;3u", 0, 0},
++ { XK_plus, Mod1Mask|ControlMask, "\033[43;7u", 0, 0},
++ { XK_plus, Mod1Mask|ControlMask|ShiftMask, "\033[43;8u", 0, 0},
++ { XK_plus, Mod1Mask|ShiftMask, "\033[43;4u", 0, 0},
++ { XK_question, ControlMask, "\033[63;5u", 0, 0},
++ { XK_question, ControlMask|ShiftMask, "\033[63;6u", 0, 0},
++ { XK_question, Mod1Mask, "\033[63;3u", 0, 0},
++ { XK_question, Mod1Mask|ControlMask, "\033[63;7u", 0, 0},
++ { XK_question, Mod1Mask|ControlMask|ShiftMask, "\033[63;8u", 0, 0},
++ { XK_question, Mod1Mask|ShiftMask, "\033[63;4u", 0, 0},
++ { XK_quotedbl, ControlMask, "\033[34;5u", 0, 0},
++ { XK_quotedbl, ControlMask|ShiftMask, "\033[34;6u", 0, 0},
++ { XK_quotedbl, Mod1Mask, "\033[34;3u", 0, 0},
++ { XK_quotedbl, Mod1Mask|ControlMask, "\033[34;7u", 0, 0},
++ { XK_quotedbl, Mod1Mask|ControlMask|ShiftMask, "\033[34;8u", 0, 0},
++ { XK_quotedbl, Mod1Mask|ShiftMask, "\033[34;4u", 0, 0},
++ { XK_semicolon, ControlMask, "\033[59;5u", 0, 0},
++ { XK_semicolon, ControlMask|ShiftMask, "\033[59;6u", 0, 0},
++ { XK_semicolon, Mod1Mask, "\033[59;3u", 0, 0},
++ { XK_semicolon, Mod1Mask|ControlMask, "\033[59;7u", 0, 0},
++ { XK_semicolon, Mod1Mask|ControlMask|ShiftMask, "\033[59;8u", 0, 0},
++ { XK_semicolon, Mod1Mask|ShiftMask, "\033[59;4u", 0, 0},
++ { XK_slash, ControlMask|ShiftMask, "\033[47;6u", 0, 0},
++ { XK_slash, Mod1Mask, "\033[47;3u", 0, 0},
++ { XK_slash, Mod1Mask|ControlMask, "\033[47;7u", 0, 0},
++ { XK_slash, Mod1Mask|ControlMask|ShiftMask, "\033[47;8u", 0, 0},
++ { XK_slash, Mod1Mask|ShiftMask, "\033[47;4u", 0, 0},
++ { XK_underscore, ControlMask, "\033[95;5u", 0, 0},
++ { XK_underscore, ControlMask|ShiftMask, "\033[95;6u", 0, 0},
++ { XK_underscore, Mod1Mask, "\033[95;3u", 0, 0},
++ { XK_underscore, Mod1Mask|ControlMask, "\033[95;7u", 0, 0},
++ { XK_underscore, Mod1Mask|ControlMask|ShiftMask, "\033[95;8u", 0, 0},
++ { XK_underscore, Mod1Mask|ShiftMask, "\033[95;4u", 0, 0},
+ };
+
+ /*
+--
+2.21.0
+
diff --git a/patches/x11-terms/st-0.8.2/0005-apply-st-gruvbox-both-0.8.1.diff.patch b/patches/x11-terms/st-0.8.2/0005-apply-st-gruvbox-both-0.8.1.diff.patch
@@ -0,0 +1,214 @@
+From a5f5407bbcaa7d232af0e43bcacaac39d9b871ea Mon Sep 17 00:00:00 2001
+From: "Haelwenn (lanodan) Monnier" <contact@hacktivis.me>
+Date: Tue, 23 Oct 2018 02:39:08 +0200
+Subject: [PATCH 5/5] apply st-gruvbox-both-0.8.1.diff
+
+---
+ config.def.h | 68 +++++++++++++++++++++++++++++++++-------------------
+ st.h | 1 +
+ x.c | 28 +++++++++++++++++-----
+ 3 files changed, 66 insertions(+), 31 deletions(-)
+
+diff --git a/config.def.h b/config.def.h
+index 78ebbc5..5f9a078 100644
+--- a/config.def.h
++++ b/config.def.h
+@@ -84,31 +84,48 @@ unsigned int tabspaces = 8;
+
+ /* Terminal colors (16 first used in escape sequence) */
+ static const char *colorname[] = {
+- /* 8 normal colors */
+- "black",
+- "red3",
+- "green3",
+- "yellow3",
+- "blue2",
+- "magenta3",
+- "cyan3",
+- "gray90",
+-
+- /* 8 bright colors */
+- "gray50",
+- "red",
+- "green",
+- "yellow",
+- "#5c5cff",
+- "magenta",
+- "cyan",
+- "white",
++ /* gruvbox dark */
++ "#282828", /* hard contrast: #1d2021 / soft contrast: #32302f / normal: #282828 */
++ "#cc241d",
++ "#98971a",
++ "#d79921",
++ "#458588",
++ "#b16286",
++ "#689d6a",
++ "#a89984",
++ "#928374",
++ "#fb4934",
++ "#b8bb26",
++ "#fabd2f",
++ "#83a598",
++ "#d3869b",
++ "#8ec07c",
++ "#ebdbb2",
+
+ [255] = 0,
++};
+
+- /* more colors can be added after 255 to use with DefaultXX */
+- "#cccccc",
+- "#555555",
++/* Terminal colors for alternate (light) palette */
++static const char *altcolorname[] = {
++ /* gruvbox light */
++ "#fbf1c7", /* hard contrast: #f9f5d7 / soft contrast: #f2e5bc / normal: #fbf1c7 */
++ "#cc241d",
++ "#98971a",
++ "#d79921",
++ "#458588",
++ "#b16286",
++ "#689d6a",
++ "#7c6f64",
++ "#928374",
++ "#9d0006",
++ "#79740e",
++ "#b57614",
++ "#076678",
++ "#8f3f71",
++ "#427b58",
++ "#3c3836",
++
++ [255] = 0,
+ };
+
+
+@@ -116,10 +133,10 @@ static const char *colorname[] = {
+ * Default colors (colorname index)
+ * foreground, background, cursor, reverse cursor
+ */
+-unsigned int defaultfg = 7;
++unsigned int defaultfg = 15;
+ unsigned int defaultbg = 0;
+-static unsigned int defaultcs = 256;
+-static unsigned int defaultrcs = 257;
++static unsigned int defaultcs = 15;
++static unsigned int defaultrcs = 0;
+
+ /*
+ * Default shape of cursor
+@@ -178,6 +195,7 @@ static Shortcut shortcuts[] = {
+ { TERMMOD, XK_Y, selpaste, {.i = 0} },
+ { ShiftMask, XK_Insert, selpaste, {.i = 0} },
+ { TERMMOD, XK_Num_Lock, numlock, {.i = 0} },
++ { TERMMOD, XK_F6, swapcolors, {.i = 0} },
+ };
+
+ /*
+diff --git a/st.h b/st.h
+index 38c61c4..941b5f8 100644
+--- a/st.h
++++ b/st.h
+@@ -117,6 +117,7 @@ extern char *vtiden;
+ extern char *worddelimiters;
+ extern int allowaltscreen;
+ extern char *termname;
++extern int usealtcolors;
+ extern unsigned int tabspaces;
+ extern unsigned int defaultfg;
+ extern unsigned int defaultbg;
+diff --git a/x.c b/x.c
+index 2cd76d0..5a54960 100644
+--- a/x.c
++++ b/x.c
+@@ -53,6 +53,7 @@ static void clipcopy(const Arg *);
+ static void clippaste(const Arg *);
+ static void numlock(const Arg *);
+ static void selpaste(const Arg *);
++static void swapcolors(const Arg *);
+ static void zoom(const Arg *);
+ static void zoomabs(const Arg *);
+ static void zoomreset(const Arg *);
+@@ -244,6 +245,8 @@ static char *opt_title = NULL;
+
+ static int oldbutton = 3; /* button event on startup: 3 = release */
+
++int usealtcolors = 0; /* 1 to use alternate palette */
++
+ void
+ clipcopy(const Arg *dummy)
+ {
+@@ -282,6 +285,14 @@ numlock(const Arg *dummy)
+ win.mode ^= MODE_NUMLOCK;
+ }
+
++void
++swapcolors(const Arg *dummy)
++{
++ usealtcolors = !usealtcolors;
++ xloadcols();
++ redraw();
++}
++
+ void
+ zoom(const Arg *arg)
+ {
+@@ -706,6 +717,11 @@ sixd_to_16bit(int x)
+ return x == 0 ? 0 : 0x3737 + 0x2828 * x;
+ }
+
++const char* getcolorname(int i)
++{
++ return (usealtcolors) ? altcolorname[i] : colorname[i];
++}
++
+ int
+ xloadcolor(int i, const char *name, Color *ncolor)
+ {
+@@ -724,7 +740,7 @@ xloadcolor(int i, const char *name, Color *ncolor)
+ return XftColorAllocValue(xw.dpy, xw.vis,
+ xw.cmap, &color, ncolor);
+ } else
+- name = colorname[i];
++ name = getcolorname(i);
+ }
+
+ return XftColorAllocName(xw.dpy, xw.vis, xw.cmap, name, ncolor);
+@@ -741,14 +757,14 @@ xloadcols(void)
+ for (cp = dc.col; cp < &dc.col[dc.collen]; ++cp)
+ XftColorFree(xw.dpy, xw.vis, xw.cmap, cp);
+ } else {
+- dc.collen = MAX(LEN(colorname), 256);
++ dc.collen = MAX(LEN(colorname), LEN(altcolorname));
+ dc.col = xmalloc(dc.collen * sizeof(Color));
+ }
+
+ for (i = 0; i < dc.collen; i++)
+ if (!xloadcolor(i, NULL, &dc.col[i])) {
+- if (colorname[i])
+- die("could not allocate color '%s'\n", colorname[i]);
++ if (getcolorname(i))
++ die("could not allocate color '%s'\n", getcolorname(i));
+ else
+ die("could not allocate color %d\n", i);
+ }
+@@ -1108,13 +1124,13 @@ xinit(int cols, int rows)
+ cursor = XCreateFontCursor(xw.dpy, mouseshape);
+ XDefineCursor(xw.dpy, xw.win, cursor);
+
+- if (XParseColor(xw.dpy, xw.cmap, colorname[mousefg], &xmousefg) == 0) {
++ if (XParseColor(xw.dpy, xw.cmap, getcolorname(mousefg), &xmousefg) == 0) {
+ xmousefg.red = 0xffff;
+ xmousefg.green = 0xffff;
+ xmousefg.blue = 0xffff;
+ }
+
+- if (XParseColor(xw.dpy, xw.cmap, colorname[mousebg], &xmousebg) == 0) {
++ if (XParseColor(xw.dpy, xw.cmap, getcolorname(mousebg), &xmousebg) == 0) {
+ xmousebg.red = 0x0000;
+ xmousebg.green = 0x0000;
+ xmousebg.blue = 0x0000;
+--
+2.21.0
+
diff --git a/postsync.d/000-sync_gentoo_cache b/postsync.d/000-sync_gentoo_cache
@@ -0,0 +1,34 @@
+#!/bin/bash
+
+repository_name="${1}"
+repository_path="${3}"
+
+[[ ${repository_name} == "gentoo" ]] || exit 0
+
+source /lib/gentoo/functions.sh
+
+# Number of jobs for egencache, default is number or processors.
+parallel_jobs="$(nproc)"
+
+if [[ -f ${repository_path}/metadata/timestamp.x ]]; then
+ portage_current_timestamp=$(cut -f 1 -d " " "${repository_path}/metadata/timestamp.x" )
+else
+ portage_current_timestamp=0
+fi
+
+ebegin "Fetching metadata timestamp for ${repository_name}"
+rsync -aq rsync://rsync.gentoo.org/gentoo-portage/metadata/timestamp.x "${repository_path}"/metadata/timestamp.x
+eend $?
+portage_new_timestamp=$(cut -f 1 -d " " "${repository_path}/metadata/timestamp.x" )
+
+if [[ ${portage_current_timestamp} -lt ${portage_new_timestamp} ]]; then
+ ebegin "Fetching pre-generated metadata cache for ${repository_name}"
+ rsync -aq rsync://rsync.gentoo.org/gentoo-portage/metadata/md5-cache/ "${repository_path}"/metadata/md5-cache/
+ eend $?
+else
+ einfo "Metadata cache for ${repository_name} already recent, no need to fetch it :-)"
+fi
+
+ebegin "Updating metadata cache for ${repository_name}"
+egencache --jobs="${parallel_jobs}" --repo="${repository_name}" --update --update-use-local-desc
+eend $?
diff --git a/postsync.d/000-sync_gentoo_dtd b/postsync.d/000-sync_gentoo_dtd
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+repository_name="${1}"
+repository_path="${3}"
+
+[[ ${repository_name} == "gentoo" ]] || exit 0
+
+source /lib/gentoo/functions.sh
+
+DTDDIR="${repository_path}"/metadata/dtd
+ebegin "Updating DTDs"
+if [[ -e ${DTDDIR} ]]; then
+ git -C "${DTDDIR}" pull -q --ff-only
+else
+ git clone -q https://anongit.gentoo.org/git/data/dtd.git "${DTDDIR}"
+fi
+eend "$?"
diff --git a/postsync.d/000-sync_gentoo_glsa b/postsync.d/000-sync_gentoo_glsa
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+repository_name="${1}"
+repository_path="${3}"
+
+[[ ${repository_name} == "gentoo" ]] || exit 0
+
+source /lib/gentoo/functions.sh
+
+GLSADIR="${repository_path}"/metadata/glsa
+ebegin "Updating GLSAs"
+if [[ -e ${GLSADIR} ]]; then
+ git -C "${GLSADIR}" pull -q --ff-only
+else
+ git clone -q https://anongit.gentoo.org/git/data/glsa.git "${GLSADIR}"
+fi
+eend "$?"
diff --git a/postsync.d/000-sync_gentoo_news b/postsync.d/000-sync_gentoo_news
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+repository_name="${1}"
+repository_path="${3}"
+
+[[ ${repository_name} == "gentoo" ]] || exit 0
+
+source /lib/gentoo/functions.sh
+
+NEWSDIR="${repository_path}"/metadata/news
+ebegin "Updating news items"
+if [[ -e ${NEWSDIR} ]]; then
+ git -C "${NEWSDIR}" pull -q --ff-only
+else
+ git clone -q https://anongit.gentoo.org/git/data/gentoo-news.git "${NEWSDIR}"
+fi
+eend $? "Try to remove ${NEWSDIR}"
diff --git a/postsync.d/000-sync_gentoo_projects_xml b/postsync.d/000-sync_gentoo_projects_xml
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+repository_name="${1}"
+repository_path="${3}"
+
+[[ ${repository_name} == "gentoo" ]] || exit 0
+
+source /lib/gentoo/functions.sh
+
+ebegin "Updating projects.xml"
+wget -q -P "${repository_path}"/metadata/ -N https://api.gentoo.org/metastructure/projects.xml
+eend $?
diff --git a/postsync.d/000-sync_overlay_cache b/postsync.d/000-sync_overlay_cache
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+repository_name="${1}"
+
+[[ -z ${repository_name} ]] && exit 0
+[[ ${repository_name} == "gentoo" ]] && exit 0
+
+source /lib/gentoo/functions.sh
+
+# Number of jobs for egencache, default is number or processors.
+parallel_jobs="$(nproc)"
+
+ebegin "Updating metadata cache for ${repository_name}"
+egencache --jobs="${parallel_jobs}" --repo="${repository_name}" --update --update-use-local-desc
+eend $?
diff --git a/postsync.d/9998-eix b/postsync.d/9998-eix
@@ -0,0 +1,8 @@
+#!/bin/sh
+if [[ -e /var/cache/eix/portage.eix ]]; then
+ cp -a /var/cache/eix/portage.eix /var/cache/eix/previous.eix;
+fi
+eix-update
+if [[ -e /var/cache/eix/previous.eix ]]; then
+ eix-diff;
+fi
diff --git a/postsync.d/9999-eix-remote b/postsync.d/9999-eix-remote
@@ -0,0 +1,2 @@
+#!/bin/sh
+eix-remote update