@@ -0,0 +1,28 @@
1+{ stdenv, lib, fetchFromGitHub, cmake, pkgconfig }:
2+
3+stdenv.mkDerivation {
4+ name = "elementary-cmake-modules";
5+
6+ src = fetchFromGitHub {
7+ owner = "elementary";
8+ repo = "cmake-modules";
9+ rev = "319ec5336e9f05f3f22b886cc2053ef3d4b6599e";
10+ sha256 = "191hhvdxyqvh9axzndaqld7vrmv7xkn0czks908zhb2zpjhv9rby";
11+ };
12+
13+ prePatch = ''
14+ substituteInPlace CMakeLists.txt \
15+ --replace ' ''${CMAKE_ROOT}/Modules' " $out/lib/cmake"
16+ '';
17+
18+ propagatedBuildInputs = [ cmake pkgconfig ];
19+
20+ setupHook = ./setup-hook.sh;
21+
22+ meta = with lib; {
23+ platforms = platforms.linux ++ platforms.darwin;
24+ homepage = https://github.com/elementary/cmake-modules;
25+ license = licenses.gpl3Plus;
26+ maintainers = [ maintainers.samdroid-apps ];
27+ };
28+}