2019-02-25 05:09:35 +00:00
|
|
|
#!/usr/bin/env python3
|
2018-06-08 10:04:30 +00:00
|
|
|
|
|
|
|
import os
|
|
|
|
import sys
|
|
|
|
import subprocess
|
|
|
|
|
|
|
|
if 'DESTDIR' not in os.environ:
|
|
|
|
gtk_api_version = sys.argv[1]
|
|
|
|
gtk_abi_version = sys.argv[2]
|
2019-02-26 22:51:55 +00:00
|
|
|
gtk_libdir = sys.argv[3]
|
|
|
|
gtk_datadir = sys.argv[4]
|
2018-06-08 10:04:30 +00:00
|
|
|
|
|
|
|
gtk_moduledir = os.path.join(gtk_libdir, 'gtk-' + gtk_api_version, gtk_abi_version)
|
|
|
|
gtk_printmodule_dir = os.path.join(gtk_moduledir, 'printbackends')
|
|
|
|
gtk_immodule_dir = os.path.join(gtk_moduledir, 'immodules')
|
|
|
|
|
|
|
|
print('Compiling GSettings schemas...')
|
|
|
|
subprocess.call(['glib-compile-schemas',
|
|
|
|
os.path.join(gtk_datadir, 'glib-2.0', 'schemas')])
|
|
|
|
|
|
|
|
print('Updating icon cache...')
|
2019-04-02 00:20:30 +00:00
|
|
|
subprocess.call(['gtk4-update-icon-cache', '-q', '-t' ,'-f',
|
2018-06-08 10:04:30 +00:00
|
|
|
os.path.join(gtk_datadir, 'icons', 'hicolor')])
|
|
|
|
|
|
|
|
print('Updating module cache for print backends...')
|
2019-02-26 22:55:08 +00:00
|
|
|
os.makedirs(gtk_printmodule_dir, exist_ok=True)
|
2018-06-08 10:04:30 +00:00
|
|
|
subprocess.call(['gio-querymodules', gtk_printmodule_dir])
|
|
|
|
|
|
|
|
print('Updating module cache for input methods...')
|
2019-02-26 22:55:08 +00:00
|
|
|
os.makedirs(gtk_immodule_dir, exist_ok=True)
|
2018-06-08 10:04:30 +00:00
|
|
|
subprocess.call(['gio-querymodules', gtk_immodule_dir])
|