diff --git a/mrpt/Makefile b/mrpt/Makefile
index 9d143a7912782925eeeb6bbf179abef158174229..375949c458780a62a79db42bee9c5a9de5c0e8cd 100644
--- a/mrpt/Makefile
+++ b/mrpt/Makefile
@@ -8,6 +8,8 @@ CATEGORIES=		wip
 MASTER_SITES= 	${MASTER_SITE_SOURCEFORGE:=mrpt/}
 MASTER_REPOSITORY=	https://github.com/jlblancoc/mrpt
 
+PKGREVISION= 	1
+
 MAINTAINER=		arnaud.degroote@isae.fr
 COMMENT=		Mobile Robot Programming Toolkit
 HOMEPAGE= 		http://www.mrpt.org
diff --git a/mrpt/distinfo b/mrpt/distinfo
index a8e76241b1fe82fd071da308448565fca2e09519..c3fc0b7eceabaa89d689db0111a803e602e9e733 100644
--- a/mrpt/distinfo
+++ b/mrpt/distinfo
@@ -1,3 +1,4 @@
 SHA1 (mrpt-1.2.2.tar.gz) = 30936e4af61539b976d213415b82c7a0c3aae4a9
 RMD160 (mrpt-1.2.2.tar.gz) = aa24a73048655e82d9c381bcbbcb07a4ad97995c
 Size (mrpt-1.2.2.tar.gz) = 22496370 bytes
+SHA1 (patch-aa) = d00e0223be0fee23f687623fe6d6f2847263c61c
diff --git a/mrpt/patches/patch-aa b/mrpt/patches/patch-aa
new file mode 100644
index 0000000000000000000000000000000000000000..5fdd7aca9990a8085ba620c7d7bf7f49ead2799c
--- /dev/null
+++ b/mrpt/patches/patch-aa
@@ -0,0 +1,15 @@
+Handle "undefined" semantic of cmake for CMAKE_INSTALL_LIBDIR. In this context,
+CMAKE_INSTALL_LIBDIR is basically "lib", so one need to add a trailing / to make a
+valid pc
+
+--- parse-files/mrpt_template.pc.in.orig	2014-10-06 09:53:43.591941564 +0200
++++ parse-files/mrpt_template.pc.in	2014-10-06 09:54:26.315940299 +0200
+@@ -1,7 +1,7 @@
+ # This file is a parsed version for mrpt_pkgconfig_LIBNAME= @mrpt_pkgconfig_LIBNAME@
+ prefix=@mrpt_pkgconfig_INSTALL_PREFIX@
+ exec_prefix=${prefix}
+-libdir=${exec_prefix}@CMAKE_INSTALL_LIBDIR@
++libdir=${exec_prefix}/@CMAKE_INSTALL_LIBDIR@
+ includedir=${prefix}/include
+ 
+ Name: The mrpt-@mrpt_pkgconfig_LIBNAME@ library