-
Notifications
You must be signed in to change notification settings - Fork 21
/
dev.nix
82 lines (73 loc) · 1.83 KB
/
dev.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
with import <nixpkgs> { };
let
dontCheckPython = drv: drv.overridePythonAttrs (old: { doCheck = false; });
pythonPackages = python312Packages;
harfbuzz_self = harfbuzz.override { withCoreText = true; };
ld_packages = [
harfbuzz_self
harfbuzz_self.dev
imagemagick
gdal
geos
cairo
glib.out
pango
fontconfig.lib
libspatialite
file
ghostscript
postgresql.lib
mupdf
gettext
];
in
pkgs.mkShell {
name = "fds";
shellHook = ''
echo "Launching fds shell"
export FRAGDENSTAAT_DYLD_LIBRARY_PATH=${builtins.concatStringsSep ":" (map (x: x + "/lib") ld_packages)}
export LD_LIBRARY_PATH=$FRAGDENSTAAT_DYLD_LIBRARY_PATH:$LD_LIBRARY_PATH
export DYLD_LIBRARY_PATH=$FRAGDENSTAAT_DYLD_LIBRARY_PATH:$DYLD_LIBRARY_PATH
source fds-env/bin/activate
export CPATH="$CPATH:${mupdf.dev}/include/mupdf"
export PYTHONBREAKPOINT=ipdb.set_trace
export GDAL_LIBRARY_PATH=${gdal}/lib/libgdal.dylib
export GEOS_LIBRARY_PATH=${geos}/lib/libgeos_c.dylib
export CPLUS_INCLUDE_PATH="$CPLUS_INCLUDE_PATH:${libcxx.dev}/include"
export CFLAGS="-stdlib=libc++ -DUSE_STD_NAMESPACE -I${libcxx.dev}/include/c++/v1"
export MACOSX_DEPLOYMENT_TARGET=10.9
export MAGICK_HOME="${imagemagick}"
'';
buildInputs = [
uv
pythonPackages.python
gdal
pythonPackages.gdal
pythonPackages.tkinter
pythonPackages.magic
# pythonPackages.ocrmypdf
pythonPackages.weasyprint
pnpm
pkg-config
geos
cairo
pango
gettext
harfbuzz_self
imagemagick
poppler_utils
libspatialite
file
qpdf
chromedriver
git-crypt
postgresql_14
postgresql14Packages.postgis
gdal
mupdf
glib
libcxx
cmake
stripe-cli
] ++ (lib.optional stdenv.isDarwin pkgs.darwin.apple_sdk.frameworks.CoreText);
}