summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicholas George2021-01-06 16:45:02 -0600
committerNicholas George2021-01-06 16:45:02 -0600
commit783c282d996dfb73eb0f801912e475495d8d0859 (patch)
tree3500276910a1351d62e340a5661a9e75abb253cb
downloadaur-783c282d996dfb73eb0f801912e475495d8d0859.tar.gz
Initial submit
-rw-r--r--.SRCINFO21
-rw-r--r--PKGBUILD47
-rwxr-xr-xcchat-gtk.desktop8
3 files changed, 76 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..c70463705439
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,21 @@
+pkgbase = cchat-gtk-git
+ pkgdesc = Gtk frontend for cchat.
+ pkgver = r122.9cb3f71
+ pkgrel = 1
+ url = https://github.com/diamondburned/cchat-gtk
+ arch = any
+ license = GPL3
+ makedepends = git
+ makedepends = go
+ depends = gtk3
+ depends = discordlogin-git
+ depends = libhandy0
+ provides = cchat
+ conflicts = cchat
+ source = git+https://github.com/diamondburned/cchat-gtk
+ source = cchat-gtk.desktop
+ sha256sums = SKIP
+ sha256sums = 429790014af6dc2575dbcaf100008f9abdaf366553cc8665730e4c521018799f
+
+pkgname = cchat-gtk-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..305a429c4805
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,47 @@
+pkgname=cchat-gtk-git
+_pkgname=cchat-gtk
+pkgver=r122.9cb3f71
+pkgrel=1
+pkgdesc='Gtk frontend for cchat.'
+arch=('any')
+url='https://github.com/diamondburned/cchat-gtk'
+license=('GPL3')
+depends=('gtk3' 'discordlogin-git' 'libhandy0')
+provides=('cchat')
+conflicts=('cchat')
+# Maintainer: Nicholas George <vencorr@zoho.com>
+makedepends=('git' 'go')
+source=('git+https://github.com/diamondburned/cchat-gtk'
+ 'cchat-gtk.desktop')
+sha256sums=('SKIP'
+ '429790014af6dc2575dbcaf100008f9abdaf366553cc8665730e4c521018799f')
+
+pkgver() {
+ cd "$_pkgname"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+build() {
+ # add config flags as per https://wiki.archlinux.org/index.php/Go_package_guidelines
+ export CGO_CPPFLAGS="${CPPFLAGS}"
+ export CGO_CFLAGS="${CFLAGS}"
+ export CGO_CXXFLAGS="${CXXFLAGS}"
+ export CGO_LDFLAGS="${LDFLAGS}"
+ export GOFLAGS="-buildmode=pie -trimpath -modcacherw"
+
+ # check if user has already set their GoLang path
+ if [[ -z "${GOPATH}" ]]; then
+ export GOPATH="${srcdir}/go"
+ fi
+ cd "$_pkgname"
+ go build -trimpath
+}
+
+package() {
+ cd "$_pkgname"
+ install -Dm755 "$_pkgname" "$pkgdir/usr/bin/$_pkgname"
+ install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$_pkgname/LICENSE"
+ install -Dm644 "$srcdir/$_pkgname.desktop" "$pkgdir/usr/share/applications/$_pkgname.desktop"
+ install -Dm644 icons/cchat_256.png "$pkgdir/usr/share/icons/hicolor/256x256/apps/cchat-gtk.png"
+}
+
diff --git a/cchat-gtk.desktop b/cchat-gtk.desktop
new file mode 100755
index 000000000000..5bda2a5f821e
--- /dev/null
+++ b/cchat-gtk.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Name=cchat
+Comment=Gtk frontend for cchat.
+Exec=cchat-gtk
+Icon=cchat-gtk
+Terminal=false
+Type=Application
+Categories=Network;InstantMessaging;P2P;