Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#59347 - [range-v3] CMake config files not installed

Attached to Project: Community Packages
Opened by Filip Matzner (floop) - Sunday, 15 July 2018, 20:34 GMT
Last edited by Sven-Hendrik Haase (Svenstaro) - Sunday, 29 July 2018, 14:53 GMT
Task Type Feature Request
Category Packages
Status Closed
Assigned To Sven-Hendrik Haase (Svenstaro)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Currently, this package simply copies the header files into /usr/include. Unfortunately, the corresponding CMake config files are therefore not installed and range-v3 cannot be checked by external projects using CMake directive find_package(range-v3).

The following PKGBUILD installs range-v3 using the official CMake instructions, in case you are interested. I am not sure about the `gcc` dependency.

pkgname=range-v3
pkgver=0.3.6
pkgrel=1
pkgdesc="Experimental range library for C++11/14/17"
arch=('any')
url='https://github.com/ericniebler/range-v3'
license=('custom')
makedepends=('cmake' 'gcc')
source=("https://github.com/ericniebler/range-v3/archive/${pkgver}.tar.gz")
sha512sums=('218cb179023980a3c13678da24638a10030e1c957c711117ebdd7d895f6480644b598686bc1a03d0460889ac058c0f6f9b2d9fcafaae0588a6e2cc1752be1db0')

prepare() {
cd "${srcdir}/range-v3-${pkgver}"
rm -rf build && mkdir build
}

build() {
cd "${srcdir}/range-v3-${pkgver}"

cd build
cmake .. \
-DCMAKE_INSTALL_PREFIX=/usr \
-DRANGE_V3_TESTS=OFF \
-DRANGE_V3_HEADER_CHECKS=OFF \
-DRANGE_V3_EXAMPLES=OFF \
-DRANGE_V3_PERF=OFF
make
}

package() {
cd "${srcdir}/range-v3-${pkgver}"
install -Dm644 "LICENSE.txt" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"

cd build
make DESTDIR="${pkgdir}/" install
}

This task depends upon

Closed by  Sven-Hendrik Haase (Svenstaro)
Sunday, 29 July 2018, 14:53 GMT
Reason for closing:  Fixed
Comment by Filip Matzner (floop) - Sunday, 15 July 2018, 20:36 GMT
Here is the attached PKGBUILD (the second one, sorry, the interface does not seem to allow removing files).
Comment by Doug Newgard (Scimmia) - Wednesday, 18 July 2018, 15:09 GMT
Wow, that is a bad PKGBUILD, but using cmake makes sense.
Comment by Filip Matzner (floop) - Wednesday, 18 July 2018, 20:02 GMT
@Scimmia I am sorry if you consider it that bad, if you have some specific objections, I am happy to learn and improve. I tried to base it on:
https://git.archlinux.org/svntogit/community.git/tree/trunk/PKGBUILD?h=packages/arrayfire
Comment by Sven-Hendrik Haase (Svenstaro) - Sunday, 22 July 2018, 02:18 GMT
I actually think that this is a rather good PKGBUILD and I'm going to use it more or less like that. What do you dislike about it Doug?

Loading...