From cfbc17fbd8d2063c3440df156fb1f285ea9427bf Mon Sep 17 00:00:00 2001
From: Florent Gluck <florent.gluck@hesge.ch>
Date: Wed, 25 Nov 2020 10:33:17 +0100
Subject: [PATCH] Added how to compile and install kdbg from source

---
 README.md      |  2 +-
 kdbg/README.md | 30 ++++++++++++++++++++++++++++++
 2 files changed, 31 insertions(+), 1 deletion(-)
 create mode 100644 kdbg/README.md

diff --git a/README.md b/README.md
index 7e340f6..dccb11a 100644
--- a/README.md
+++ b/README.md
@@ -1 +1 @@
-The goal of this repository is to document how to configure (or extend) various applications (vscodium, pandoc, etc.).
+The goal of this repository is to document how to install and/or configure (or extend) various applications (kdbg, vscodium, pandoc, etc.).
diff --git a/kdbg/README.md b/kdbg/README.md
new file mode 100644
index 0000000..508f673
--- /dev/null
+++ b/kdbg/README.md
@@ -0,0 +1,30 @@
+# What is Kdbg?
+
+Kdbg is a nice native frontend to the GDB debugger.
+However, kdbg is not available in Ubuntu 20.04 anymore. Therefore, to install it on this distribution one needs to compile it from source.
+This is what we describe here.
+
+# Compiling and installing Kdbg from source
+
+The instructions given here apply to any Ubuntu 18.04 or 20.04 systems (and their derivatives such as Xubuntu, etc.).
+
+Install the required development packages:
+```
+apt-get install git build-essential cmake extra-cmake-modules qtbase5-dev libkf5style-dev gettext libkf5xmlgui-dev
+```
+
+Clone the repository:
+```
+git clone -b maint https://github.com/j6t/kdbg.git kdbg.git && cd kdbg.git
+```
+
+Specify the base directory where Kdbg will be installed: replace `install_dir` with a base directory of your choice. If `-DCMAKE_INSTALL_PREFIX` is omitted, it will be installed system-wide (in `/usr/local/`) which I personally don't recommend as it will pollute the system and will be tricky to cleanly remove later.
+```
+cmake -DCMAKE_INSTALL_PREFIX=install_dir .
+```
+
+Install Kdbg. If you want to do a system-wide install, the command below must be run as `root` (since non root users can't write in `/usr/local`).
+```
+make install
+```
+
-- 
GitLab