dwarf-fortress-packages.dfhack: 0.43.03-r1 -> 0.43.05-alpha2

This commit is contained in:
Nikolay Amiantov 2016-11-23 18:04:57 +03:00
parent 7e1d5eb17d
commit a6fd30822f
4 changed files with 64 additions and 43 deletions

View file

@ -7,9 +7,9 @@ let
self = rec {
dwarf-fortress-original = callPackage ./game.nix { };
dfhack = callPackage_i686 ./dfhack {
inherit (pkgsi686Linux.perlPackages) XMLLibXML XMLLibXSLT;
protobuf = with pkgsi686Linux; protobuf.override {
dfhack = callPackage ./dfhack {
inherit (pkgs.perlPackages) XMLLibXML XMLLibXSLT;
protobuf = with pkgs; protobuf.override {
stdenv = overrideInStdenv stdenv [ useOldCXXAbi ];
};
};

View file

@ -5,12 +5,15 @@
}:
let
dfVersion = "0.43.03";
version = "${dfVersion}-r1";
dfVersion = "0.43.05";
# version = "${dfVersion}-r1";
# rev = "refs/tags/${version}";
version = "${dfVersion}-alpha2";
rev = "13eb5e702beb6d8e40c0e17be64cda9a8d9d1efb";
sha256 = "18i8qfhhfnfrpa519akwagn73q2zns1pry2sdfag63vffxh60zr5";
rev = "refs/tags/${version}";
# revision of library/xml submodule
xmlRev = "98cc1e01886aaea161d651cf97229ad08e9782b0";
xmlRev = "84f6e968a9ec5515f9dbef96b445e3fc83f83e8b";
fakegit = writeScriptBin "git" ''
#! ${stdenv.shell}
@ -35,8 +38,7 @@ in stdenv.mkDerivation rec {
# Beware of submodules
src = fetchgit {
url = "https://github.com/DFHack/dfhack";
inherit rev;
sha256 = "0m5kqpaz0ypji4c32w0hhbsicvgvnjh56pqvq7af6pqqnyg1nzcx";
inherit rev sha256;
};
patches = [ ./use-system-libraries.patch ];

View file

@ -1,8 +1,7 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 956edfc..fb0e6bc 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -160,8 +160,6 @@ ELSEIF(MSVC)
diff -ru3 dfhack-ae59b4f/CMakeLists.txt dfhack-ae59b4f-new/CMakeLists.txt
--- dfhack-ae59b4f/CMakeLists.txt 1970-01-01 03:00:01.000000000 +0300
+++ dfhack-ae59b4f-new/CMakeLists.txt 2016-11-23 15:21:56.134538785 +0300
@@ -202,8 +202,6 @@
SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELWITHDEBINFO} /Od")
ENDIF()
@ -11,9 +10,9 @@ index 956edfc..fb0e6bc 100644
ADD_DEFINITIONS(-DLUA_BUILD_AS_DLL)
if(APPLE)
@@ -182,10 +180,8 @@ else()
set(ZLIB_ROOT /usr/lib/i386-linux-gnu)
@@ -297,10 +295,8 @@
endif()
find_package(ZLIB REQUIRED)
-include_directories(depends/protobuf)
include_directories(depends/lua/include)
@ -22,10 +21,9 @@ index 956edfc..fb0e6bc 100644
# Support linking against external tinyxml
# If we find an external tinyxml, set the DFHACK_TINYXML variable to "tinyxml"
diff --git a/depends/CMakeLists.txt b/depends/CMakeLists.txt
index d8442b1..b47dc2a 100644
--- a/depends/CMakeLists.txt
+++ b/depends/CMakeLists.txt
diff -ru3 dfhack-ae59b4f/depends/CMakeLists.txt dfhack-ae59b4f-new/depends/CMakeLists.txt
--- dfhack-ae59b4f/depends/CMakeLists.txt 1970-01-01 03:00:01.000000000 +0300
+++ dfhack-ae59b4f-new/depends/CMakeLists.txt 2016-11-23 15:21:56.134538785 +0300
@@ -1,7 +1,6 @@
#list depends here.
add_subdirectory(lua)
@ -34,7 +32,7 @@ index d8442b1..b47dc2a 100644
# Don't build tinyxml if it's being externally linked against.
if(NOT TinyXML_FOUND)
@@ -9,7 +8,6 @@ if(NOT TinyXML_FOUND)
@@ -9,7 +8,6 @@
endif()
add_subdirectory(tthread)
@ -42,46 +40,67 @@ index d8442b1..b47dc2a 100644
# build clsocket static and only as a dependency. Setting those options here overrides its own default settings.
OPTION(CLSOCKET_SHARED "Build clsocket lib as shared." OFF)
OPTION(CLSOCKET_DEP_ONLY "Build for use inside other CMake projects as dependency." ON)
diff --git a/library/CMakeLists.txt b/library/CMakeLists.txt
index d3e3480..5d4b572 100644
--- a/library/CMakeLists.txt
+++ b/library/CMakeLists.txt
@@ -223,10 +223,10 @@ LIST(APPEND PROJECT_SOURCES ${PROJECT_PROTO_SRCS})
diff -ru3 dfhack-ae59b4f/library/CMakeLists.txt dfhack-ae59b4f-new/library/CMakeLists.txt
--- dfhack-ae59b4f/library/CMakeLists.txt 1970-01-01 03:00:01.000000000 +0300
+++ dfhack-ae59b4f-new/library/CMakeLists.txt 2016-11-23 15:22:24.995519136 +0300
@@ -236,14 +236,14 @@
ADD_CUSTOM_COMMAND(
OUTPUT ${PROJECT_PROTO_SRCS} ${PROJECT_PROTO_HDRS}
OUTPUT ${PROJECT_PROTO_TMP_FILES}
- COMMAND protoc-bin -I=${CMAKE_CURRENT_SOURCE_DIR}/proto/
+ COMMAND protoc -I=${CMAKE_CURRENT_SOURCE_DIR}/proto/
--cpp_out=dllexport_decl=DFHACK_EXPORT:${CMAKE_CURRENT_SOURCE_DIR}/proto/
--cpp_out=dllexport_decl=DFHACK_EXPORT:${CMAKE_CURRENT_SOURCE_DIR}/proto/tmp/
${PROJECT_PROTOS}
COMMAND ${PERL_EXECUTABLE} ${CMAKE_SOURCE_DIR}/depends/copy-if-different.pl
${PROJECT_PROTO_TMP_FILES}
${CMAKE_CURRENT_SOURCE_DIR}/proto/
COMMENT "Generating core protobufs"
- DEPENDS protoc-bin ${PROJECT_PROTOS}
+ DEPENDS ${PROJECT_PROTOS}
)
# Merge headers into sources
diff --git a/plugins/CMakeLists.txt b/plugins/CMakeLists.txt
index c24b940..afeb888 100644
--- a/plugins/CMakeLists.txt
+++ b/plugins/CMakeLists.txt
@@ -47,11 +47,11 @@ STRING(REPLACE ".proto" ".pb.h" PROJECT_PROTO_HDRS "${PROJECT_PROTOS}")
ADD_CUSTOM_TARGET(generate_proto_core DEPENDS ${PROJECT_PROTO_TMP_FILES})
diff -ru3 dfhack-ae59b4f/plugins/CMakeLists.txt dfhack-ae59b4f-new/plugins/CMakeLists.txt
--- dfhack-ae59b4f/plugins/CMakeLists.txt 1970-01-01 03:00:01.000000000 +0300
+++ dfhack-ae59b4f-new/plugins/CMakeLists.txt 2016-11-23 15:22:47.291503960 +0300
@@ -60,7 +60,7 @@
ADD_CUSTOM_COMMAND(
OUTPUT ${PROJECT_PROTO_SRCS} ${PROJECT_PROTO_HDRS}
OUTPUT ${PROJECT_PROTO_TMP_FILES}
- COMMAND protoc-bin -I=${dfhack_SOURCE_DIR}/library/proto/
+ COMMAND protoc -I=${dfhack_SOURCE_DIR}/library/proto/
-I=${CMAKE_CURRENT_SOURCE_DIR}/proto/
--cpp_out=${CMAKE_CURRENT_SOURCE_DIR}/proto/
--cpp_out=${CMAKE_CURRENT_SOURCE_DIR}/proto/tmp/
${PROJECT_PROTOS}
@@ -68,7 +68,7 @@
${PROJECT_PROTO_TMP_FILES}
${CMAKE_CURRENT_SOURCE_DIR}/proto/
COMMENT "Generating plugin protobufs"
- DEPENDS protoc-bin ${PROJECT_PROTOS}
+ DEPENDS ${PROJECT_PROTOS}
)
add_custom_target(generate_proto DEPENDS ${PROJECT_PROTO_SRCS} ${PROJECT_PROTO_HDRS})
ADD_CUSTOM_TARGET(generate_proto DEPENDS ${PROJECT_PROTO_TMP_FILES})
diff --git a/plugins/stockpiles/CMakeLists.txt b/plugins/stockpiles/CMakeLists.txt
index 713c3d6..dd2d4cb 100644
--- a/plugins/stockpiles/CMakeLists.txt
+++ b/plugins/stockpiles/CMakeLists.txt
@@ -33,8 +33,8 @@ LIST(APPEND PROJECT_SRCS ${PROJECT_HDRS})
diff -ru3 dfhack-ae59b4f/plugins/ruby/CMakeLists.txt dfhack-ae59b4f-new/plugins/ruby/CMakeLists.txt
--- dfhack-ae59b4f/plugins/ruby/CMakeLists.txt 1970-01-01 03:00:01.000000000 +0300
+++ dfhack-ae59b4f-new/plugins/ruby/CMakeLists.txt 2016-11-23 15:29:09.907286546 +0300
@@ -1,3 +1,4 @@
+IF(FALSE)
IF (APPLE)
SET(RUBYLIB ${CMAKE_CURRENT_SOURCE_DIR}/osx${DFHACK_BUILD_ARCH}/libruby.dylib)
SET(RUBYLIB_INSTALL_NAME "libruby.dylib")
@@ -48,6 +49,7 @@
"482c1c418f4ee1a5f04203eee1cda0ef")
ENDIF()
ENDIF()
+ENDIF()
IF (APPLE OR UNIX)
SET(RUBYAUTOGEN ruby-autogen-gcc.rb)
diff -ru3 dfhack-ae59b4f/plugins/stockpiles/CMakeLists.txt dfhack-ae59b4f-new/plugins/stockpiles/CMakeLists.txt
--- dfhack-ae59b4f/plugins/stockpiles/CMakeLists.txt 1970-01-01 03:00:01.000000000 +0300
+++ dfhack-ae59b4f-new/plugins/stockpiles/CMakeLists.txt 2016-11-23 15:21:56.134538785 +0300
@@ -33,8 +33,8 @@
#Generate sources from our proto files and store them in the source tree
ADD_CUSTOM_COMMAND(
OUTPUT ${PROJECT_PROTO_SRCS} ${PROJECT_PROTO_HDRS}

View file

@ -8,4 +8,4 @@ done
cd "$DF_DIR"
LD_LIBRARY_PATH="$env_dir/hack/libs:$env_dir/hack:$LD_LIBRARY_PATH" \
LD_PRELOAD=$env_dir/hack/libdfhack.so exec $env_dir/libs/Dwarf_Fortress "$@"
LD_PRELOAD="$env_dir/hack/libdfhack.so:$LD_PRELOAD" exec $env_dir/libs/Dwarf_Fortress "$@"