forked from pop-os/system76-scheduler
-
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.
chore: Setup system76-scheduler 2.0 for Fedora copr build system
- Loading branch information
Showing
7 changed files
with
238 additions
and
9 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 |
---|---|---|
@@ -0,0 +1,12 @@ | ||
version: "1" | ||
rules: | ||
- base: master | ||
upstream: pop-os:master | ||
mergeMethod: merge | ||
mergeUnstable: false | ||
assignees: | ||
- KyleGospo | ||
reviewers: | ||
- KyleGospo | ||
conflictReviewers: | ||
- KyleGospo |
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
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,103 @@ | ||
assignments { | ||
recording { | ||
amsynth | ||
easyeffects | ||
jamesdsp | ||
jitsi | ||
mumble | ||
obs | ||
teams | ||
wireplumber | ||
zoom | ||
bitwig-studio | ||
fx_cast_bridge | ||
include name="Bitwig*" | ||
} | ||
|
||
games { | ||
lutris | ||
steam | ||
vrcompositor | ||
vrdashboard | ||
vrmonitor | ||
vrserver | ||
include descends="steam" | ||
include descends="lutris" | ||
} | ||
|
||
desktop-environment { | ||
cosmic-comp | ||
gnome-shell | ||
i3wm | ||
kwin | ||
sway | ||
Xorg | ||
} | ||
|
||
session-services { | ||
include parent="gnome-session-binary" | ||
include parent="gvfsd" | ||
} | ||
|
||
package-manager { | ||
include name="apt-*" | ||
include name="dpkg-*" | ||
apt | ||
dpkg | ||
flatpak | ||
fwupd | ||
packagekitd | ||
update-initramfs | ||
apk | ||
dnf | ||
pacman | ||
include name="rpm-*" | ||
rpm | ||
swupd | ||
yay | ||
yum | ||
zypper | ||
} | ||
|
||
batch { | ||
include name="sbuild-*" | ||
"7z" | ||
"7za" | ||
"7zr" | ||
ar | ||
boinc | ||
c++ | ||
cargo | ||
clang | ||
cmake | ||
cpp | ||
FAHClient | ||
FAHCoreWrapper | ||
fossilize-replay | ||
g++ | ||
gcc | ||
gradle | ||
javac | ||
ld | ||
lld | ||
make | ||
mold | ||
mvn | ||
ninja | ||
rust-analyzer | ||
rustc | ||
sbuild | ||
tar | ||
tracker-miner-fs-3 | ||
unrar | ||
zip | ||
rslsync | ||
} | ||
} | ||
|
||
exceptions { | ||
preload | ||
include name="fig_*" | ||
fig | ||
vanilla-first-setup | ||
} |
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,93 @@ | ||
Name: system76-scheduler | ||
Version: 2.{{{ git_dir_version }}} | ||
Release: 1%{?dist} | ||
Summary: System76 Scheduler daemon - Auto-configure CFS and process priorities for improved desktop responsiveness | ||
|
||
License: MPLv2.0 | ||
URL: https://github.com/KyleGospo/system76-scheduler | ||
|
||
VCS: {{{ git_dir_vcs }}} | ||
Source: {{{ git_dir_pack }}} | ||
|
||
# Realtime priority if bcc-tools is installed. Not available on OpenMandriva. | ||
%if ! 0%{?mdkversion} | ||
Requires: bcc-tools | ||
%endif | ||
|
||
# No just package on EPEL, OpenSUSE, or OpenMandriva | ||
%{?fedora:BuildRequires: just} | ||
BuildRequires: rust | ||
BuildRequires: cargo | ||
BuildRequires: pipewire-devel | ||
BuildRequires: llvm-devel | ||
BuildRequires: clang-libs | ||
BuildRequires: clang-devel | ||
BuildRequires: systemd-rpm-macros | ||
# Required packages to build just on OpenMandriva | ||
%if 0%{?mdkversion} | ||
BuildRequires: glibc-devel | ||
BuildRequires: glibc-static-devel | ||
%endif | ||
|
||
%description | ||
Scheduling service which optimizes Linux's CPU scheduler and automatically assigns process priorities for improved desktop responsiveness. Low latency CPU scheduling will be activated automatically when on AC, and the default scheduling latencies set on battery. Processes are regularly sweeped and assigned process priorities based on configuration files. When combined with a supported desktop environment, foreground processes and their sub-processes will be given higher process priority. | ||
|
||
These changes result in a noticeable improvement in the experienced smoothness and performance of applications and games. The improved responsiveness of applications is most noticeable on older systems with budget hardware, whereas games will benefit from higher framerates and reduced jitter. This is because background applications and services will be given a smaller portion of leftover CPU budget after the active process has had the most time on the CPU. | ||
|
||
# Disable debug packages | ||
%define debug_package %{nil} | ||
%if 0%{?mdkversion} | ||
# FIXME this is a workaround for some debug files being created on OpenMandriva despite debug_package being set to %{nil} | ||
%define _unpackaged_files_terminate_build 0 | ||
%endif | ||
|
||
# Set path to just | ||
%if ! 0%{?fedora} | ||
# Cargo install path on EPEL, OpenSUSE, or OpenMandriva | ||
%define justpath /builddir/.cargo/bin/just | ||
%else | ||
%define justpath just | ||
%endif | ||
|
||
%prep | ||
{{{ git_dir_setup_macro }}} | ||
|
||
# This will invoke `just` command in the directory with the extracted sources. | ||
%build | ||
%if ! 0%{?fedora} | ||
cargo install just | ||
%endif | ||
%{justpath} execsnoop=/usr/share/bcc/tools/execsnoop build-release | ||
|
||
# This will copy the files generated by the `just` command above into | ||
# the installable rpm package. | ||
%install | ||
%{justpath} rootdir=%{buildroot} unitdir=%{_unitdir} sysconfdir=%{_sysconfdir} install | ||
|
||
# Do post-installation | ||
%post | ||
%systemd_post com.system76.Scheduler.service | ||
|
||
# Do before uninstallation | ||
%preun | ||
%systemd_preun com.system76.Scheduler.service | ||
|
||
# Do after uninstallation | ||
%postun | ||
%systemd_postun_with_restart com.system76.Scheduler.service | ||
|
||
# This lists all the files that are included in the rpm package and that | ||
# are going to be installed into target system where the rpm is installed. | ||
%files | ||
%license LICENSE | ||
%doc README.md | ||
%{_bindir}/system76-scheduler | ||
%{_sysconfdir}/system76-scheduler/config.kdl | ||
%{_sysconfdir}/system76-scheduler/process-scheduler/fedora.kdl | ||
%{_unitdir}/com.system76.Scheduler.service | ||
%{_sysconfdir}/dbus-1/system.d/com.system76.Scheduler.conf | ||
|
||
# Finally, changes from the latest release of your application are generated from | ||
# your project's Git history. It will be empty until you make first annotated Git tag. | ||
%changelog | ||
{{{ git_dir_changelog }}} |