Improved support for detecting missing dependencies:
- Added libpaper-dev package checking. - Previously, SDL_Pango's bug forced Tux Paint to include a customized version of SDL_Pango.h in its distribution, so we couldn't tell if SDL_Pango was installed in the system by including SDL_Pango.h. We made a new workaround for SDL_Pango's bug that does not require Tux Paint to include SDL_Pango.h, so now we can check for SDL_Pango installation. - Makefile now includes a check for gettext installation and will not fail when attempting to generate .mo files or install .mo files. Instead, Makefile will now display a warning and skip the .mo file generation and installation steps. Many thanks to Arunodai Vudem for the patches.
This commit is contained in:
parent
0e49f7bc82
commit
4cabed88a6
6 changed files with 85 additions and 170 deletions
25
Makefile
25
Makefile
|
|
@ -387,8 +387,24 @@ uninstall-i18n:
|
|||
|
||||
|
||||
# Install the translated text:
|
||||
# We can install *.mo files if they were already generated, or if it can be
|
||||
# generated from the *.po files. The *.mo files can be generated from the
|
||||
# *.po files if we have the converter program, msgfmt, installed in the
|
||||
# system. So we test for both and install them if either case is found
|
||||
# to be true. If neither case is found to be true, we'll just install
|
||||
# Tux Paint without the translation files.
|
||||
.PHONY: install-gettext
|
||||
ifeq "$(wildcard trans/*.mo)$(shell msgfmt -h)" ""
|
||||
install-gettext:
|
||||
@echo
|
||||
@echo "--------------------------------------------------------------"
|
||||
@echo "Cannot install translation files because no translation files"
|
||||
@echo "were found (trans/*.mo) and the 'msgfmt' program is not installed."
|
||||
@echo "You will not be able to run Tux Paint in non-U.S. English modes."
|
||||
@echo "--------------------------------------------------------------"
|
||||
else
|
||||
install-gettext: $(INSTALLED_MOFILES)
|
||||
endif
|
||||
|
||||
|
||||
# Install the Input Method files:
|
||||
|
|
@ -428,7 +444,16 @@ $(MOFILES): trans/%.mo: src/po/%.po
|
|||
msgfmt -o $@ $<
|
||||
|
||||
.PHONY: translations
|
||||
ifeq "$(shell msgfmt -h)" ""
|
||||
translations: trans
|
||||
@echo "--------------------------------------------------------------"
|
||||
@echo "Cannot find program 'msgfmt'!"
|
||||
@echo "No translation files will be prepared."
|
||||
@echo "Install gettext to run Tux Paint in non-U.S. English modes."
|
||||
@echo "--------------------------------------------------------------"
|
||||
else
|
||||
translations: trans $(MOFILES)
|
||||
endif
|
||||
|
||||
trans:
|
||||
@echo
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue