logo

overlay

My (experimental) gentoo overlay
commit: 59624a9adabefd4e6cb800d5623f5d9d3a59ec40
parent: b4b7cf185f6093d3eab4466b353883c56aef2dc9
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Thu, 10 May 2018 23:28:32 +0200

games-arcade/tinymania: New Package

Diffstat:

Agames-arcade/tinymania/files/tinymania-fix-Makefile.patch42++++++++++++++++++++++++++++++++++++++++++
Agames-arcade/tinymania/tinymania-9999.ebuild29+++++++++++++++++++++++++++++
2 files changed, 71 insertions(+), 0 deletions(-)

diff --git a/games-arcade/tinymania/files/tinymania-fix-Makefile.patch b/games-arcade/tinymania/files/tinymania-fix-Makefile.patch @@ -0,0 +1,42 @@ +diff --git a/Makefile b/Makefile +index 739c63f..500e8a0 100644 +--- a/Makefile ++++ b/Makefile +@@ -1,5 +1,6 @@ + # compiler +-CC := g++ ++CXX ?= g++ ++PREFIX ?= /usr/local + + # OS and specific libs + OS := $(shell uname) +@@ -21,23 +23,24 @@ TARGET := tinymania + SRCEXT := cpp + SOURCES := $(shell find $(SRCDIR) -type f -name *.$(SRCEXT)) + OBJECTS := $(patsubst $(SRCDIR)/%,$(BUILDDIR)/%,$(SOURCES:.$(SRCEXT)=.o)) +-CFLAGS := -g -std=c++17 -O3 -Wall -Wextra -pedantic ++CXXFLAGS ?= -g -O3 -Wall -Wextra -pedantic + INC := -I include + + #specify linked libraries + + $(TARGET): $(OBJECTS) + @echo " linking..." +- @echo " $(CC) $^ -o $(TARGET) $(LIB)"; $(CC) $^ -o $(TARGET) $(LIB) ++ $(CXX) $^ -o $(TARGET) $(LIB) + + $(BUILDDIR)/%.o: $(SRCDIR)/%.$(SRCEXT) + @echo " compiling..." + @mkdir -p $(BUILDDIR) +- @echo " $(CC) $(CFLAGS) $(INC) -c -o $@ $<"; $(CC) $(CFLAGS) $(INC) -c -o $@ $< ++ $(CXX) $(CXXFLAGS) -std=c++14 $(INC) -c -o $@ $< + + install: $(TARGET) +- cp tinymania /usr/bin/tinymania ++ mkdir -p $(DESTDIR)$(PREFIX)/bin ++ cp tinymania $(DESTDIR)$(PREFIX)/bin/tinymania + + clean: + @echo " cleaning ..." +- @echo " $(RM) -r $(BUILDDIR) $(TARGET)"; $(RM) -r $(BUILDDIR) $(TARGET) ++ $(RM) -r $(BUILDDIR) $(TARGET) diff --git a/games-arcade/tinymania/tinymania-9999.ebuild b/games-arcade/tinymania/tinymania-9999.ebuild @@ -0,0 +1,29 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit git-r3 eutils + +DESCRIPTION="" +HOMEPAGE="" + +EGIT_REPO_URI="https://git.sakamoto.gq/eal/tinymania.git" + +LICENSE="" +SLOT="0" +KEYWORDS="" +IUSE="" + +DEPEND="media-libs/libsfml" +RDEPEND="${DEPEND}" + +src_prepare() { + default + + epatch "${FILESDIR}/tinymania-fix-Makefile.patch" +} + +src_install() { + emake install DESTDIR="${D}" PREFIX="/usr/games" +}