Fix Dropdown issue
This commit is contained in:
25
Makefile
25
Makefile
@@ -1,5 +1,6 @@
|
||||
# gKeyMapper - Build
|
||||
# Dependencies: g++, pkg-config, msgfmt, libgtk-4-dev, libusb-1.0-0-dev, libxkbcommon-dev
|
||||
# Dependencies: g++, pkg-config, gettext (msgfmt, for the translations),
|
||||
# libgtk-4-dev, libusb-1.0-0-dev, libxkbcommon-dev
|
||||
# Installation: sudo apt install build-essential gettext libgtk-4-dev libusb-1.0-0-dev libxkbcommon-dev
|
||||
|
||||
CXX ?= g++
|
||||
@@ -42,12 +43,15 @@ DBUS_DIR := $(PREFIX)/share/dbus-1/services
|
||||
CXXFLAGS += -DPACKAGE=\"$(PACKAGE)\" -DLOCALEDIR=\"$(LOCALEDIR)\" -DASSETS_DIR=\"$(ASSETS_DIR)\"
|
||||
CXXFLAGS += -I$(SHARED_DIR)
|
||||
|
||||
# Translations
|
||||
# Translations. The .pot is generated from the sources (make pot) and the
|
||||
# catalogs are merged against it (scripts/i18n.sh update); the rules are in
|
||||
# po/README.md.
|
||||
PO_FILES := $(wildcard po/*.po)
|
||||
LANGS := $(patsubst po/%.po,%,$(PO_FILES))
|
||||
MO_FILES := $(patsubst %,locale/%/LC_MESSAGES/$(PACKAGE).mo,$(LANGS))
|
||||
I18N := $(CURDIR)/scripts/i18n.sh
|
||||
|
||||
.PHONY: all clean run install translations daemon
|
||||
.PHONY: all clean run install translations daemon pot i18n-check i18n-status
|
||||
|
||||
all: $(TARGET) translations $(DAEMON)
|
||||
|
||||
@@ -72,6 +76,21 @@ locale/%/LC_MESSAGES/$(PACKAGE).mo: po/%.po
|
||||
@mkdir -p $(@D)
|
||||
$(MSGFMT) -o $@ $<
|
||||
|
||||
# Regenerate po/gkeymapper.pot from the sources. "make translations" does not: a
|
||||
# pot that is written by a build is a pot that nobody has looked at, and the
|
||||
# strings are reviewed by hand (po/README.md, "Adding or changing a string").
|
||||
pot:
|
||||
$(I18N) extract
|
||||
|
||||
# Everything that can be wrong with the translations at once: the pot against the
|
||||
# sources, every catalog against the pot, and the language list of the GUI against
|
||||
# po/*.po. Run it before committing a string change.
|
||||
i18n-check:
|
||||
$(I18N) check
|
||||
|
||||
i18n-status:
|
||||
$(I18N) status
|
||||
|
||||
run: $(TARGET) translations
|
||||
GKEYMAPPER_LOCALEDIR=$(CURDIR)/locale GKEYMAPPER_ASSETS_DIR=$(CURDIR)/assets ./$(TARGET)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user