Index: head/games/keeperrl/Makefile =================================================================== --- head/games/keeperrl/Makefile (revision 460619) +++ head/games/keeperrl/Makefile (revision 460620) @@ -1,52 +1,53 @@ # $FreeBSD$ PORTNAME= keeperrl PORTVERSION= 0.0.${ALPHA_VERSION} +PORTREVISION= 1 CATEGORIES= games MAINTAINER= pawel@FreeBSD.org COMMENT= Ambitious dungeon builder with roguelike elements LICENSE= GPLv2 OFL11 LICENSE_COMB= multi LICENSE_FILE_GPLv2= ${WRKSRC}/COPYING.txt LICENSE_FILE_OFL11= ${WRKSRC}/data_contrib/SIL_Open_Font_License.txt BROKEN_FreeBSD_10= needs c++14, does not build even with clang5 LIB_DEPENDS= libvorbis.so:audio/libvorbis \ libcurl.so:ftp/curl USES= gmake localbase openal USE_GITHUB= yes GH_ACCOUNT= miki151 GH_TAGNAME= alpha${ALPHA_VERSION} USE_GL= gl USE_SDL= sdl2 image2 ALPHA_VERSION= 23 NO_CONFIGURE= yes LIBS+= -lexecinfo MAKE_ARGS= DATA_DIR="${DATADIR}" GCC="${CXX}" \ LDFLAGS="${LDFLAGS}" RELEASE=true DESKTOP_ENTRIES="KeeperRL" "" "" "keeper" \ "Game;Simulation;" false post-patch: @${REINPLACE_CMD} -e '/^CFLAGS =/ s|=|= ${CFLAGS}|' \ -e '/^LIBS =/ s|$$| ${LIBS}|' \ -e 's|bash|sh|' \ ${WRKSRC}/Makefile @${REINPLACE_CMD} 's|bash|sh|' ${WRKSRC}/check_serial.sh @${REINPLACE_CMD} '/_GLIBCXX_END_NAMESPACE_VERSION/d' \ ${WRKSRC}/extern/iomanip.h do-install: ${INSTALL_PROGRAM} ${WRKSRC}/keeper ${STAGEDIR}${PREFIX}/bin @${MKDIR} ${STAGEDIR}${DATADIR} cd ${WRKSRC} && ${COPYTREE_SHARE} "data_contrib data_free" \ ${STAGEDIR}${DATADIR} "! -name *License.txt" .include Index: head/games/keeperrl/files/patch-main.cpp =================================================================== --- head/games/keeperrl/files/patch-main.cpp (nonexistent) +++ head/games/keeperrl/files/patch-main.cpp (revision 460620) @@ -0,0 +1,43 @@ +--- main.cpp.orig 2018-01-31 20:31:47 UTC ++++ main.cpp +@@ -22,6 +22,7 @@ + #include "extern/ProgramOptions.h" + + #include ++#include + + #include "view.h" + #include "options.h" +@@ -285,18 +286,8 @@ static int keeperMain(po::parser& commandLineFlags) { + DirectoryPath userPath([&] () -> string { + if (commandLineFlags["user_dir"].was_set()) + return commandLineFlags["user_dir"].get().string; +-#ifdef USER_DIR +- else if (const char* userDir = USER_DIR) +- return userDir; +-#endif // USER_DIR +-#ifndef WINDOWS +- else if (const char* localPath = std::getenv("XDG_DATA_HOME")) +- return localPath + string("/KeeperRL"); +-#endif +-#ifdef ENABLE_LOCAL_USER_DIR // Some environments don't define XDG_DATA_HOME + else if (const char* homePath = std::getenv("HOME")) +- return homePath + string("/.local/share/KeeperRL"); +-#endif // ENABLE_LOCAL_USER_DIR ++ return homePath + string("/.KeeperRL"); + else + return "."; + }()); +@@ -311,8 +302,10 @@ static int keeperMain(po::parser& commandLineFlags) { + #else + uploadUrl = "http://localhost/~michal/" + serverVersion; + #endif +- //userPath.createIfDoesntExist(); +- CHECK(userPath.exists()) << "User directory \"" << userPath << "\" doesn't exist."; ++ if (!userPath.exists()) { ++ auto configDir = userPath.file(""); ++ ::mkdir(configDir.getPath(), 0775); ++ } + auto settingsPath = userPath.file("options.txt"); + if (commandLineFlags["restore_settings"].was_set()) + remove(settingsPath.getPath()); Property changes on: head/games/keeperrl/files/patch-main.cpp ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property