diff --git a/default.nix b/default.nix index 0b2b2c0..01bb51a 100644 --- a/default.nix +++ b/default.nix @@ -11,9 +11,9 @@ let inherit (sources.ton) owner repo rev; # sadly, not the one niv comes up with. add this check # to make sure people update the hash - sha256 = if version == "ceaed40" then - "1znikk7l2pv5mdl9rh59dljdrqkbwnazlpdjr4yfc87bcynb1rbz" else - "0000000000000000000000000000000000000000000000000000"; + hash = if version == "ae5c072" then + "sha256-6sKA3CPcMkkzLpMJULqGWcLg/INLOK5pVaNbljSIwIs=" else + "sha256-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA="; fetchSubmodules = true; }; in diff --git a/nix/sources.json b/nix/sources.json index 142c971..e76c5fb 100644 --- a/nix/sources.json +++ b/nix/sources.json @@ -5,34 +5,34 @@ "homepage": "https://github.com/nmattia/niv", "owner": "nmattia", "repo": "niv", - "rev": "444c1ad4896ace10b97ab5becede1ceeced0a90c", - "sha256": "199nhdwlnk4wn4kgqyjq9z5cwlajjq7j3i4f54ihc1l9b9rggfd8", + "rev": "5830a4dd348d77e39a0f3c4c762ff2663b602d4c", + "sha256": "1d3lsrqvci4qz2hwjrcnd8h5vfkg8aypq3sjd4g3izbc8frwz5sm", "type": "tarball", - "url": "https://github.com/nmattia/niv/archive/444c1ad4896ace10b97ab5becede1ceeced0a90c.tar.gz", + "url": "https://github.com/nmattia/niv/archive/5830a4dd348d77e39a0f3c4c762ff2663b602d4c.tar.gz", "url_template": "https://github.com///archive/.tar.gz" }, "nixpkgs": { - "branch": "nixos-19.03", + "branch": "nixos-unstable", "description": "A read-only mirror of NixOS/nixpkgs tracking the released channels. Send issues and PRs to", "homepage": "https://github.com/NixOS/nixpkgs", "owner": "NixOS", "repo": "nixpkgs-channels", - "rev": "5f7eae4bbb15ce7fa4da1984fd6ba5be7af50952", - "sha256": "00bzh394dqlwyh53lsd5vj8jdy9pr30rp52q8q5z6h5kw2lr1byf", + "rev": "4762fba469e2baa82f983b262e2c06ac2fdaae67", + "sha256": "1sidky93vc2bpnwb8avqlym1p70h2szhkfiam549377v9r5ld2r1", "type": "tarball", - "url": "https://github.com/NixOS/nixpkgs-channels/archive/5f7eae4bbb15ce7fa4da1984fd6ba5be7af50952.tar.gz", + "url": "https://github.com/NixOS/nixpkgs-channels/archive/4762fba469e2baa82f983b262e2c06ac2fdaae67.tar.gz", "url_template": "https://github.com///archive/.tar.gz" }, "ton": { "branch": "master", "description": null, "homepage": null, - "owner": "ton-blockchain", + "owner": "newton-blockchain", "repo": "ton", - "rev": "ceaed40ac4871ffaeb5b493586ab6f0899fd490d", - "sha256": "1p3kg2l7h6nfnjizf0xgs7090037v60zz8qmqamvf9y71ic9cr7f", + "rev": "ae5c0720143e231c32c3d2034cfe4e533a16d969", + "sha256": "0rwrgndydwgrpfkvpgflmxj820rrgpcw1plp6rwy15153h23hqiz", "type": "tarball", - "url": "https://github.com/ton-blockchain/ton/archive/ceaed40ac4871ffaeb5b493586ab6f0899fd490d.tar.gz", + "url": "https://github.com/newton-blockchain/ton/archive/ae5c0720143e231c32c3d2034cfe4e533a16d969.tar.gz", "url_template": "https://github.com///archive/.tar.gz" } } diff --git a/pkgs/all.nix b/pkgs/all.nix index 598d697..71c13d2 100644 --- a/pkgs/all.nix +++ b/pkgs/all.nix @@ -7,6 +7,7 @@ , stdenv, lib , cmake, pkgconfig , openssl, readline, zlib +, git , libmicrohttpd }: @@ -18,5 +19,5 @@ stdenv.mkDerivation rec { [ ./patches/tonlib-cmake-config.patch ./patches/install-binaries.patch ]; nativeBuildInputs = [ cmake pkgconfig ]; - buildInputs = [ openssl readline zlib libmicrohttpd ]; + buildInputs = [ openssl readline zlib libmicrohttpd git ]; } diff --git a/pkgs/patches/install-binaries.patch b/pkgs/patches/install-binaries.patch index 788c027..a980b15 100644 --- a/pkgs/patches/install-binaries.patch +++ b/pkgs/patches/install-binaries.patch @@ -3,14 +3,14 @@ # SPDX-License-Identifier: LGPL-2.0-or-later diff --git a/lite-client/CMakeLists.txt b/lite-client/CMakeLists.txt -index a1afd52..f45dac2 100644 +index b844951..c71ec85 100644 --- a/lite-client/CMakeLists.txt +++ b/lite-client/CMakeLists.txt -@@ -6,3 +6,10 @@ target_link_libraries(lite-client-common PUBLIC tdutils tdactor adnllite tl_api - add_executable(lite-client lite-client.cpp lite-client.h) +@@ -7,4 +7,9 @@ add_executable(lite-client lite-client.cpp lite-client.h) target_link_libraries(lite-client tdutils tdactor adnllite tl_api tl_lite_api tl-lite-utils ton_crypto ton_block - terminal lite-client-common) -+ + terminal lite-client-common git) + +-install(TARGETS lite-client RUNTIME DESTINATION bin) +install(TARGETS lite-client + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib @@ -18,14 +18,13 @@ index a1afd52..f45dac2 100644 + INCLUDES DESTINATION include +) diff --git a/utils/CMakeLists.txt b/utils/CMakeLists.txt -index c4207bb..36caf8f 100644 +index 25df572..55b8a67 100644 --- a/utils/CMakeLists.txt +++ b/utils/CMakeLists.txt -@@ -14,3 +14,11 @@ add_executable(json2tlo json2tlo.cpp ) - target_link_libraries(json2tlo tl_api ton_crypto keys ) +@@ -15,9 +15,15 @@ target_link_libraries(json2tlo tl_api ton_crypto keys git) target_include_directories(json2tlo PUBLIC $/..) -+ + + +install(TARGETS generate-random-id json2tlo + LIBRARY DESTINATION lib @@ -33,3 +32,10 @@ index c4207bb..36caf8f 100644 + RUNTIME DESTINATION bin + INCLUDES DESTINATION include +) ++ + add_executable(pack-viewer pack-viewer.cpp ) + target_link_libraries(pack-viewer tl_api ton_crypto keys validator tddb) + target_include_directories(pack-viewer PUBLIC + $/..) +- +-install(TARGETS generate-random-id RUNTIME DESTINATION bin) diff --git a/pkgs/patches/tonlib-cmake-config.patch b/pkgs/patches/tonlib-cmake-config.patch index 278a49d..f0b7aad 100644 --- a/pkgs/patches/tonlib-cmake-config.patch +++ b/pkgs/patches/tonlib-cmake-config.patch @@ -11,7 +11,7 @@ index 0000000..4d4080b +@PACKAGE_INIT@ +include ("${CMAKE_CURRENT_LIST_DIR}/TonlibTargets.cmake")% diff --git a/tonlib/CMakeLists.txt b/tonlib/CMakeLists.txt -index 9b9b81d..473bc48 100644 +index 5b6530a..d8102bc 100644 --- a/tonlib/CMakeLists.txt +++ b/tonlib/CMakeLists.txt @@ -154,12 +154,19 @@ install(EXPORT Tonlib