-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
34 lines (24 loc) · 767 Bytes
/
Copy pathMakefile
File metadata and controls
34 lines (24 loc) · 767 Bytes
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
DAZ_FS=$(shell pwd)/../crypt4gh-sqlite.fs
DAZ_MNT=$(shell pwd)/mnt
DAZ_SQLITE=$(shell pwd)/example.sqlite
DAZ_SQLITE_BAK=$(DAZ_SQLITE).bak
DAZ_SECKEY=$(shell pwd)/example.seckey
export C4GH_PASSPHRASE=hello
DAZ_OPTS+=ro,seckey=$(DAZ_SECKEY),passphrase_from_env=C4GH_PASSPHRASE
DAZ_OPTS+=allow_other,default_permissions
DAZ_OPTS+=file_cache,dir_cache
all: up
debug: DAZ_FS+= -d
debug1 debug2 debug3: DAZ_FS+= -g
debug1: DAZ_OPTS+=local_debug=1
debug2: DAZ_OPTS+=local_debug=2
debug3: DAZ_OPTS+=local_debug=3
up debug debug1 debug2 debug3: $(DAZ_SQLITE) | mnt
$(DAZ_FS) $(DAZ_OPTS:%=-o %) $< $(DAZ_MNT)
down:
umount $(DAZ_MNT)
mnt:
mkdir -p -m 700 $@
$(DAZ_SQLITE): $(DAZ_SQLITE_BAK)
@cp $< $@
@sqlite3 $@ "UPDATE files SET mountpoint = '$(shell pwd)';"