diff --git a/src/meson.build b/src/meson.build index ee17d8f..49a5fa4 100644 --- a/src/meson.build +++ b/src/meson.build @@ -98,20 +98,11 @@ executable('power-profiles-daemon', install_dir: libexecdir ) -python = import('python') -py_installation = python.find_installation('python3', required: true) - -ppd_conf = configuration_data() -ppd_conf.set('VERSION', meson.project_version()) -ppd_conf.set('PYTHON3', py_installation.full_path()) - -script = configure_file( - input: 'powerprofilesctl.in', - output: 'powerprofilesctl', - configuration: ppd_conf, - install_dir: get_option('bindir') +script = 'powerprofilesctl' +install_data(script, + install_dir: get_option('bindir') ) - +script = join_paths(meson.current_source_dir(), script) if get_option('pylint') test('pylint-powerprofilesctl', pylint, diff --git a/src/powerprofilesctl.in b/src/powerprofilesctl similarity index 99% rename from src/powerprofilesctl.in rename to src/powerprofilesctl index a4ecc99..7eb86f8 100755 --- a/src/powerprofilesctl.in +++ b/src/powerprofilesctl @@ -1,12 +1,10 @@ -#!@PYTHON3@ +#!/usr/bin/env python3 import signal import subprocess import sys from gi.repository import Gio, GLib -VERSION = "@VERSION@" - PP_NAME = "org.freedesktop.UPower.PowerProfiles" PP_PATH = "/org/freedesktop/UPower/PowerProfiles" PP_IFACE = "org.freedesktop.UPower.PowerProfiles"