--- a/misc/armadillo.pc.in
+++ b/misc/armadillo.pc.in
@@ -1,5 +1,7 @@
-libdir=@CMAKE_INSTALL_FULL_LIBDIR@
-includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@
+prefix=@CMAKE_INSTALL_PREFIX@
+exec_prefix=${prefix}
+libdir=${exec_prefix}/lib
+includedir=${prefix}/include
 
 Name: armadillo
 Description: Fast C++ matrix library with syntax similar to MATLAB and Octave
