generated from hsbasu/template-repo
-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Install python sources using meson build
- Setup meson to install python sources during python and meson builds - Install executable binary using meson and avoid using python builds for now - Remove unnecessary python packaging files
- Loading branch information
Showing
8 changed files
with
67 additions
and
111 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
include debian/changelog | ||
global-exclude *.py[cod] | ||
graft data* | ||
include src/battery-monitor.in | ||
graft src/ThemeManager/ui* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
@version@ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
python_sources = [ | ||
'about_window.py', | ||
'common.py', | ||
'DesktopTheme.py', | ||
'gui.py', | ||
'indicator.py', | ||
'__init__.py', | ||
'logger.py', | ||
'LoginTheme.py', | ||
'main.py', | ||
'time_chooser.py', | ||
'tm_daemon.py', | ||
] | ||
|
||
version_file = configure_file( | ||
input: 'VERSION.in', | ||
output: 'VERSION', | ||
configuration: { | ||
'version': meson.project_version(), | ||
} | ||
) | ||
|
||
python.install_sources( | ||
python_sources, version_file, | ||
subdir: 'ThemeManager', | ||
preserve_path: true, | ||
) | ||
|
||
# Install assets like ui and icons | ||
ui = files('ui/theme-manager.ui', 'ui/logger.ui') | ||
|
||
install_data( | ||
ui, | ||
install_dir: join_paths(pysrcinstalldir, 'ThemeManager', 'ui') | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
pysrcinstalldir = python.get_install_dir() # python.get_path('platlib') | ||
message(f'Python dir: @pysrcinstalldir@') | ||
|
||
conf = configuration_data() | ||
conf.set('PYTHON', python.full_path()) | ||
conf.set('pkgdatadir', pysrcinstalldir) | ||
|
||
configure_file( | ||
input: 'theme-manager.in', | ||
output: 'theme-manager', | ||
configuration: conf, | ||
install: true, | ||
install_dir: bindir, | ||
install_mode: 'rwxr-xr-x' | ||
) | ||
|
||
subdir('ThemeManager') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!@PYTHON@ | ||
# -*- coding: utf-8 -*- | ||
import re | ||
import sys | ||
|
||
sys.path.insert(1, '@pkgdatadir@') | ||
|
||
from ThemeManager.main import start_TM | ||
if __name__ == '__main__': | ||
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0]) | ||
sys.exit(start_TM()) |