diff options
-rw-r--r-- | .SRCINFO | 21 | ||||
-rw-r--r-- | PKGBUILD | 40 | ||||
-rw-r--r-- | gsimplecal-lunar-2.1.patch | 56 |
3 files changed, 117 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..3557e738aad3 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,21 @@ +# Generated by mksrcinfo v8 +# Sun Feb 21 07:34:42 UTC 2016 +pkgbase = gsimplecal-lunar + pkgdesc = Simple and lightweight GTK calendar with lunar calendar patch + pkgver = 2.1 + pkgrel = 2 + url = http://dmedvinsky.github.com/gsimplecal + arch = i686 + arch = x86_64 + license = BSD + depends = gtk3 + depends = lunar-calendar + provides = gsimplecal + conflicts = gsimplecal + source = gsimplecal-2.1.tar.gz::https://github.com/dmedvinsky/gsimplecal/archive/v2.1.tar.gz + source = gsimplecal-lunar-2.1.patch + md5sums = 170ac0bdc8663d97dec436e45b195491 + md5sums = SKIP + +pkgname = gsimplecal-lunar + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..08f722ac4df9 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,40 @@ +# Maintainer: zlsun <zlsun1995 at gmail dot com> +# Contributor: Jonathan Steel <jsteel at archlinux.org> +# Contributor: DrZaius <lou at fakeoutdoorsman dot com> +# Contributor: Victor Feight <vrfeight3 at gmail dot com> + +pkgname=gsimplecal-lunar +_pkgname=gsimplecal +pkgver=2.1 +pkgrel=2 +pkgdesc="Simple and lightweight GTK calendar with lunar calendar patch" +arch=('i686' 'x86_64') +url="http://dmedvinsky.github.com/$_pkgname" +license=('BSD') +depends=('gtk3' 'lunar-calendar') +conflicts=('gsimplecal') +provides=('gsimplecal') +_lunar_patch="$pkgname-$pkgver.patch" +source=("$_pkgname-$pkgver.tar.gz::https://github.com/dmedvinsky/$_pkgname/archive/v$pkgver.tar.gz" + $_lunar_patch) +md5sums=('170ac0bdc8663d97dec436e45b195491' + 'SKIP') + +prepare() { + cd "$_pkgname-$pkgver" + patch -p1 -i "$srcdir/$_lunar_patch" +} + +build() { + cd $_pkgname-$pkgver + ./autogen.sh + ./configure --prefix=/usr + make +} + +package() { + cd $_pkgname-$pkgver + make DESTDIR="$pkgdir" install + install -Dm644 COPYING "$pkgdir"/usr/share/licenses/$_pkgname/COPYING +} + diff --git a/gsimplecal-lunar-2.1.patch b/gsimplecal-lunar-2.1.patch new file mode 100644 index 000000000000..10df413de15c --- /dev/null +++ b/gsimplecal-lunar-2.1.patch @@ -0,0 +1,56 @@ +diff --git a/configure.ac b/configure.ac +index 957d231..5cc0c7e 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -47,6 +47,11 @@ PKG_CHECK_MODULES(GTK, [$GTK_VERSION]) + AC_SUBST(GTK_CFLAGS) + AC_SUBST(GTK_LIBS) + ++AM_COND_IF([ENABLE_GTK2], ++ [PKG_CHECK_MODULES(LUNAR_CALENDAR, [lunar-calendar-2.0 >= 2.4.1])], ++ [PKG_CHECK_MODULES(LUNAR_CALENDAR, [lunar-calendar-3.0 >= 3.0.0])]) ++AC_SUBST(LUNAR_CALENDAR_CFLAGS) ++AC_SUBST(LUNAR_CALENDAR_LIBS) + + # Checks for header files. + AC_CHECK_HEADERS([iostream \ +diff --git a/src/Calendar.cpp b/src/Calendar.cpp +index 285390a..c754d19 100644 +--- a/src/Calendar.cpp ++++ b/src/Calendar.cpp +@@ -2,6 +2,7 @@ + #include <sys/time.h> + + #include <gtk/gtk.h> ++#include <lunar-calendar/lunar-calendar.h> + + #include "Calendar.hpp" + #include "Config.hpp" +@@ -33,13 +34,13 @@ void dayDoubleClickCb(GtkCalendar *calendar, gpointer cls) + + Calendar::Calendar() + { +- widget = gtk_calendar_new(); ++ widget = lunar_calendar_new(); + + Config* config = Config::getInstance(); + g_object_set(widget, + "show-heading", true, + "show-day-names", true, +- "show-details", false, ++ "show-details", true, + "show-week-numbers", config->show_week_numbers, + NULL); + // Store today date to be able to jump to it. +diff --git a/src/Makefile.am b/src/Makefile.am +index fcf4357..7019835 100644 +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -1,5 +1,5 @@ +-AM_CPPFLAGS = @GTK_CFLAGS@ +-LIBS = @GTK_LIBS@ ++AM_CPPFLAGS = @GTK_CFLAGS@ @LUNAR_CALENDAR_CFLAGS@ ++LIBS = @GTK_LIBS@ @LUNAR_CALENDAR_LIBS@ + + bin_PROGRAMS = gsimplecal + gsimplecal_SOURCES = \ |