Browse Source

Cleanup db/Makefile

doc_update_sequoia
Damiano Boppart 5 years ago
parent
commit
23073c18ed
1 changed files with 8 additions and 6 deletions
  1. +8
    -6
      db/Makefile

+ 8
- 6
db/Makefile View File

@ -3,20 +3,22 @@
include ../Makefile.conf
.PHONY: db
db: system.db
dicos=$(wildcard *.csv)
DICOS = $(wildcard *.csv)
system.db: create_system_db.sql $(dicos)
system.db: create_system_db.sql $(DICOS)
# Keep a backup db around
-mv -f $@ $@~
sqlite3 -batch $@ < $<
for c in $(dicos); do echo $$c ; echo .import "$$c" wordlist | sqlite3 -batch -csv $@ ; done
.PHONY: clean install
for c in $(DICOS) ; do echo "$$c" ; echo .import "$$c" wordlist | sqlite3 -batch -csv $@ ; done
.PHONY: install
install: system.db
mkdir -p `dirname $(SYSTEM_DB)`
cp system.db $(SYSTEM_DB)
.PHONY: clean
clean:
rm -f system.db
-rm -f system.db system.db~

Loading…
Cancel
Save