Page 1 of 1

Define the installation directory.

PostPosted: Thu May 17, 2012 10:29 am
by jduran
Hello,

By default, the library is installed in /usr/local, it is valid as a default option, however sometimes, it is needed to install the library in another directory, for example, because it has been compiled for another architecture. I've defined the variable PREFIX to set the directory base to install the library. http://stackoverflow.com/questions/7106442/qt-project-files-and-prefix-variable

The patch is:
Code: Select all
--- QxOrm/QxOrm.pro.prev   2012-05-17 12:01:34.323390561 +0200
+++ QxOrm/QxOrm.pro   2012-05-17 12:08:31.491376455 +0200
@@ -52,11 +52,15 @@
 } # CONFIG(debug, debug|release)
 
 unix {
+isEmpty(PREFIX){
+PREFIX = /usr/local
+}
+
 DESTDIR = ./lib/
-target.path = /usr/local/lib/
-headers.path = /usr/local/include/
+target.path = $$PREFIX/lib/
+headers.path = $$PREFIX/include/
 headers.files = ./include/*
-headers_inl.path = /usr/local/inl/
+headers_inl.path = $$PREFIX/inl/
 headers_inl.files = ./inl/*
 INSTALLS = target headers headers_inl
 } # unix


Thanks and Best Regards,
Joaquim Duran

Re: Define the installation directory.

PostPosted: Thu May 17, 2012 4:33 pm
by QxOrm admin
Hi,

Thanx, it's a good idea, I will add this PREFIX variable for the next official release (QxOrm 1.2.4) !