Add iab.txt which is needed for the new hwdb update.
[oweals/hwids.git] / Makefile
1 # can be replaced with `wget -q -O -` if you want
2 ifeq "$(V)" "0"
3   HTTPCAT = curl -s
4   STATUS = git status -s
5   Q=@
6 else
7   HTTPCAT = curl
8   STATUS = git status
9   Q=
10 endif
11
12 fetch:
13         $(Q)$(HTTPCAT) http://pci-ids.ucw.cz/v2.2/pci.ids.bz2 | bzcat > pci.ids
14         $(Q)$(HTTPCAT) http://www.linux-usb.org/usb.ids.bz2 | bzcat > usb.ids
15         $(Q)$(HTTPCAT) http://standards.ieee.org/develop/regauth/oui/oui.txt > oui.txt
16         $(Q)$(HTTPCAT) http://standards.ieee.org/develop/regauth/iab/iab.txt > iab.txt
17         $(Q)$(HTTPCAT) http://cgit.freedesktop.org/systemd/systemd/plain/hwdb/20-acpi-vendor.hwdb > udev/20-acpi-vendor.hwdb
18         $(Q)$(HTTPCAT) http://cgit.freedesktop.org/systemd/systemd/plain/hwdb/ids-update.pl > udev-hwdb-update.pl
19         $(Q)$(STATUS)
20
21 PV ?= $(shell ( awk '$$2 == "Date:" { print $$3; nextfile }' pci.ids usb.ids; git log --format=format:%ci -1 -- oui.txt hwdb/20-acpi-vendor.hwdb udev-hwdb-update.pl | cut -d ' ' -f1; ) | sort | tail -n 1 | tr -d -)
22 P = hwids-$(PV)
23
24 tag:
25         git tag $(P)
26
27 udev-hwdb:
28         perl ./udev-hwdb-update.pl && mv *.hwdb udev/