# Patches the build system 
# Ward Poelmans <ward.poelmans@ugent.be>
diff -ur likwid-likwid-4.1.0.orig/config.mk likwid-likwid-4.1.0/config.mk
--- likwid-likwid-4.1.0.orig/config.mk	2016-05-19 13:16:28.000000000 +0200
+++ likwid-likwid-4.1.0/config.mk	2016-05-19 13:46:33.345284562 +0200
@@ -9,7 +9,7 @@
 COLOR = BLUE#NO SPACE
 
 # Path were to install likwid
-PREFIX = /usr/local#NO SPACE
+#PREFIX = /usr/local#NO SPACE
 
 #################################################################
 # Common users do not need to change values below this comment! #
@@ -33,7 +33,7 @@
 # chown installed tools to this user/group
 # if you change anything here, make sure that the user/group can access
 # the MSR devices and (on Intel) the PCI devices.
-INSTALL_CHOWN = -g root -o root
+INSTALL_CHOWN = 
 
 # For the daemon based secure msr/pci access configure
 # the absolute path to the msr daemon executable.
@@ -44,7 +44,7 @@
 # Build the accessDaemon. Have a look in the WIKI for details.
 BUILDDAEMON = true#NO SPACE
 #Build the setFrequencies tool
-BUILDFREQ = true#NO SPACE
+BUILDFREQ = false#NO SPACE
 
 # Set the default mode for MSR access.
 # This can usually be overriden on the commandline.
@@ -71,8 +71,8 @@
 # a proper config file at CFG_FILE_PATH)
 MAX_NUM_THREADS = 263
 MAX_NUM_NODES = 64
-CFG_FILE_PATH = /etc/likwid.cfg
-TOPO_FILE_PATH = /etc/likwid_topo.cfg
+CFG_FILE_PATH = $(PREFIX)/etc/likwid.cfg
+TOPO_FILE_PATH = $(PREFIX)/etc/likwid_topo.cfg
 
 # Versioning Information
 VERSION = 4
