update: use the new package manager
This commit is contained in:
22
Makefile
22
Makefile
@ -14,7 +14,7 @@ dist/xcfg: $(CSRCS) $(HEADERS)
|
||||
mkdir -p dist
|
||||
$(CC) $(CFLAGS) $(CSRCS) -o $@ -lncurses -lmenu -lm
|
||||
|
||||
locale/%.mo: locale/%.po
|
||||
locale/%.mo: locale/%.po
|
||||
msgfmt $^ -o $@
|
||||
|
||||
locale/%.po: locale/xcfg.pot
|
||||
@ -24,7 +24,7 @@ locale/%.po: locale/xcfg.pot
|
||||
echo "merge success: $@" ; \
|
||||
else \
|
||||
echo "merge failed: $@" ; \
|
||||
mv $@.old $@ ; \
|
||||
install -m644 $@.old $@ ; \
|
||||
fi; \
|
||||
|
||||
locale/xcfg.pot: $(CSRCS)
|
||||
@ -32,25 +32,25 @@ locale/xcfg.pot: $(CSRCS)
|
||||
xgettext -k_ -c $^ -o $@
|
||||
|
||||
install:
|
||||
mkdir -pv $(DESTDIR)$(prefix)/bin
|
||||
install -v -m755 dist/xcfg $(DESTDIR)$(prefix)/bin/xcfg
|
||||
mkdir -pv $(DESTDIR)/$(prefix)/bin
|
||||
install -v -m755 dist/xcfg $(DESTDIR)/$(prefix)/bin/xcfg
|
||||
@for po in $(PO_DIRS) ; do \
|
||||
echo "installing locale: $$po/xcfg.mo" ; \
|
||||
mkdir -pv $(DESTDIR)/usr/share/$$po ; \
|
||||
cp $$po/xcfg.mo $(DESTDIR)/usr/share/$$po ; \
|
||||
install -v -Ddm755 $(DESTDIR)/usr/share/$$po ; \
|
||||
install -m644 $$po/xcfg.mo $(DESTDIR)/usr/share/$$po ; \
|
||||
done
|
||||
|
||||
uninstall:
|
||||
rm -v $(DESTDIR)$(prefix)/bin/xcfg
|
||||
rm -v $(DESTDIR)/$(prefix)/bin/xcfg
|
||||
|
||||
clean:
|
||||
rm dist/xcfg
|
||||
rm locale/xcfg.pot
|
||||
rm -v dist/xcfg
|
||||
rm -v locale/xcfg.pot
|
||||
@for po in $(PO_DIRS) ; do \
|
||||
rm $$po/xcfg.mo ; \
|
||||
done
|
||||
|
||||
format:
|
||||
clang-format -i -style=file $(HEADERS) $(CSRCS)
|
||||
clang-format -i -style=file $(HEADERS) $(CSRCS)
|
||||
|
||||
.PHONY: install defcfg uninstall clean
|
||||
.PHONY: install uninstall clean
|
||||
|
Reference in New Issue
Block a user