Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F150058539
D1696.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
15 KB
Referenced Files
None
Subscribers
None
D1696.diff
View Options
Index: head/devel/Makefile
===================================================================
--- head/devel/Makefile
+++ head/devel/Makefile
@@ -4265,6 +4265,7 @@
SUBDIR += replay
SUBDIR += rhtvision
SUBDIR += rlog
+ SUBDIR += rlvm
SUBDIR += rlwrap
SUBDIR += roboctl
SUBDIR += robodoc
Index: head/devel/rlvm/Makefile
===================================================================
--- head/devel/rlvm/Makefile
+++ head/devel/rlvm/Makefile
@@ -0,0 +1,108 @@
+# $FreeBSD$
+
+PORTNAME= rlvm
+PORTVERSION= 0.14
+CATEGORIES= devel games
+
+MAINTAINER= jbeich@FreeBSD.org
+COMMENT= RealLive virtual machine clone
+
+LICENSE= GPLv2 GPLv3 MIT
+LICENSE_COMB= multi
+
+BUILD_DEPENDS= ${LOCALBASE}/include/utf8.h:${PORTSDIR}/devel/utf8cpp
+LIB_DEPENDS= libvorbisfile.so:${PORTSDIR}/audio/libvorbis \
+ libboost_serialization.so:${PORTSDIR}/devel/boost-libs \
+ libguichan.so:${PORTSDIR}/devel/guichan \
+ libGLEW.so:${PORTSDIR}/graphics/glew \
+ libjpeg.so:${PORTSDIR}/graphics/jpeg \
+ libpng.so:${PORTSDIR}/graphics/png \
+ libsmpeg.so:${PORTSDIR}/multimedia/smpeg
+RUN_DEPENDS= ${LOCALBASE}/lib/X11/fonts/dejavu/DejaVuSans.ttf:${PORTSDIR}/x11-fonts/dejavu
+
+USE_GITHUB= yes
+GH_ACCOUNT= eglaysher
+GH_TAGNAME= release-${PORTVERSION}
+GH_COMMIT= b88bfe0
+
+USES= compiler:c++11-lib pkgconfig scons
+USE_GL= yes
+USE_GNOME= gtk20
+USE_SDL= image mixer ttf
+EXCLUDE= GLEW SDL_image SDL_mixer SDL_ttf gmock gtest guichan \
+ luabind utf8cpp # leaving only pygame, xclannad, *.cpp
+EXTRACT_AFTER_ARGS=${EXCLUDE:S,^,--exclude vendor/,}
+MAKE_ARGS= VERBOSE=1
+INSTALLS_ICONS= yes
+PORTDOCS= AUTHORS.TXT NEWS.TXT README.md STATUS.TXT notes
+
+CFLAGS+= -D_GLIBCXX_USE_C99 # XXX ports/193528
+LDFLAGS+= -Wl,--as-needed # avoid overlinking (gtk deps)
+
+OPTIONS_DEFINE= DEBUG DOCS NLS TEST
+OPTIONS_GROUP= JAPANESE_FONT
+OPTIONS_GROUP_JAPANESE_FONT=KOCHI MONA SAZANAMI
+OPTIONS_SUB= yes
+
+JAPANESE_FONT_DESC=msgothic.ttc alternatives with verified metrics (unless --font)
+KOCHI_DESC= kochi-gothic-subst.ttf from japanese/font-kochi
+KOCHI_RUN_DEPENDS=${LOCALBASE}/lib/X11/fonts/TTF/kochi-gothic-subst.ttf:${PORTSDIR}/japanese/font-kochi
+MONA_DESC= mona.ttf from japanese/monafonts-ttf
+MONA_RUN_DEPENDS=${LOCALBASE}/lib/X11/fonts/TrueType/mona.ttf:${PORTSDIR}/japanese/monafonts-ttf
+SAZANAMI_DESC= sazanami-gothic.ttf from japanese/font-sazanami
+SAZANAMI_RUN_DEPENDS=${LOCALBASE}/lib/X11/fonts/TTF/sazanami-gothic.ttf:${PORTSDIR}/japanese/font-sazanami
+
+DEBUG_MAKE_ARGS_OFF=--release
+NLS_USES= gettext
+NLS_EXTRA_PATCHES_OFF=${FILESDIR}/extra-patch-disable-nls
+TEST_USES= lua:51
+TEST_BUILD_DEPENDS=googletest>=1.7.0:${PORTSDIR}/devel/googletest \
+ googlemock>=1.7.0:${PORTSDIR}/devel/googlemock \
+ luabind>0:${PORTSDIR}/devel/luabind
+TEST_EXTRA_PATCHES_OFF=${FILESDIR}/extra-patch-disable-test
+
+.include <bsd.port.options.mk>
+
+post-patch:
+ @${GREP} -Flr 'utf8cpp/' ${WRKSRC} | ${XARGS} ${REINPLACE_CMD} \
+ -i .bak.utf8cpp -e 's,utf8cpp/,,'
+# Default to TTF/ subdir where japanese/ fonts are often installed
+ @${GREP} -Flr '/usr/share' ${WRKSRC} | ${XARGS} ${REINPLACE_CMD} \
+ -i .bak.paths \
+ -e 's,/usr/share,${PREFIX}/share,' \
+ -e 's,share/fonts,lib/X11/fonts,' \
+ -e 's,truetype/ttf-dejavu,dejavu,' \
+ -e 's,truetype/mona,TrueType,' \
+ -e 's,truetype/[^/"]*,TTF,'
+
+pre-install:
+.if ${PORT_OPTIONS:MTEST}
+ (cd ${WRKSRC} && build/${PORTNAME}_unittests)
+.endif
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/build/${PORTNAME} \
+ ${STAGEDIR}${PREFIX}/bin
+ ${INSTALL_MAN} ${WRKSRC}/debian/${PORTNAME}.6 \
+ ${STAGEDIR}${MAN6PREFIX}/man/man6
+ ${INSTALL_DATA} ${WRKSRC}/src/platforms/gtk/${PORTNAME}.desktop \
+ ${STAGEDIR}${DESKTOPDIR}
+ @(cd ${WRKSRC}/resources && for f in */${PORTNAME}.png; do \
+ ${MKDIR} ${STAGEDIR}${PREFIX}/share/icons/hicolor/$${f%/*}x$${f%/*}/apps; \
+ ${INSTALL_DATA} -v $$f \
+ ${STAGEDIR}${PREFIX}/share/icons/hicolor/$${f%/*}x$${f%/*}/apps; \
+ done)
+.if ${PORT_OPTIONS:MNLS}
+ (cd ${WRKSRC}/build/locale && ${COPYTREE_SHARE} \
+ . ${STAGEDIR}${PREFIX}/share/locale)
+.endif
+.if ${PORT_OPTIONS:MDOCS}
+ ${MKDIR} ${STAGEDIR}${DOCSDIR}
+. for f in ${PORTDOCS:Nnotes}
+ ${INSTALL_DATA} ${WRKSRC}/${f} ${STAGEDIR}${DOCSDIR}
+. endfor
+ (cd ${WRKSRC}/doc && ${COPYTREE_SHARE} \
+ notes ${STAGEDIR}${DOCSDIR})
+.endif
+
+.include <bsd.port.mk>
Index: head/devel/rlvm/distinfo
===================================================================
--- head/devel/rlvm/distinfo
+++ head/devel/rlvm/distinfo
@@ -0,0 +1,2 @@
+SHA256 (rlvm-0.14.tar.gz) = a50a22016cbf87b0ed4d26a14e687c4540b01a2cf836a7f1471c0a9b50ebd8d5
+SIZE (rlvm-0.14.tar.gz) = 1933830
Index: head/devel/rlvm/files/extra-patch-disable-nls
===================================================================
--- head/devel/rlvm/files/extra-patch-disable-nls
+++ head/devel/rlvm/files/extra-patch-disable-nls
@@ -0,0 +1,22 @@
+--- SConstruct~
++++ SConstruct
+@@ -38,9 +38,6 @@ env = Environment(
+ CPPDEFINES = [
+ "HAVE_CONFIG_H",
+
+- # We use gettext for translations.
+- "ENABLE_NLS",
+-
+ # This prevents conflicts between SDL and GLEW. I shouldn't have to do
+ # this, but the SDL_opengl.h and glew.h differ in const correctness...
+ "NO_SDL_GLEXT"
+@@ -410,9 +407,3 @@ if GetOption("coverage"):
+ variant_dir="$BUILD_DIR/",
+ duplicate=0,
+ exports='env')
+-
+-# In addition to all that, we also want to build the translation files.
+-env.Command("build/locale/ja/LC_MESSAGES/rlvm.mo",
+- "po/ja.po",
+- ["mkdir -p build/locale/ja/LC_MESSAGES/",
+- "msgfmt -o build/locale/ja/LC_MESSAGES/rlvm.mo po/ja.po"])
Index: head/devel/rlvm/files/extra-patch-disable-test
===================================================================
--- head/devel/rlvm/files/extra-patch-disable-test
+++ head/devel/rlvm/files/extra-patch-disable-test
@@ -0,0 +1,27 @@
+--- SConstruct~
++++ SConstruct
+@@ -387,24 +387,6 @@ else:
+ duplicate=0,
+ exports='env')
+
+-# Copy the platform independent SEEN.TXT files to output (we no longer depend
+-# on rldev because I can no longer reliably compile it).
+-env.SConscript("test/SConscript.rlc",
+- variant_dir="build/test",
+- duplicate=0,
+- exports='env')
+-
+-# Build the rlvmTests binary that uses those SEEN.TXT files.
+-env.SConscript("SConscript.test",
+- variant_dir="$BUILD_DIR/",
+- duplicate=0,
+- exports='env')
+-
+-env.SConscript("SConscript.luarlvm",
+- variant_dir="$BUILD_DIR/",
+- duplicate=0,
+- exports='env')
+-
+ if GetOption("coverage"):
+ env.SConscript("SConscript.coverage",
+ variant_dir="$BUILD_DIR/",
Index: head/devel/rlvm/files/patch-SConscript.luarlvm
===================================================================
--- head/devel/rlvm/files/patch-SConscript.luarlvm
+++ head/devel/rlvm/files/patch-SConscript.luarlvm
@@ -0,0 +1,20 @@
+--- SConscript.luarlvm~
++++ SConscript.luarlvm
+@@ -31,7 +31,7 @@ config = test_env.Configure()
+ # Building the luaRlvm test harness requires having lua installed; if we do
+ # have lua installed, go ahead and use it, but don't really worry if this fails
+ # since end users don't use this binary.
+-if config.CheckLibWithHeader('lua5.1', 'lua5.1/lua.h', 'cpp'):
++if config.CheckLibWithHeader('lua-5.1', 'lua51/lua.h', 'cpp'):
+ env['BUILD_LUA_TESTS'] = True
+ else:
+ print "Not building luaRlvm. (Don't worry, it's only a testing tool!)"
+@@ -50,7 +50,7 @@ script_machine_files = [
+ ]
+
+ if env['BUILD_LUA_TESTS'] == True:
+- test_env.Append(CPPPATH = [ "/usr/include/lua5.1" ] )
++ test_env.Append(CPPPATH = [ env['ENV']['LUA_INCDIR'] ] )
+
+ # Build our included copy of luabind.
+ test_env.BuildSubcomponent("luabind")
Index: head/devel/rlvm/files/patch-SConstruct
===================================================================
--- head/devel/rlvm/files/patch-SConstruct
+++ head/devel/rlvm/files/patch-SConstruct
@@ -0,0 +1,81 @@
+--- SConstruct~
++++ SConstruct
+@@ -19,7 +19,12 @@ AddOption('--fullstatic', action='store_
+
+ # Set libraries used by all configurations and all binaries in rlvm.
+ env = Environment(
++ ENV=os.environ,
+ tools = ["default", "rlvm"],
++ **dict((k, v.split()) for k, v in ARGUMENTS.iteritems())
++)
++
++env.Append(
+
+ LIBS = ["z"],
+
+@@ -87,13 +91,6 @@ else:
+ if GetOption("fullstatic"):
+ env["FULL_STATIC_BUILD"] = True
+
+-# Auto select the number of processors
+-if os.path.exists('/proc'):
+- cpus = len([l for l in open('/proc/cpuinfo') if l.startswith('processor\t')])
+-else:
+- cpus = 1
+-env.SetOption('num_jobs', cpus + 1)
+-
+ # Use timestamps change, followed by MD5 for speed
+ env.Decider('MD5-timestamp')
+
+@@ -277,11 +274,15 @@ if not config.CheckGuichan():
+ print "(Using included copy of guichan)"
+ subcomponents.append("guichan")
+
++# Get the configuration from sdl and freetype
++env.ParseConfig("sdl-config --cflags")
++env.ParseConfig("freetype-config --cflags --libs")
++
+ # Really optional libraries that jagarl's file loaders take advantage of if on
+ # the system.
+ config.CheckLibWithHeader('png', 'png.h', "cpp")
+-config.CheckLibWithHeader('jpeg', 'jpeglib.h', "cpp")
+-config.CheckLibWithHeader('mad', 'mad.h', "cpp")
++config.CheckLibWithHeader('jpeg', 'jconfig.h', "cpp")
++config.CheckLibWithHeader('smpeg', 'smpeg/smpeg.h', "cpp")
+
+ env = config.Finish()
+
+@@ -291,10 +292,6 @@ env = config.Finish()
+ if env['PLATFORM'] == 'darwin':
+ env.Append(LIBS=["SDL", "intl", "iconv"])
+
+-# Get the configuration from sdl and freetype
+-env.ParseConfig("sdl-config --cflags")
+-env.ParseConfig("freetype-config --cflags --libs")
+-
+ #########################################################################
+ ## Building subcomponent functions
+ #########################################################################
+@@ -314,7 +311,6 @@ if GetOption('release'):
+ # Now add release optimizations to the environment
+ env.Append(
+ CPPFLAGS = [
+- "-Os",
+ "-DNDEBUG",
+ "-DBOOST_DISABLE_ASSERTS"
+ ]
+@@ -360,13 +356,7 @@ elif GetOption('pprof'):
+ "profiler"]
+ )
+ else:
+- # Add debugging flags to all binaries here
+- env.Append(
+- CPPFLAGS = [
+- "-g",
+- "-O0"
+- ]
+- )
++ pass
+
+ # Cross platform core of rlvm. Produces librlvm.a and libsystem_sdl.a
+ env.SConscript("SConscript",
Index: head/devel/rlvm/files/patch-src_systems_sdl_sdl__graphics__system.cc
===================================================================
--- head/devel/rlvm/files/patch-src_systems_sdl_sdl__graphics__system.cc
+++ head/devel/rlvm/files/patch-src_systems_sdl_sdl__graphics__system.cc
@@ -0,0 +1,20 @@
+--- src/systems/sdl/sdl_graphics_system.cc~
++++ src/systems/sdl/sdl_graphics_system.cc
+@@ -32,7 +32,7 @@
+ #include <SDL/SDL.h>
+ #include <SDL/SDL_opengl.h>
+
+-#if defined(__linux__)
++#if !defined(__APPLE__)
+ #include <SDL/SDL_image.h>
+ #endif
+
+@@ -244,7 +244,7 @@ SDLGraphicsSystem::SDLGraphicsSystem(Sys
+
+ SetWindowTitle();
+
+-#if defined(__linux__)
++#if !defined(__APPLE__)
+ // We only set the icon on linux because OSX will use the icns file
+ // automatically and this doesn't look too awesome.
+ SDL_Surface* icon = IMG_Load("/usr/share/icons/hicolor/48x48/apps/rlvm.png");
Index: head/devel/rlvm/files/patch-system-test-deps
===================================================================
--- head/devel/rlvm/files/patch-system-test-deps
+++ head/devel/rlvm/files/patch-system-test-deps
@@ -0,0 +1,24 @@
+--- SConscript.luarlvm~
++++ SConscript.luarlvm
+@@ -52,8 +52,7 @@ script_machine_files = [
+ if env['BUILD_LUA_TESTS'] == True:
+ test_env.Append(CPPPATH = [ env['ENV']['LUA_INCDIR'] ] )
+
+- # Build our included copy of luabind.
+- test_env.BuildSubcomponent("luabind")
++ test_env.Append(LIBS = ["luabind"])
+
+ test_env.RlvmProgram("lua_rlvm", ['test/lua_rlvm.cc', script_machine_files],
+ use_lib_set = ["SDL", "LUA"],
+--- SConscript.test~
++++ SConscript.test
+@@ -23,8 +23,7 @@ test_env.Append(CPPPATH = ["#/test"])
+ # We need to build gtest/gmock always. Downstream distributors: if you comment
+ # this out and add a ParseConfig, make sure to do it here in |test_env| instead
+ # of one of the environments that could link gtest into the main rlvm binary.
+-test_env.BuildSubcomponent("gtest")
+-test_env.BuildSubcomponent("gmock")
++test_env.Append(LIBS = ["gtest", "gmock"])
+
+ test_case_files = [
+ "test/test_system/test_machine.cc",
Index: head/devel/rlvm/files/patch-test_medium__object__promotion.cc
===================================================================
--- head/devel/rlvm/files/patch-test_medium__object__promotion.cc
+++ head/devel/rlvm/files/patch-test_medium__object__promotion.cc
@@ -0,0 +1,19 @@
+To workaround the following error
+
+ unknown file: Failure
+ C++ exception with description "ExpressionPiece::GetStringValue() invalid on this object" thrown in the test body.
+ [ FAILED ] MediumObjectPoromotion/PromotionTest.BgLayerPromotion/49, where GetParam() = ("recMulti", 1, (3, "\"file\"$\xFF\0\0\0\0$\xFF\xFF\0\0\0"), true) (1 ms)
+
+--- test/medium_object_promotion.cc~
++++ test/medium_object_promotion.cc
+@@ -246,10 +246,6 @@ std::vector<PromotionData> data = {
+ 0,
+ TestMachine::Arg("file", 0),
+ SHOULD_PROMOTE_BG),
+- std::make_tuple("recMulti",
+- 1,
+- TestMachine::Arg("file", 0, 255),
+- SHOULD_PROMOTE_BG),
+ std::make_tuple("grpOpen",
+ 0,
+ TestMachine::Arg("file", 0),
Index: head/devel/rlvm/files/patch-vendor_xclannad_wavfile.cc
===================================================================
--- head/devel/rlvm/files/patch-vendor_xclannad_wavfile.cc
+++ head/devel/rlvm/files/patch-vendor_xclannad_wavfile.cc
@@ -0,0 +1,22 @@
+--- vendor/xclannad/wavfile.cc~
++++ vendor/xclannad/wavfile.cc
+@@ -23,6 +23,10 @@
+ *
+ */
+
++#ifdef HAVE_CONFIG_H
++# include "config.h"
++#endif
++
+ #include <stdarg.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+@@ -738,7 +742,7 @@ void MP3FILE::Seek(int count) {
+ } while(pimpl->status != MP3FILE_impl::DONE && pimpl->write_pointer < pimpl->write_data_len);
+ return;
+ }
+-#elif USE_SMPEG
++#elif HAVE_LIBSMPEG
+ #include<smpeg/smpeg.h>
+
+ struct MP3FILE_impl {
Index: head/devel/rlvm/pkg-descr
===================================================================
--- head/devel/rlvm/pkg-descr
+++ head/devel/rlvm/pkg-descr
@@ -0,0 +1,5 @@
+rlvm is a Free Software reimplementation of VisualArt's KK's RealLive
+interpreter, used in the games Kanon, Air, CLANNAD, Planetarian,
+Tomoyo After and Little Busters, among many others.
+
+WWW: http://www.elliotglaysher.org/rlvm/
Index: head/devel/rlvm/pkg-plist
===================================================================
--- head/devel/rlvm/pkg-plist
+++ head/devel/rlvm/pkg-plist
@@ -0,0 +1,10 @@
+bin/rlvm
+man/man6/rlvm.6.gz
+share/applications/rlvm.desktop
+share/icons/hicolor/128x128/apps/rlvm.png
+share/icons/hicolor/16x16/apps/rlvm.png
+share/icons/hicolor/24x24/apps/rlvm.png
+share/icons/hicolor/256x256/apps/rlvm.png
+share/icons/hicolor/32x32/apps/rlvm.png
+share/icons/hicolor/48x48/apps/rlvm.png
+%%NLS%%share/locale/ja/LC_MESSAGES/rlvm.mo
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Mar 30, 1:43 AM (1 h, 28 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
30566740
Default Alt Text
D1696.diff (15 KB)
Attached To
Mode
D1696: add devel/rlvm port
Attached
Detach File
Event Timeline
Log In to Comment