summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO18
-rw-r--r--Dockerfile13
-rw-r--r--PKGBUILD39
-rw-r--r--makepngs.sh27
4 files changed, 82 insertions, 15 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 9740bb1c80b5..81bd89f678e0 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,6 @@
pkgbase = adwaita-custom-cursor-colors
pkgdesc = GNOME's Adwaita Theme with Customizable Cursor Colors
- pkgver = 3.36.0
+ pkgver = 43
pkgrel = 1
url = https://git.gnome.org/browse/adwaita-icon-theme
arch = any
@@ -10,17 +10,19 @@ pkgbase = adwaita-custom-cursor-colors
makedepends = git
makedepends = gtk3
makedepends = gnome-common
- makedepends = python2
- makedepends = python2-pillow
- makedepends = inkscape
- makedepends = xorg-xcursorgen
+ makedepends = docker
depends = hicolor-icon-theme
depends = gtk-update-icon-cache
depends = librsvg
provides = adwaita-icon-theme
+ provides = adwaita-cursors
conflicts = adwaita-icon-theme
- source = https://github.com/GNOME/adwaita-icon-theme/archive/3.36.0.tar.gz
- sha256sums = 813a094e60c375e7ed527ef5f3c02adbeab086b5b7b64a7bda6b2aa9fd4dadf4
+ conflicts = adwaita-cursors
+ source = https://github.com/GNOME/adwaita-icon-theme/archive/43.tar.gz
+ source = Dockerfile
+ source = makepngs.sh
+ sha256sums = 15c635c227f85d78121841e40815ed5277c7580c9c80e01f1613a807d931b4c1
+ sha256sums = SKIP
+ sha256sums = SKIP
pkgname = adwaita-custom-cursor-colors
-
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 000000000000..2364e1c93bdc
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,13 @@
+FROM debian:oldstable
+
+RUN apt-get -y update
+RUN apt-get -y install python2 inkscape wget
+RUN wget https://bootstrap.pypa.io/pip/2.7/get-pip.py
+RUN python2 get-pip.py
+RUN python2 -m pip install pillow
+
+WORKDIR /app/src/cursors
+
+COPY ./makepngs.sh /
+
+ENTRYPOINT bash /makepngs.sh
diff --git a/PKGBUILD b/PKGBUILD
index 6bb64bf49ef7..8e30400b854d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,22 +2,46 @@
# Contributor: Lukas Fleischer <lfleischer@archlinux.org>
# Contributor: Jan de Groot <jgc@archlinux.org>
+# NOTE: This is broken with the latest inkscape CLI & you will have to comment
+# out the renderpngs.py script for now, using docker to run the script in a
+# debian environment.
+#
+# Start by extracting & preparing the source files, this command will fail:
+# $ makepkg
+#
+# Run these commands to generate icon PNGs from the base SVG file:
+# $ docker build -t adwaita:latest .
+# $ docker run --mount type=bind,source=./src/adwaita-icon-theme-43,target=/app adwaita
+#
+# Then comment out the ./renderpngs.py line in build() & finish building the
+# package with:
+# $ makepkg --noextract --noprepare --install
+
# To Change the Colors of the Generated Cursor Files, Edit the FILL_COLOR &
# OUTLINE_COLOR Variables in the `build()` Function.
pkgname=adwaita-custom-cursor-colors
-pkgver=3.36.0
+pkgver=43
pkgrel=1
pkgdesc="GNOME's Adwaita Theme with Customizable Cursor Colors"
url="https://git.gnome.org/browse/adwaita-icon-theme"
arch=(any)
license=(LGPL3 CCPL:cc-by-sa)
depends=(hicolor-icon-theme gtk-update-icon-cache librsvg)
-makedepends=(intltool git gtk3 gnome-common python2 python2-pillow inkscape xorg-xcursorgen)
-provides=(adwaita-icon-theme)
-conflicts=(adwaita-icon-theme)
-source=("https://github.com/GNOME/adwaita-icon-theme/archive/$pkgver.tar.gz")
-sha256sums=('813a094e60c375e7ed527ef5f3c02adbeab086b5b7b64a7bda6b2aa9fd4dadf4')
+#makedepends=(intltool git gtk3 gnome-common python python-pillow inkscape xorg-xcursorgen)
+makedepends=(intltool git gtk3 gnome-common docker)
+provides=(adwaita-icon-theme adwaita-cursors)
+conflicts=(adwaita-icon-theme adwaita-cursors)
+source=(
+ "https://github.com/GNOME/adwaita-icon-theme/archive/$pkgver.tar.gz"
+ "Dockerfile"
+ "makepngs.sh"
+)
+sha256sums=(
+ '15c635c227f85d78121841e40815ed5277c7580c9c80e01f1613a807d931b4c1'
+ 'SKIP'
+ 'SKIP'
+)
_sourcefolder="adwaita-icon-theme-$pkgver"
@@ -25,7 +49,7 @@ prepare() {
cd "$_sourcefolder"
autoreconf -fvi
}
-
+
build() {
cd "$_sourcefolder"
@@ -57,6 +81,7 @@ build() {
sed -i "s/${TEMP_VAR}/${OUTLINE_COLOR}/g" adwaita.svg
# Generate PNGs from the SVG
+ # NOTE: This is broken, see comment at top of PKGBUILD
CORE_COUNT="$(grep -c '^core id' /proc/cpuinfo)"
./renderpngs.py -r -s -t -o -m 32 -a -c -n "${CORE_COUNT}" adwaita.svg
diff --git a/makepngs.sh b/makepngs.sh
new file mode 100644
index 000000000000..e6ab353e9550
--- /dev/null
+++ b/makepngs.sh
@@ -0,0 +1,27 @@
+#!/usr/bin/env bash
+
+# Some Colors from the Molokai colorscheme you can pick
+BACKGROUND="#1B1D1E"
+#BLACK="#232526"
+#WHITE="#F8F8F0"
+#RED="#FF0000"
+#ORANGE="#FD971F"
+MAGENTA="#F92672"
+#CYAN="#66D9EF"
+#GREEN="A6E22E"
+
+# Set Desired Filll & Outline Colors
+FILL_COLOR="${MAGENTA}"
+OUTLINE_COLOR="${BACKGROUND}"
+
+TEMP_VAR="42IPROBABLYDONTEXISTINTHESVGFILE9001"
+sed -i -e "s/#ffffff/${TEMP_VAR}/g" \
+ -e "s/#bebebe/${TEMP_VAR}/g" \
+ -e "s/#dedede/${TEMP_VAR}/g" \
+ adwaita.svg
+sed -i -e "s/#000000/${FILL_COLOR}/g" \
+ -e "s/#484848/${FILL_COLOR}/g" \
+ -e "s/#313131/${FILL_COLOR}/g" \
+ adwaita.svg
+sed -i "s/${TEMP_VAR}/${OUTLINE_COLOR}/g" adwaita.svg
+./renderpngs.py -r -s -o -m 32 -a -c -n 1 adwaita.svg