megasync: remove freeimage
also use lib.cmakeBool
This commit is contained in:
-26
@@ -1,26 +0,0 @@
|
||||
--- a/src/MEGASync/mega/src/gfx/freeimage.cpp
|
||||
+++ b/src/MEGASync/mega/src/gfx/freeimage.cpp
|
||||
@@ -200,12 +200,6 @@ bool GfxProviderFreeImage::readbitmapFreeimage(const LocalPath& imagePath, int s
|
||||
|
||||
#ifdef HAVE_FFMPEG
|
||||
|
||||
-#ifdef AV_CODEC_CAP_TRUNCATED
|
||||
-#define CAP_TRUNCATED AV_CODEC_CAP_TRUNCATED
|
||||
-#else
|
||||
-#define CAP_TRUNCATED CODEC_CAP_TRUNCATED
|
||||
-#endif
|
||||
-
|
||||
const char *GfxProviderFreeImage::supportedformatsFfmpeg()
|
||||
{
|
||||
return ".264.265.3g2.3gp.3gpa.3gpp.3gpp2.mp3"
|
||||
@@ -321,10 +315,6 @@ bool GfxProviderFreeImage::readbitmapFfmpeg(const LocalPath& imagePath, int size
|
||||
|
||||
// Force seeking to key frames
|
||||
formatContext->seek2any = false;
|
||||
- if (decoder->capabilities & CAP_TRUNCATED)
|
||||
- {
|
||||
- codecContext->flags |= CAP_TRUNCATED;
|
||||
- }
|
||||
|
||||
AVPixelFormat sourcePixelFormat = static_cast<AVPixelFormat>(codecParm->format);
|
||||
AVPixelFormat targetPixelFormat = AV_PIX_FMT_BGR24; //raw data expected by freeimage is in this format
|
||||
@@ -8,7 +8,6 @@
|
||||
curl,
|
||||
fetchFromGitHub,
|
||||
ffmpeg,
|
||||
freeimage,
|
||||
hicolor-icon-theme,
|
||||
icu,
|
||||
libmediainfo,
|
||||
@@ -59,7 +58,6 @@ mkDerivation rec {
|
||||
cryptopp
|
||||
curl
|
||||
ffmpeg
|
||||
freeimage
|
||||
hicolor-icon-theme
|
||||
icu
|
||||
libmediainfo
|
||||
@@ -82,7 +80,6 @@ mkDerivation rec {
|
||||
];
|
||||
|
||||
patches = [
|
||||
./010-megasync-freeimage-remove-obsolete-ffmpeg-macros.patch
|
||||
./020-megasync-sdk-fix-cmake-dependencies-detection.patch
|
||||
./030-megasync-app-fix-cmake-dependencies-detection.patch #Thanks Arch Linux
|
||||
./040-megasync-fix-cmake-install-bindir.patch
|
||||
@@ -99,8 +96,8 @@ mkDerivation rec {
|
||||
|
||||
cmakeFlags = [
|
||||
"-DCMAKE_MODULE_PATH:PATH=${src}/src/MEGASync/mega/contrib/cmake/modules/packages"
|
||||
"-Wno-dev"
|
||||
"-DUSE_PDFIUM=FALSE" # PDFIUM is not in nixpkgs
|
||||
(lib.cmakeBool "USE_PDFIUM" false) # PDFIUM is not in nixpkgs
|
||||
(lib.cmakeBool "USE_FREEIMAGE" false) # freeimage is insecure
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
|
||||
Reference in New Issue
Block a user