forked from sam1am/Ryzen-Master-Commander
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.py
More file actions
57 lines (53 loc) · 2.22 KB
/
Copy pathsetup.py
File metadata and controls
57 lines (53 loc) · 2.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
from setuptools import setup, find_namespace_packages
from src.version import __version__
import os
# All paths for data_files must be relative to this setup.py file.
fan_profiles_source_dir = 'share/ryzen-master-commander/fan_profiles'
tdp_profiles_source_dir = 'share/ryzen-master-commander/tdp_profiles'
data_files = [
('share/applications', ['share/applications/ryzen-master-commander.desktop']),
(fan_profiles_source_dir,
[os.path.join(fan_profiles_source_dir, f) for f in os.listdir(fan_profiles_source_dir) if os.path.isfile(os.path.join(fan_profiles_source_dir, f))]),
(tdp_profiles_source_dir,
[os.path.join(tdp_profiles_source_dir, f) for f in os.listdir(tdp_profiles_source_dir) if os.path.isfile(os.path.join(tdp_profiles_source_dir, f))]),
('bin', ['bin/ryzen-master-commander-helper']),
('share/polkit-1/actions', ['polkit/com.merrythieves.ryzenadj.policy']),
]
# Add icon files using relative paths
for size in ['16x16', '32x32', '64x64', '128x128']:
icon_source_file_rel = os.path.join('share/icons/hicolor', size, 'apps', 'ryzen-master-commander.png')
icon_target_dir = os.path.join('share/icons/hicolor', size, 'apps')
if os.path.isfile(icon_source_file_rel):
data_files.append((icon_target_dir, [icon_source_file_rel]))
setup(
version=__version__,
name="ryzen-master-commander",
author="sam1am",
author_email="noreply@merrythieves.com",
description="TDP and fan control for AMD Ryzen processors",
url="https://github.com/sam1am/Ryzen-Master-Commander",
# package_dir={"": "src"}, # Tell setuptools packages are under src
# packages=find_namespace_packages(where="src"), # Find all packages under src
packages=["src", "src.app"],
include_package_data=True,
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: POSIX :: Linux",
],
license_files=('LICENSE',),
install_requires=[
"PyQt6",
"pyqtgraph",
"numpy",
"Pillow",
"pystray",
],
python_requires=">=3.8",
data_files=data_files,
entry_points={
'console_scripts': [
'ryzen-master-commander=src.main:main',
],
},
)