test
This commit is contained in:
parent
4c84939ef9
commit
dc6b805fe6
2 changed files with 13 additions and 7 deletions
14
setup.py
14
setup.py
|
|
@ -3,11 +3,12 @@
|
|||
import os
|
||||
import sys
|
||||
from glob import glob
|
||||
from distutils.core import setup
|
||||
from setuptools import setup
|
||||
|
||||
try:
|
||||
from distutils import dep_util
|
||||
from setuptools import dep_util
|
||||
except:
|
||||
print("No")
|
||||
pass
|
||||
|
||||
|
||||
|
|
@ -36,7 +37,7 @@ def get_data_files():
|
|||
# translations must be always in /usr/share because Gtk.builder only
|
||||
# search there. If someone knows how to fix this...
|
||||
# share/locale/fr/LC_MESSAGES/
|
||||
target = os.path.join('/usr', 'share', 'locale',
|
||||
target = os.path.join('share', 'locale',
|
||||
lang_name, 'LC_MESSAGES')
|
||||
data_files.append((target, [mofile]))
|
||||
|
||||
|
|
@ -63,10 +64,9 @@ def compile_translations():
|
|||
if not os.path.isdir(modir):
|
||||
os.makedirs(modir)
|
||||
|
||||
if not os.path.isfile(mofile) or dep_util.newer(pofile, mofile):
|
||||
# msgfmt.make(pofile, mofile)
|
||||
os.system("msgfmt \"" + pofile + "\" -o \"" + mofile + "\"")
|
||||
os.system("msgfmt \"" + pofile + "\" -o \"" + mofile + "\"")
|
||||
except:
|
||||
print("Error")
|
||||
pass
|
||||
|
||||
try:
|
||||
|
|
@ -132,5 +132,5 @@ setup(
|
|||
scripts=['src/devede_ng.py', 'src/copy_files_verbose.py'],
|
||||
)
|
||||
|
||||
if (len(sys.argv) == 2) and (sys.argv[1] == "install"):
|
||||
if (len(sys.argv) >= 2) and (sys.argv[1] == "install"):
|
||||
os.system("gtk-update-icon-cache")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue