Index: xCAT-nbroot/xcat-core-nbroot.spec
===================================================================
--- xCAT-nbroot/xcat-core-nbroot.spec	(revision 14914)
+++ xCAT-nbroot/xcat-core-nbroot.spec	(working copy)
@@ -13,7 +13,10 @@
 Release: snap%(date +"%Y%m%d%H%M")
 Epoch: 4
 AutoReq: false
-Prefix: /opt/xcat
+
+%{!?_xcat_home: %define _xcat_home /opt/xcat}
+
+Prefix: %{_xcat_home}
 AutoProv: false
 
 
@@ -58,4 +61,4 @@
 %Files
 %defattr(-,root,root)
 %doc LICENSE.html
-/
+%{_xcat_home}/*
Index: xCAT-nbroot2/xCAT-genesis-builder.spec
===================================================================
--- xCAT-nbroot2/xCAT-genesis-builder.spec	(revision 14914)
+++ xCAT-nbroot2/xCAT-genesis-builder.spec	(working copy)
@@ -5,7 +5,10 @@
 Epoch: 1
 AutoReq: false
 Requires: efibootmgr ipmitool screen btrfs-progs lldpad rpm-build compat-libstdc++-33
-Prefix: /opt/xcat
+
+%{!?_xcat_home: %define _xcat_home /opt/xcat}
+
+Prefix: %{_xcat_home}
 AutoProv: false
 
 
@@ -41,4 +44,4 @@
 %Files
 %defattr(-,root,root)
 %doc LICENSE.html
-/
+%{_xcat_home}/*
Index: xCAT-nbroot2/xCAT-genesis.spec
===================================================================
--- xCAT-nbroot2/xCAT-genesis.spec	(revision 14914)
+++ xCAT-nbroot2/xCAT-genesis.spec	(working copy)
@@ -16,7 +16,10 @@
 Release: snap%(date +"%Y%m%d%H%M")
 Epoch: 1
 AutoReq: false
-Prefix: /opt/xcat
+
+%{!?_xcat_home: %define _xcat_home /opt/xcat}
+Prefix: %{_xcat_home}
+
 AutoProv: false
 
 
@@ -58,4 +61,4 @@
 
 %Files
 %defattr(-,root,root)
-/
+%{_xcat_home}/*
