Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

f3kdb: flash3kyuu_deband -> neo_f3kdb #24

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion everything-shell.nix
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ in
pkgs.vapoursynthPlugins.dfttest
pkgs.vapoursynthPlugins.eedi2
pkgs.vapoursynthPlugins.eedi3m
# pkgs.vapoursynthPlugins.f3kdb
pkgs.vapoursynthPlugins.f3kdb
pkgs.vapoursynthPlugins.ffms2
pkgs.vapoursynthPlugins.fft3dfilter
pkgs.vapoursynthPlugins.fillborders
Expand Down
40 changes: 27 additions & 13 deletions plugins/f3kdb/default.nix
Original file line number Diff line number Diff line change
@@ -1,26 +1,40 @@
{ lib, stdenv, fetchFromGitHub, wafHook, python3, vapoursynth }:
{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, python3, vapoursynth, tbb }:

stdenv.mkDerivation rec {
pname = "flash3kyuu_deband";
version = "unstable-2018-08-09";
stdenv.mkDerivation (finalAttrs: {
pname = "neo_f3kdb";
version = "r9";

src = fetchFromGitHub {
owner = "SAPikachu";
repo = pname;
rev = "c57e9d6a535ec9a85fb5415a405f099cbe69f535";
sha256 = "1jkp6b29adjfwl94r8snvk4fv2vy0rgvswsyda5f4jb3lf9hds59";
owner = "HomeOfAviSynthPlusEvolution";
repo = finalAttrs.pname;
rev = finalAttrs.version;
sha256 = "sha256-MIvKjsemDeyv9qonuJbns0Dau8BjFQ1REppccs7s9JU=";
};

wafConfigureFlags = [ "--libdir=${placeholder "out"}/lib/vapoursynth" ];
patches = [
./no-git.patch
];

nativeBuildInputs = [ wafHook python3 ];
buildInputs = [ vapoursynth ];
nativeBuildInputs = [ cmake pkg-config python3 ];
buildInputs = [ vapoursynth tbb ];

cmakeFlags = [
"-DVERSION=${finalAttrs.version}"
];

installPhase = ''
runHook preInstall

install -D --target-directory="$out/lib/vapoursynth" *.so

runHook postInstall
'';

meta = with lib; {
description = "A deband library and filter for AviSynth/VapourSynth";
homepage = "https://github.com/SAPikachu/flash3kyuu_deband";
homepage = "https://github.com/HomeOfAviSynthPlusEvolution/neo_f3kdb";
license = licenses.gpl3;
maintainers = with maintainers; [ tadeokondrak ];
platforms = platforms.all;
};
}
})
15 changes: 15 additions & 0 deletions plugins/f3kdb/no-git.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index f1ee4b3..2f10fb3 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -6,10 +6,6 @@ add_library(neo-f3kdb SHARED main.cpp src/version.rc ${CODE} ${CODE_IMPL})
set_property(TARGET neo-f3kdb PROPERTY CXX_STANDARD 17)
option(ENABLE_PAR "Enable C++17 Parallel Execution" ON)

-find_package(Git REQUIRED)
-execute_process(COMMAND ${GIT_EXECUTABLE} describe --first-parent --tags --always OUTPUT_VARIABLE GIT_REPO_VERSION OUTPUT_STRIP_TRAILING_WHITESPACE)
-string(REGEX REPLACE "(r[0-9]+).*" "\\1" VERSION ${GIT_REPO_VERSION})
-
configure_file (
"${PROJECT_SOURCE_DIR}/src/version.hpp.in"
"${PROJECT_SOURCE_DIR}/src/version.hpp"