diff options
author | Kacper Kowalik <xarthisius@gentoo.org> | 2011-07-12 13:06:07 +0000 |
---|---|---|
committer | Kacper Kowalik <xarthisius@gentoo.org> | 2011-07-12 13:06:07 +0000 |
commit | 0f7fd1a7183819dbfedd35f7fbf96280d1960079 (patch) | |
tree | e3147ef4e7752fe60405e8e4938e2bdcd07e84e2 /x11-wm/i3 | |
parent | x86 stable per bug 367039 (diff) | |
download | gentoo-2-0f7fd1a7183819dbfedd35f7fbf96280d1960079.tar.gz gentoo-2-0f7fd1a7183819dbfedd35f7fbf96280d1960079.tar.bz2 gentoo-2-0f7fd1a7183819dbfedd35f7fbf96280d1960079.zip |
Initial import. Ebuild based on extensive work done by Ondrej Sukup (mimi_vx) <mimi.vx@gmail.com> and Andre-Patrick Bubel (moredread) <code@andre-bubel.de> in sunrise overlay. Fixes bug 267476
(Portage version: 2.2.0_alpha43/cvs/Linux x86_64)
Diffstat (limited to 'x11-wm/i3')
-rw-r--r-- | x11-wm/i3/ChangeLog | 12 | ||||
-rw-r--r-- | x11-wm/i3/files/i3-gentoo.diff | 175 | ||||
-rw-r--r-- | x11-wm/i3/i3-3e_p3.ebuild | 52 | ||||
-rw-r--r-- | x11-wm/i3/metadata.xml | 9 |
4 files changed, 248 insertions, 0 deletions
diff --git a/x11-wm/i3/ChangeLog b/x11-wm/i3/ChangeLog new file mode 100644 index 000000000000..f12acfc014e9 --- /dev/null +++ b/x11-wm/i3/ChangeLog @@ -0,0 +1,12 @@ +# ChangeLog for x11-wm/i3 +# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/x11-wm/i3/ChangeLog,v 1.1 2011/07/12 13:06:07 xarthisius Exp $ + +*i3-3e_p3 (12 Jul 2011) + + 12 Jul 2011; Kacper Kowalik <xarthisius@gentoo.org> +files/i3-gentoo.diff, + +i3-3e_p3.ebuild, +metadata.xml: + Initial import. Ebuild based on extensive work done by Ondrej Sukup (mimi_vx) + <mimi.vx@gmail.com> and Andre-Patrick Bubel (moredread) <code@andre-bubel.de> + in sunrise overlay. Fixes bug 267476 + diff --git a/x11-wm/i3/files/i3-gentoo.diff b/x11-wm/i3/files/i3-gentoo.diff new file mode 100644 index 000000000000..003707e96190 --- /dev/null +++ b/x11-wm/i3/files/i3-gentoo.diff @@ -0,0 +1,175 @@ +--- common.mk ++++ common.mk +@@ -1,5 +1,5 @@ + UNAME=$(shell uname) +-DEBUG=1 ++DEBUG=0 + INSTALL=install + PREFIX=/usr + ifeq ($(PREFIX),/usr) +@@ -17,8 +17,7 @@ + # We don’t want unused-parameter because of the use of many callbacks + CFLAGS += -Wunused-value + CFLAGS += -Iinclude +-CFLAGS += -I/usr/local/include +-CFLAGS += -DI3_VERSION=\"${GIT_VERSION}\" ++CPPFLAGS += -DI3_VERSION=\"${GIT_VERSION}\" + + # Check if pkg-config is installed, because without pkg-config, the following + # check for the version of libxcb cannot be done. +@@ -33,27 +32,17 @@ + ifeq ($(shell pkg-config --exact-version=0.3.3 xcb-keysyms && echo 1),1) + # xcb-keysyms fixed API from 0.3.3 to 0.3.4, so for some months, we will + # have this here. Distributions should upgrade their libxcb in the meantime. +-CFLAGS += -DOLD_XCB_KEYSYMS_API ++CPPFLAGS += -DOLD_XCB_KEYSYMS_API + endif + +-LDFLAGS += -lm +-LDFLAGS += -lxcb-keysyms + ifeq ($(shell pkg-config --exists xcb-util || echo 1),1) +-CFLAGS += -DXCB_COMPAT +-LDFLAGS += -lxcb-atom +-LDFLAGS += -lxcb-aux +-LDFLAGS += -lxcb-event ++CPPFLAGS += -DXCB_COMPAT ++LIBS += -lxcb-atom -lxcb-aux -lxcb-event + else +-LDFLAGS += -lxcb-util ++LIBS += $(shell pkg-config --libs xcb-util) + endif +-LDFLAGS += -lxcb-icccm +-LDFLAGS += -lxcb-xinerama +-LDFLAGS += -lxcb-randr +-LDFLAGS += -lxcb +-LDFLAGS += -lyajl +-LDFLAGS += -lX11 +-LDFLAGS += -lev +-LDFLAGS += -L/usr/local/lib -L/usr/pkg/lib ++LIBS += $(shell pkg-config --libs xcb-keysyms xcb-icccm xcb-xinerama xcb-randr xcb x11) ++LIBS += -lyajl -lev -lm + + ifeq ($(UNAME),NetBSD) + # We need -idirafter instead of -I to prefer the system’s iconv over GNU libiconv +@@ -63,12 +52,12 @@ + + ifeq ($(UNAME),OpenBSD) + CFLAGS += -I${X11BASE}/include +-LDFLAGS += -liconv ++LIBS += -liconv + LDFLAGS += -L${X11BASE}/lib + endif + + ifeq ($(UNAME),FreeBSD) +-LDFLAGS += -liconv ++LIBS += -liconv + endif + + # Fallback for libyajl 1 which did not include yajl_version.h. We need +@@ -76,20 +65,15 @@ + CFLAGS += -idirafter yajl-fallback + + ifneq (,$(filter Linux GNU GNU/%, $(UNAME))) +-CFLAGS += -D_GNU_SOURCE ++CPPFLAGS += -D_GNU_SOURCE + endif + + ifeq ($(DEBUG),1) + # Extended debugging flags, macros shall be available in gcc + CFLAGS += -gdwarf-2 + CFLAGS += -g3 +-else +-CFLAGS += -O2 + endif + +-# Don’t print command lines which are run +-.SILENT: +- + # Always remake the following targets + .PHONY: install clean dist distclean + +--- Makefile ++++ Makefile +@@ -20,20 +20,14 @@ + + # Depend on the specific file (.c for each .o) and on all headers + src/%.o: src/%.c ${HEADERS} +- echo "CC $<" +- $(CC) $(CFLAGS) -DLOGLEVEL="(1 << $(shell awk '/$(shell basename $< .c)/ { print NR }' loglevels.tmp))" -c -o $@ $< ++ $(CC) $(CPPFLAGS) $(CFLAGS) -DLOGLEVEL="(1 << $(shell awk '/$(shell basename $< .c)/ { print NR }' loglevels.tmp))" -c -o $@ $< + + all: src/cfgparse.y.o src/cfgparse.yy.o ${FILES} +- echo "LINK i3" +- $(CC) -o i3 ${FILES} src/cfgparse.y.o src/cfgparse.yy.o $(LDFLAGS) +- echo "" +- echo "SUBDIR i3-msg" ++ $(CC) $(LDFLAGS) -o i3 ${FILES} src/cfgparse.y.o src/cfgparse.yy.o $(LIBS) + $(MAKE) TOPDIR=$(TOPDIR) -C i3-msg +- echo "SUBDIR i3-input" + $(MAKE) TOPDIR=$(TOPDIR) -C i3-input + + loglevels.h: +- echo "LOGLEVELS" + for file in $$(ls src/*.c src/*.y src/*.l | grep -v 'cfgparse.\(tab\|yy\).c'); \ + do \ + echo $$(basename $$file .c); \ +@@ -45,17 +39,14 @@ + echo "};") > include/loglevels.h; + + src/cfgparse.yy.o: src/cfgparse.l src/cfgparse.y.o ${HEADERS} +- echo "LEX $<" + flex -i -o$(@:.o=.c) $< +- $(CC) $(CFLAGS) -DLOGLEVEL="(1 << $(shell awk '/cfgparse.l/ { print NR }' loglevels.tmp))" -c -o $@ $(@:.o=.c) ++ $(CC) $(CPPFLAGS) $(CFLAGS) -DLOGLEVEL="(1 << $(shell awk '/cfgparse.l/ { print NR }' loglevels.tmp))" -c -o $@ $(@:.o=.c) + + src/cfgparse.y.o: src/cfgparse.y ${HEADERS} +- echo "YACC $<" + bison --debug --verbose -b $(basename $< .y) -d $< +- $(CC) $(CFLAGS) -DLOGLEVEL="(1 << $(shell awk '/cfgparse.y/ { print NR }' loglevels.tmp))" -c -o $@ $(<:.y=.tab.c) ++ $(CC) $(CPPFLAGS) $(CFLAGS) -DLOGLEVEL="(1 << $(shell awk '/cfgparse.y/ { print NR }' loglevels.tmp))" -c -o $@ $(<:.y=.tab.c) + + install: all +- echo "INSTALL" + $(INSTALL) -d -m 0755 $(DESTDIR)$(PREFIX)/bin + $(INSTALL) -d -m 0755 $(DESTDIR)$(SYSCONFDIR)/i3 + $(INSTALL) -d -m 0755 $(DESTDIR)$(PREFIX)/include/i3 +--- i3-msg/Makefile ++++ i3-msg/Makefile +@@ -11,15 +11,12 @@ + + # Depend on the specific file (.c for each .o) and on all headers + %.o: %.c ${HEADERS} +- echo "CC $<" +- $(CC) $(CFLAGS) -c -o $@ $< ++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $< + + all: ${FILES} +- echo "LINK i3-msg" +- $(CC) -o i3-msg ${FILES} $(LDFLAGS) ++ $(CC) $(LDFLAGS) -o i3-msg ${FILES} $(LIBS) + + install: all +- echo "INSTALL" + $(INSTALL) -d -m 0755 $(DESTDIR)$(PREFIX)/bin + $(INSTALL) -m 0755 i3-msg $(DESTDIR)$(PREFIX)/bin/ + +--- i3-input/Makefile ++++ i3-input/Makefile +@@ -9,15 +9,12 @@ + + # Depend on the specific file (.c for each .o) and on all headers + %.o: %.c ${HEADERS} +- echo "CC $<" +- $(CC) $(CFLAGS) -c -o $@ $< ++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $< + + all: ${FILES} +- echo "LINK i3-input" +- $(CC) -o i3-input ${FILES} $(LDFLAGS) ++ $(CC) $(LDFLAGS) -o i3-input ${FILES} $(LIBS) + + install: all +- echo "INSTALL" + $(INSTALL) -d -m 0755 $(DESTDIR)$(PREFIX)/bin + $(INSTALL) -m 0755 i3-input $(DESTDIR)$(PREFIX)/bin/ + diff --git a/x11-wm/i3/i3-3e_p3.ebuild b/x11-wm/i3/i3-3e_p3.ebuild new file mode 100644 index 000000000000..de032375f01c --- /dev/null +++ b/x11-wm/i3/i3-3e_p3.ebuild @@ -0,0 +1,52 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/x11-wm/i3/i3-3e_p3.ebuild,v 1.1 2011/07/12 13:06:07 xarthisius Exp $ + +EAPI=4 + +inherit base versionator toolchain-funcs + +MY_PV=$(version_format_string '$1.$2-${3/p/bf}') +MY_P=${PN}-${MY_PV} + +DESCRIPTION="An improved dynamic tiling window manager" +HOMEPAGE="http://i3wm.org/" +SRC_URI="http://i3wm.org/downloads/${MY_P}.tar.bz2" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="" + +CDEPEND="dev-libs/libev + dev-libs/yajl + x11-libs/libxcb + x11-libs/libX11 + x11-libs/xcb-util" +DEPEND="${CDEPEND} + sys-devel/flex + sys-devel/bison + x11-proto/xcb-proto" +RDEPEND="${CDEPEND} + x11-apps/xmessage" + +S=${WORKDIR}/${MY_P} + +DOCS=( GOALS TODO RELEASE-NOTES-${MY_PV} ) +PATCHES=( "${FILESDIR}"/${PN}-gentoo.diff ) + +pkg_setup() { + tc-export CC +} + +src_install() { + base_src_install + doman man/*.1 + dohtml -r docs/* +} + +pkg_postinst() { + elog "${PN} by default uses x11-terms/rxvt-unicode as a default terminal." + elog "Either merge it yourself or change proper bind in /etc/${PN}/config" + elog "or ~/.i3/config" +} diff --git a/x11-wm/i3/metadata.xml b/x11-wm/i3/metadata.xml new file mode 100644 index 000000000000..2cb4afce85c5 --- /dev/null +++ b/x11-wm/i3/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>desktop-wm</herd> + <maintainer> + <email>xarthisius@gentoo.org</email> + <name>Kacper Kowalik</name> + </maintainer> +</pkgmetadata> |