diff --git a/devel/Makefile b/devel/Makefile index f34201246874..01ec1e25e3eb 100644 --- a/devel/Makefile +++ b/devel/Makefile @@ -4648,6 +4648,7 @@ SUBDIR += scons SUBDIR += sdl12 SUBDIR += sdl20 + SUBDIR += sdl2pp SUBDIR += sdl_console SUBDIR += sdl_gnat SUBDIR += sdl_sge diff --git a/devel/sdl2pp/Makefile b/devel/sdl2pp/Makefile new file mode 100644 index 000000000000..420fd5f3ed52 --- /dev/null +++ b/devel/sdl2pp/Makefile @@ -0,0 +1,41 @@ +# Created by: Dmitry Marakasov +# $FreeBSD$ + +PORTNAME= sdl2pp +PORTVERSION= 0.4.0 +CATEGORIES= devel + +MAINTAINER= amdmi3@FreeBSD.org +COMMENT= C++11 bindings/wrapper for SDL2 + +LICENSE= ZLIB +LICENSE_FILE= ${WRKSRC}/COPYING.txt + +USE_GITHUB= yes +GH_ACCOUNT= AMDmi3 +GH_PROJECT= libSDL2pp +GH_COMMIT= eea2b29 + +USES= compiler:c++11-lib cmake +CMAKE_ARGS= -DRUN_GUI_TESTS=OFF \ + -DSDL2PP_WITH_WERROR=ON +USE_SDL= sdl2 image2 + +PORTDOCS= * + +OPTIONS_DEFINE= DOCS + +.include + +.if ${COMPILER_TYPE} == gcc +CXXFLAGS+= -D_GLIBCXX_USE_C99 # gcc c++11 support is broken on FreeBSD +.endif + +post-install: + ${MKDIR} ${STAGEDIR}${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/README.md ${STAGEDIR}${DOCSDIR}/ + +regression-test: build + cd ${WRKSRC} && ${DO_MAKE_BUILD} test + +.include diff --git a/devel/sdl2pp/distinfo b/devel/sdl2pp/distinfo new file mode 100644 index 000000000000..273734dd9c9c --- /dev/null +++ b/devel/sdl2pp/distinfo @@ -0,0 +1,2 @@ +SHA256 (sdl2pp-0.4.0.tar.gz) = 73ccc98a9557c0683baa446c17e9e71d7b7cb56de795c6927adbde93bafa18da +SIZE (sdl2pp-0.4.0.tar.gz) = 90567 diff --git a/devel/sdl2pp/pkg-descr b/devel/sdl2pp/pkg-descr new file mode 100644 index 000000000000..a8dfe0d74bf4 --- /dev/null +++ b/devel/sdl2pp/pkg-descr @@ -0,0 +1,10 @@ +This library provides C++11 bindings/wrapper over a subset of SDL2 +functions with extra features proided with modern C++ such as: + +* RAII-style initialization and destruction +* Full error checking: exception is thrown if any SDL function + fails. Exception itself allows to retrieve SDL error string +* C++11 move semantics support, which allow you to store SDL objects + in containers and pass/return them by value with no overhead + +WWW: https://github.com/AMDmi3/libSDL2pp diff --git a/devel/sdl2pp/pkg-plist b/devel/sdl2pp/pkg-plist new file mode 100644 index 000000000000..9b1ef1b6dc58 --- /dev/null +++ b/devel/sdl2pp/pkg-plist @@ -0,0 +1,19 @@ +include/SDL2pp/AudioDevice.hh +include/SDL2pp/AudioSpec.hh +include/SDL2pp/Config.hh +include/SDL2pp/ContainerRWops.hh +include/SDL2pp/Exception.hh +include/SDL2pp/Point.hh +include/SDL2pp/RWops.hh +include/SDL2pp/Rect.hh +include/SDL2pp/Renderer.hh +include/SDL2pp/SDL.hh +include/SDL2pp/SDL2pp.hh +include/SDL2pp/StreamRWops.hh +include/SDL2pp/Texture.hh +include/SDL2pp/Wav.hh +include/SDL2pp/Window.hh +lib/libSDL2pp.so +lib/libSDL2pp.so.1 +lib/libSDL2pp.so.1.0.0 +libdata/pkgconfig/sdl2pp.pc