diff --git a/system/base/pisi/files/kernel_build_fix.patch b/system/base/pisi/files/kernel_build_fix.patch
new file mode 100644
index 00000000..19547fa8
--- /dev/null
+++ b/system/base/pisi/files/kernel_build_fix.patch
@@ -0,0 +1,14 @@
+diff --git a/pisi/actionsapi/kerneltools.py b/pisi/actionsapi/kerneltools.py
+index df3de3b..2560b47 100644
+--- a/pisi/actionsapi/kerneltools.py
++++ b/pisi/actionsapi/kerneltools.py
+@@ -253,6 +253,9 @@ def installLibcHeaders(excludes=None):
+ # Create directories
+ shelltools.makedirs(headers_tmp)
+ shelltools.makedirs(headers_dir)
++
++ # Clean up the source directory
++ autotools.make('mrproper')
+
+ # install the headers
+ autotools.rawInstall(make_cmd, "headers_install")
diff --git a/system/base/pisi/pspec.xml b/system/base/pisi/pspec.xml
index cfba2fba..037c2166 100644
--- a/system/base/pisi/pspec.xml
+++ b/system/base/pisi/pspec.xml
@@ -22,6 +22,9 @@
intltool
leveldb-devel
+
+ kernel_build_fix.patch
+
@@ -71,6 +74,13 @@
+
+ 2020-01-10
+ 2.7.1
+ Apply patch and rebuild
+ Safa Arıman
+ safa@ariman.gen.tr
+
2020-01-10
2.7.1