Skip to content
Snippets Groups Projects
Commit ad918898 authored by Dan Denkijin's avatar Dan Denkijin
Browse files

initial commit, version 0.11.0 no systemd

parents
No related branches found
No related tags found
No related merge requests found
trunk/pkg/
trunk/src/
trunk/*.pkg.tar.xz
trunk/*.pkg.tar.xz.sig
stages:
- build
- deploy
- request
before_script:
- cp ./pacman.conf /etc/pacman.conf.builder
package:
stage: build
script:
- pkg-prepare.sh
- pkg-build.sh
artifacts:
name: $CI_PROJECT_NAME-$CI_COMMIT_SHORT_SHA
paths:
- "*.pkg.tar.xz"
only:
- tags
deploy:
stage: deploy
dependencies:
- package
script:
- pkg-deploy.sh
only:
- tags
request:
stage: build
script:
- pkg-build.sh
only:
- merge_requests
README.md 0 → 100644
# Template for Building a Package
This template is designed for building packages and can only be used in the `obcommunity` repository. If you intend to add a package to `obcore` or `obextra`, please use the [prototype-apkg](https://git.obarun.org/pkg/prototype-apkg) repository instead. In this guide, we'll use the `conky` package as an example, but feel free to replace it with the package you need.
# Installation for a New Project
## Create a clone
Begin by making a clone of this [repository](https://git.obarun.org/pkg/prototype-pkg)
```
git clone https://git.obarun.org/pkg/prototype-pkg
```
Rename the directory to conky and navigate inside it
```
mv prototype-pkg conky
cd conky
```
Delete the .git directory
```
rm -rf .git
```
Initialize a fresh Git repository
```
git init --initial-branch=master
```
## Configure the git remote origin
We need to define the remote origin of the repository
```
git remote add origin ssh://git@git.obarun.org:22023/pkg/obcommunity/conky.git
```
If you prefer using HTTPS instead of SSH, replace the address with
```
git remote add origin https://git.obarun.org/pkg/obcommunity/conky.git
```
## Update the `trunk` directory
The scripts used to build the project expect to find the `PKGBUILD` and necessary files in the trunk directory. Therefore, edit the `PKGBUILD` file to fit your project's requirements, along with other files like patches and installation files. Typically, you can find these files on the [Archlinux](https://gitlab.archlinux.org/archlinux/packaging/packages/conky) GitLab instance.
## Adding, committing and pushing your changes
Check the status of your repository
```
git status
```
Next, add your changes
```
git add .
```
Commit your changes with an informative message
```
git commit -m"upgrade: 1.2.6-2"
```
Finally, push your changes to the remote repository
```
git push --set-upstream origin master
```
## Make the project publicly accessible
Make sure that the project is publicly accessible. To do so:
Connect to [`gitlab`](https://git.obarun.org) obarun instance.
- On the left sidebar, select **Search or go to** and find your project.
- Select **Settings** > **General**.
- Expand **Visibility, project features, permissions**
- Under **Project visibility** pick **public** at drop-down menu.
## Triggering the Runner with Tags
The `runner` responsible for building the package is activated only when you push tags. You are free to make changes and commit to the repository without triggering the runner, as long as you haven't pushed a tag.
To trigger the runner, create an annotated tag with the following commands
```
git tag -am"1.2.6-2" 1.2.6-2
```
Then, push the tag along with your changes using the following command
```
git push --follow-tags
```
[options]
HoldPkg = pacman glibc
Architecture = x86_64
IgnorePkg = systemd systemd-libs
CheckSpace
ParallelDownloads = 5
SigLevel = Required
LocalFileSigLevel = Optional
[obcore]
Server = https://cloud.server.obarun.org/$repo/os/$arch/
[obextra]
Server = https://cloud.server.obarun.org/$repo/os/$arch/
[obcommunity]
SigLevel = DatabaseOptional
Server = https://cloud.server.obarun.org/$repo/os/$arch/
[observice]
Server = https://cloud.server.obarun.org/$repo/os/$arch/
[core]
SigLevel = DatabaseOptional
Include = /etc/pacman.d/mirrorlist
[extra]
SigLevel = DatabaseOptional
Include = /etc/pacman.d/mirrorlist
--- a/meson_options.txt 2024-09-13 03:51:11.000000000 -0400
+++ b/meson_options.txt 2024-09-30 08:53:46.117843899 -0400
@@ -7,15 +7,15 @@
option('upower_glib', type: 'feature', value: 'auto', description: 'Enable support for upower')
option('pipewire', type: 'feature', value: 'auto', description: 'Enable support for pipewire')
option('mpris', type: 'feature', value: 'auto', description: 'Enable support for mpris')
-option('systemd', type: 'feature', value: 'auto', description: 'Install systemd user service unit')
+option('systemd', type: 'feature', value: 'disabled', description: 'Install systemd user service unit')
option('dbusmenu-gtk', type: 'feature', value: 'auto', description: 'Enable support for tray')
option('man-pages', type: 'feature', value: 'auto', description: 'Generate and install man pages')
option('mpd', type: 'feature', value: 'auto', description: 'Enable support for the Music Player Daemon')
option('rfkill', type: 'feature', value: 'auto', description: 'Enable support for RFKILL')
option('sndio', type: 'feature', value: 'auto', description: 'Enable support for sndio')
-option('logind', type: 'feature', value: 'auto', description: 'Enable support for logind')
+option('logind', type: 'feature', value: 'disabled', description: 'Enable support for logind')
option('tests', type: 'feature', value: 'auto', description: 'Enable tests')
-option('experimental', type : 'boolean', value : false, description: 'Enable experimental features')
+option('experimental', type : 'boolean', value :true, description: 'Enable experimental features')
option('jack', type: 'feature', value: 'auto', description: 'Enable support for JACK')
option('wireplumber', type: 'feature', value: 'auto', description: 'Enable support for WirePlumber')
option('cava', type: 'feature', value: 'auto', description: 'Enable support for Cava')
# Maintainer: Brett Cornwall <ainola@archlinux.org>
# Maintainer: Robin Candau <antiz@archlinux.org>
# Contributor: Maxim Baz <archlinux at maximbaz dot com>
# Contributor: Parmjot Singh <parmjotsinghrobot at gmail dot com>
pkgname=waybar
pkgver=0.11.0
pkgrel=4
pkgdesc='Highly customizable Wayland bar for Wl compositors, no systemd build, with cava enabled'
arch=('x86_64')
url="https://github.com/Alexays/Waybar/"
license=('MIT')
depends=(
'atkmm'
'cairomm'
'fmt'
'gcc-libs'
'glib2'
'glibc'
'glibmm'
'gtk-layer-shell'
'gtk3'
'gtkmm3'
'jack'
'jsoncpp'
'libdbusmenu-gtk3'
'libevdev'
'libinput'
'libmpdclient'
'libnl'
'libpipewire'
'libpulse'
'libsigc++'
'libwireplumber'
'libxkbcommon'
'playerctl'
'sndio'
'spdlog'
#'systemd-libs'
'upower'
'wayland'
#'cava'
)
makedepends=(
'catch2'
'cmake'
'meson'
'iniparser' # for cava
'glib2-devel' # gdbus-codegen
'scdoc' # For generating manpages
'wayland-protocols'
)
backup=(
etc/xdg/waybar/config.jsonc
etc/xdg/waybar/style.css
)
optdepends=(
'otf-font-awesome: Icons in the default configuration'
)
source=(
"$pkgname-$pkgver.tar.gz::https://github.com/Alexays/Waybar/archive/$pkgver.tar.gz"
"fix-systray.patch::https://github.com/Alexays/Waybar/commit/0d02f6877d88551ea2be0cd151c1e6354e208b1c.patch"
"0001_meson_options_disable_systemd.patch"
)
b2sums=('f2407335e00f02cbf946d95cfcd409dd148917839fd73d52bec1a0c77e041022e81ad7efcde2bd4394356d92686a25b2ca345319fee5ac393202a483db339f93'
'e99cdecc0736ba8e424caa70aca552acb34cec38b3be0952d73b6cd6b04b3b8161387d9798b088440a9effc0ae059fbbd310b372f3bfccb197f8c5888c550367'
'46cc0be77ca493b2f91022a0b5e543054b63594e6d6a8c41f57961c4ed8bd17d6f999b2b78d0e0a8e145af31c68c9e59342a3ad66d7d593d75dc928778466bfe')
prepare() {
cd "Waybar-$pkgver"
# Temporary patch to fix system tray
# See https://github.com/Alexays/Waybar/issues/3597
patch -p1 < "${srcdir}/fix-systray.patch"
# patch to disable systemd
patch -p1 < "${srcdir}/0001_meson_options_disable_systemd.patch"
}
build() {
cd "Waybar-$pkgver"
meson --prefix=/usr \
--buildtype=plain \
--auto-features=enabled \
--wrap-mode=default \
-Dcpp_std=c++20 \
-Dexperimental=true \
-Dcava=disabled \
-Dtests=enabled \
build
meson compile -C build
}
check() {
cd "Waybar-$pkgver"
meson test -C build --print-errorlogs --no-rebuild --suite waybar
}
package() {
depends+=(
'libatkmm-1.6.so'
'libcairomm-1.0.so'
'libgtk-3.so'
'libjack.so'
'libjsoncpp.so'
'libpipewire-0.3.so'
'libsndio.so'
'libspdlog.so'
'libudev.so'
'libupower-glib.so'
)
cd "Waybar-$pkgver"
meson install -C build --destdir "$pkgdir"
install -Dm644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname/"
}
From f60c291b82181b6e871b4807625fbcc7818d3c36 Mon Sep 17 00:00:00 2001
From: Aleksei Bavshin <alebastr89@gmail.com>
Date: Sat, 14 Sep 2024 07:36:23 -0700
Subject: [PATCH 1/2] chore: update fmt wrap to 11.0.2
---
subprojects/fmt.wrap | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/subprojects/fmt.wrap b/subprojects/fmt.wrap
index 42b615963..fd508477f 100644
--- a/subprojects/fmt.wrap
+++ b/subprojects/fmt.wrap
@@ -1,13 +1,13 @@
[wrap-file]
-directory = fmt-11.0.1
-source_url = https://github.com/fmtlib/fmt/archive/11.0.1.tar.gz
-source_filename = fmt-11.0.1.tar.gz
-source_hash = 7d009f7f89ac84c0a83f79ed602463d092fbf66763766a907c97fd02b100f5e9
-patch_filename = fmt_11.0.1-1_patch.zip
-patch_url = https://wrapdb.mesonbuild.com/v2/fmt_11.0.1-1/get_patch
-patch_hash = 0a8b93d1ee6d84a82d3872a9bfb4c3977d8a53f7f484d42d1f7ed63ed496d549
-source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/fmt_11.0.1-1/fmt-11.0.1.tar.gz
-wrapdb_version = 11.0.1-1
+directory = fmt-11.0.2
+source_url = https://github.com/fmtlib/fmt/archive/11.0.2.tar.gz
+source_filename = fmt-11.0.2.tar.gz
+source_hash = 6cb1e6d37bdcb756dbbe59be438790db409cdb4868c66e888d5df9f13f7c027f
+patch_filename = fmt_11.0.2-1_patch.zip
+patch_url = https://wrapdb.mesonbuild.com/v2/fmt_11.0.2-1/get_patch
+patch_hash = 90c9e3b8e8f29713d40ca949f6f93ad115d78d7fb921064112bc6179e6427c5e
+source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/fmt_11.0.2-1/fmt-11.0.2.tar.gz
+wrapdb_version = 11.0.2-1
[provide]
fmt = fmt_dep
From 0006e4713ae19776528038b3242ded05db884ba5 Mon Sep 17 00:00:00 2001
From: Aleksei Bavshin <alebastr89@gmail.com>
Date: Sat, 14 Sep 2024 07:37:37 -0700
Subject: [PATCH 2/2] fix(tray): revert ustring formatting changes
This reverts commit a4d31ab10d1630cb9104c695d7b777ca12468904.
---
src/modules/sni/item.cpp | 23 +++++++++--------------
1 file changed, 9 insertions(+), 14 deletions(-)
diff --git a/src/modules/sni/item.cpp b/src/modules/sni/item.cpp
index 8afb39fb3..6c4ec8c06 100644
--- a/src/modules/sni/item.cpp
+++ b/src/modules/sni/item.cpp
@@ -104,11 +104,9 @@ void Item::proxyReady(Glib::RefPtr<Gio::AsyncResult>& result) {
this->updateImage();
} catch (const Glib::Error& err) {
- spdlog::error("Failed to create DBus Proxy for {} {}: {}", bus_name, object_path,
- std::string(err.what()));
+ spdlog::error("Failed to create DBus Proxy for {} {}: {}", bus_name, object_path, err.what());
} catch (const std::exception& err) {
- spdlog::error("Failed to create DBus Proxy for {} {}: {}", bus_name, object_path,
- std::string(err.what()));
+ spdlog::error("Failed to create DBus Proxy for {} {}: {}", bus_name, object_path, err.what());
}
}
@@ -126,15 +124,14 @@ ToolTip get_variant<ToolTip>(const Glib::VariantBase& value) {
result.text = get_variant<Glib::ustring>(container.get_child(2));
auto description = get_variant<Glib::ustring>(container.get_child(3));
if (!description.empty()) {
- result.text = fmt::format("<b>{}</b>\n{}", std::string(result.text), std::string(description));
+ result.text = fmt::format("<b>{}</b>\n{}", result.text, description);
}
return result;
}
void Item::setProperty(const Glib::ustring& name, Glib::VariantBase& value) {
try {
- spdlog::trace("Set tray item property: {}.{} = {}", id.empty() ? bus_name : id,
- std::string(name), get_variant<std::string>(value));
+ spdlog::trace("Set tray item property: {}.{} = {}", id.empty() ? bus_name : id, name, value);
if (name == "Category") {
category = get_variant<std::string>(value);
@@ -179,12 +176,10 @@ void Item::setProperty(const Glib::ustring& name, Glib::VariantBase& value) {
}
} catch (const Glib::Error& err) {
spdlog::warn("Failed to set tray item property: {}.{}, value = {}, err = {}",
- id.empty() ? bus_name : id, std::string(name), get_variant<std::string>(value),
- std::string(err.what()));
+ id.empty() ? bus_name : id, name, value, err.what());
} catch (const std::exception& err) {
spdlog::warn("Failed to set tray item property: {}.{}, value = {}, err = {}",
- id.empty() ? bus_name : id, std::string(name), get_variant<std::string>(value),
- std::string(err.what()));
+ id.empty() ? bus_name : id, name, value, err.what());
}
}
@@ -226,9 +221,9 @@ void Item::processUpdatedProperties(Glib::RefPtr<Gio::AsyncResult>& _result) {
this->updateImage();
} catch (const Glib::Error& err) {
- spdlog::warn("Failed to update properties: {}", std::string(err.what()));
+ spdlog::warn("Failed to update properties: {}", err.what());
} catch (const std::exception& err) {
- spdlog::warn("Failed to update properties: {}", std::string(err.what()));
+ spdlog::warn("Failed to update properties: {}", err.what());
}
update_pending_.clear();
}
@@ -250,7 +245,7 @@ static const std::map<std::string_view, std::set<std::string_view>> signal2props
void Item::onSignal(const Glib::ustring& sender_name, const Glib::ustring& signal_name,
const Glib::VariantContainerBase& arguments) {
- spdlog::trace("Tray item '{}' got signal {}", id, std::string(signal_name));
+ spdlog::trace("Tray item '{}' got signal {}", id, signal_name);
auto changed = signal2props.find(signal_name.raw());
if (changed != signal2props.end()) {
if (update_pending_.empty()) {
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment