summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorPeter Strapp2016-02-18 00:24:52 +0000
committerPeter Strapp2016-02-18 00:24:52 +0000
commit98fda341f31c956f4a1eab6dba8d9069a349fe33 (patch)
tree76ee28f52ba4836040af86b4bd7748a762ed695c /PKGBUILD
parentfdcb8e95d7d08a4397c1c419e14f6bd2c6895ada (diff)
downloadaur-98fda341f31c956f4a1eab6dba8d9069a349fe33.tar.gz
Two-pass build now far more reliable
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD22
1 files changed, 14 insertions, 8 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 42f33b4b0434..4fc6cb338948 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -3,12 +3,12 @@
pkgname=libindi_3rdparty
pkgver=1.2.0
-pkgrel=1
+pkgrel=2
pkgdesc="3rd party drivers for INDI, a distributed control protocol designed to operate astronomical instrumentation"
url="http://www.indilib.org/index.php?title=Main_Page"
license=(LGPL2.1)
arch=(i686 x86_64)
-depends=(libvorbis libusb openal libnova libjpeg libindi libgphoto2 libftdi-compat cfitsio dcraw)
+depends=(libvorbis libusb openal libnova libjpeg libindi libgphoto2 libftdi-compat cfitsio dcraw libqhy-git)
makedepends=(cmake boost)
source=("http://indilib.org/jdownloads/Source/${pkgname}_${pkgver}.tar.gz")
sha1sums=('7348b96ae663d11ea877bdb9f181e3126e14eeb6')
@@ -16,17 +16,23 @@ sha1sums=('7348b96ae663d11ea877bdb9f181e3126e14eeb6')
prepare() {
mkdir -p build
cd ${pkgname}_${pkgver}
- find ./ -name CMakeLists.txt -exec sed -i -e 's|"/lib/firmware|"/usr/lib/firmware|' {} \;
- find ./ -name CMakeLists.txt -exec sed -i -e 's|"/lib/udev|"/etc/udev|' {} \;
- sed -e 's|<ApogeeCam.h>|<libapogee/ApogeeCam.h>|' -i indi-apogee/apogee_ccd.h
- sed -e 's|<FindDeviceEthernet.h>|<libapogee/FindDeviceEthernet.h>|' -i indi-apogee/apogee_ccd.h
- sed -e 's|<FindDeviceUsb.h>|<libapogee/FindDeviceUsb.h>|' -i indi-apogee/apogee_ccd.h
+ find ./ -name CMakeLists.txt -exec sed -i -e 's|"\/lib|"${CMAKE_INSTALL_PREFIX}/lib|g' {} \; # Allow installing outside of /lib
+ sed -e 's|<ApogeeCam.h>|<libapogee/ApogeeCam.h>|' -i indi-apogee/apogee_ccd.h # Headers found in libapogee directory
+ sed -e 's|<FindDeviceEthernet.h>|<libapogee/FindDeviceEthernet.h>|' -i indi-apogee/apogee_ccd.h # Headers found in libapogee directory
+ sed -e 's|<FindDeviceUsb.h>|<libapogee/FindDeviceUsb.h>|' -i indi-apogee/apogee_ccd.h # Headers found in libapogee directory
+ sed -e 's|#add_subdirectory[(]indi-qhy[)]|add_subdirectory(indi-qhy)|' -i CMakeLists.txt # Enable build of QHY INDI driver (despite it being "broken")
+ cp CMakeLists.txt CMakeLists.txt.bak # Backup CMakeLists.txt. It's modified for first pass and restored for second pass.
+ sed -e '/###/d' -i CMakeLists.txt # Force all libraries to be built
+ sed -e '/_FOUND[)]/d' -i CMakeLists.txt # Force all libraries to be built
+ sed -e '/add_subdirectory[(]indi-/d' -i CMakeLists.txt # Force all libraries to be built
}
build() {
cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr ../${pkgname}_${pkgver}
- make DESTDIR="/tmp/${pkgname}_${pkgver}" install
+ make DESTDIR="/tmp/${pkgname}_${pkgver}" install # Install libraries to temp directory for use in INDI driver build
+
+ cp ../${pkgname}_${pkgver}/CMakeLists.txt.bak ../${pkgname}_${pkgver}/CMakeLists.txt # Restore original CMakeLists.txt for INDI driver build
cmake -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DFISHCAMP_LIBRARIES=/tmp/${pkgname}_${pkgver}/usr/lib/libfishcamp.so \