libopenshot: bump version

This commit is contained in:
Gerasim Troeglazov
2021-09-04 21:16:14 +10:00
parent 0efe740606
commit 46862a9c21
3 changed files with 96 additions and 133 deletions

View File

@@ -4,11 +4,11 @@ dedicated to delivering high quality video editing, animation, and playback \
solutions to the world. This is the same library which powers \ solutions to the world. This is the same library which powers \
OpenShot Video Editor (version 2.0+). C++, Python are fully supported." OpenShot Video Editor (version 2.0+). C++, Python are fully supported."
HOMEPAGE="https://www.openshot.org/" HOMEPAGE="https://www.openshot.org/"
COPYRIGHT="2008-2020 OpenShot Studios, LLC" COPYRIGHT="2008-2021 OpenShot Studios, LLC"
LICENSE="GNU LGPL v3" LICENSE="GNU LGPL v3"
REVISION="4" REVISION="1"
SOURCE_URI="https://github.com/OpenShot/libopenshot/archive/v$portVersion.tar.gz" SOURCE_URI="https://github.com/OpenShot/libopenshot/archive/v$portVersion.tar.gz"
CHECKSUM_SHA256="8ae7d226fbd2efbc84da4f7d9d8c7f3cc9616e4de46e1233e3b0a84ac0a429bc" CHECKSUM_SHA256="3e6f60c86748ea814a9c0c48e5a59c5b04a5876a43b763258d0dd3f6ae84fde8"
SOURCE_FILENAME="libopenshot-$portVersion.tar.gz" SOURCE_FILENAME="libopenshot-$portVersion.tar.gz"
PATCHES="libopenshot-$portVersion.patchset" PATCHES="libopenshot-$portVersion.patchset"
@@ -16,7 +16,7 @@ ARCHITECTURES="!x86_gcc2 x86 x86_64"
SECONDARY_ARCHITECTURES="x86" SECONDARY_ARCHITECTURES="x86"
PYTHON_VERSION="3.8" PYTHON_VERSION="3.8"
libVersion="17" libVersion="20"
PROVIDES=" PROVIDES="
libopenshot$secondaryArchSuffix = $portVersion libopenshot$secondaryArchSuffix = $portVersion
@@ -84,6 +84,7 @@ BUILD_REQUIRES="
devel:libexecinfo$secondaryArchSuffix devel:libexecinfo$secondaryArchSuffix
devel:libjsoncpp$secondaryArchSuffix devel:libjsoncpp$secondaryArchSuffix
devel:libMagick++_6.Q16$secondaryArchSuffix devel:libMagick++_6.Q16$secondaryArchSuffix
devel:libopencv_core$secondaryArchSuffix
devel:libopenshot_audio$secondaryArchSuffix devel:libopenshot_audio$secondaryArchSuffix
devel:libQt5Core$secondaryArchSuffix devel:libQt5Core$secondaryArchSuffix
devel:libQt5Gui$secondaryArchSuffix devel:libQt5Gui$secondaryArchSuffix
@@ -92,6 +93,7 @@ BUILD_REQUIRES="
devel:libswresample$secondaryArchSuffix devel:libswresample$secondaryArchSuffix
devel:libswscale$secondaryArchSuffix devel:libswscale$secondaryArchSuffix
devel:libzmq$secondaryArchSuffix devel:libzmq$secondaryArchSuffix
devel:libz$secondaryArchSuffix
" "
BUILD_PREREQUIRES=" BUILD_PREREQUIRES="
cmd:cmake cmd:cmake
@@ -139,7 +141,8 @@ INSTALL()
pythonLocation=$prefix/lib/python$pythonVersion pythonLocation=$prefix/lib/python$pythonVersion
installLocation=$pythonLocation/vendor-packages installLocation=$pythonLocation/vendor-packages
pythonDebugInfoDir=$(getPackagePrefix python38_debuginfo)/$relativeDebugInfoDir pythonDebugInfoDir=$(getPackagePrefix python38_debuginfo)/$relativeDebugInfoDir
mv $pythonLocation/dist-packages $pythonLocation/vendor-packages mkdir -p $pythonLocation
mv $libDir/python/po/vendor-packages $pythonLocation
extractDebugInfo $installLocation/_openshot.so \ extractDebugInfo $installLocation/_openshot.so \
"$pythonDebugInfoDir/_openshot.so(libopenshot_python38-$portFullVersion).debuginfo" "$pythonDebugInfoDir/_openshot.so(libopenshot_python38-$portFullVersion).debuginfo"
# python package # python package

View File

@@ -1,128 +0,0 @@
From e901218528cd2e092f64dc68cf2f07364fd83124 Mon Sep 17 00:00:00 2001
From: Gerasim Troeglazov <3dEyes@gmail.com>
Date: Sat, 2 May 2020 21:02:14 +1000
Subject: Fix build for Haiku
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 470db45..54a3313 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -38,6 +38,7 @@ For more information, please visit <http://www.openshot.org/>.
################ ADD CMAKE MODULES ##################
set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/Modules")
+include(GNUInstallDirs)
################ PROJECT VERSION ####################
set(PROJECT_VERSION_FULL "0.2.5")
diff --git a/include/FFmpegUtilities.h b/include/FFmpegUtilities.h
index 62d64df..f107ccf 100644
--- a/include/FFmpegUtilities.h
+++ b/include/FFmpegUtilities.h
@@ -45,6 +45,10 @@
#define HAVE_HW_ACCEL (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(57, 107, 100))
#endif
+ #ifdef __HAIKU__
+ #undef HAVE_HW_ACCEL
+ #endif
+
// Include the FFmpeg headers
extern "C" {
#include <libavcodec/avcodec.h>
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index a544982..9f527ae 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -77,7 +77,7 @@ ENDIF (ImageMagick_FOUND)
################# LIBOPENSHOT-AUDIO ###################
# Find JUCE-based openshot Audio libraries
-FIND_PACKAGE(OpenShotAudio 0.2.0 REQUIRED)
+FIND_PACKAGE(OpenShotAudio REQUIRED)
# Include Juce headers (needed for compile)
include_directories(${LIBOPENSHOT_AUDIO_INCLUDE_DIRS})
@@ -426,13 +426,13 @@ set(LIB_INSTALL_DIR lib${LIB_SUFFIX}) # determine correct lib folder
# Install primary library
INSTALL(TARGETS openshot
- ARCHIVE DESTINATION ${LIB_INSTALL_DIR}
- LIBRARY DESTINATION ${LIB_INSTALL_DIR}
- RUNTIME DESTINATION ${LIB_INSTALL_DIR}
+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
+ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
+ RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}
COMPONENT library )
INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/include/
- DESTINATION ${CMAKE_INSTALL_PREFIX}/include/libopenshot
+ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/libopenshot
FILES_MATCHING PATTERN "*.h")
############### CPACK PACKAGING ##############
diff --git a/src/CrashHandler.cpp b/src/CrashHandler.cpp
index 1782f5b..1d8d54c 100644
--- a/src/CrashHandler.cpp
+++ b/src/CrashHandler.cpp
@@ -200,7 +200,7 @@ void CrashHandler::printStackTrace(FILE *out, unsigned int max_frames)
}
SymCleanup(process);
-#else
+#elif !defined(__HAIKU__)
// Linux and Mac stack unwinding
// Storage array for stack trace address data
void* addrlist[max_frames+1];
@@ -320,4 +320,4 @@ void CrashHandler::printStackTrace(FILE *out, unsigned int max_frames)
fprintf(out, "---- End of Stack Trace ----\n");
ZmqLogger::Instance()->LogToFile("---- End of Stack Trace ----\n");
-}
\ No newline at end of file
+}
diff --git a/src/bindings/python/CMakeLists.txt b/src/bindings/python/CMakeLists.txt
index 21405f6..c1f48b8 100644
--- a/src/bindings/python/CMakeLists.txt
+++ b/src/bindings/python/CMakeLists.txt
@@ -90,9 +90,11 @@ print( get_python_lib( plat_specific=True, prefix='${CMAKE_INSTALL_PREFIX}' ) )"
GET_FILENAME_COMPONENT(_ABS_PYTHON_MODULE_PATH
"${_ABS_PYTHON_MODULE_PATH}" ABSOLUTE)
+IF (NOT HAIKU)
FILE(RELATIVE_PATH _REL_PYTHON_MODULE_PATH
${CMAKE_INSTALL_PREFIX} ${_ABS_PYTHON_MODULE_PATH})
SET(PYTHON_MODULE_PATH ${_ABS_PYTHON_MODULE_PATH})
+ENDIF(NOT HAIKU)
endif()
message("PYTHON_MODULE_PATH: ${PYTHON_MODULE_PATH}")
--
2.30.0
From 9044a47bf07689978e659e05aab620ccf2615463 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Tue, 26 Jan 2021 19:11:27 +0100
Subject: Force python 3.8
diff --git a/src/bindings/python/CMakeLists.txt b/src/bindings/python/CMakeLists.txt
index c1f48b8..14bda02 100644
--- a/src/bindings/python/CMakeLists.txt
+++ b/src/bindings/python/CMakeLists.txt
@@ -37,8 +37,8 @@ if (POLICY CMP0086)
cmake_policy(SET CMP0086 OLD)
endif()
-FIND_PACKAGE(PythonInterp 3)
-FIND_PACKAGE(PythonLibs 3)
+FIND_PACKAGE(PythonInterp 3.8)
+FIND_PACKAGE(PythonLibs 3.8)
if (PYTHONLIBS_FOUND AND PYTHONINTERP_FOUND)
### Include Python header files
--
2.30.0

View File

@@ -0,0 +1,88 @@
From fafdb707b395355e481d86cfdd1a54a0c01148e2 Mon Sep 17 00:00:00 2001
From: Gerasim Troeglazov <3dEyes@gmail.com>
Date: Tue, 31 Aug 2021 21:23:36 +1000
Subject: Fix build for Haiku
diff --git a/CMakeLists.txt b/CMakeLists.txt
index a36eed2..a1022b2 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -38,6 +38,7 @@ For more information, please visit <http://www.openshot.org/>.
################ ADD CMAKE MODULES ##################
set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/Modules")
+include(GNUInstallDirs)
################ PROJECT VERSION ####################
set(PROJECT_VERSION_FULL "0.2.6")
diff --git a/src/CrashHandler.cpp b/src/CrashHandler.cpp
index 7b6c4e7..6acb8df 100644
--- a/src/CrashHandler.cpp
+++ b/src/CrashHandler.cpp
@@ -200,7 +200,7 @@ void CrashHandler::printStackTrace(FILE *out, unsigned int max_frames)
}
SymCleanup(process);
-#else
+#elif !defined(__HAIKU__)
// Linux and Mac stack unwinding
// Storage array for stack trace address data
void* addrlist[max_frames+1];
@@ -320,4 +320,4 @@ void CrashHandler::printStackTrace(FILE *out, unsigned int max_frames)
fprintf(out, "---- End of Stack Trace ----\n");
ZmqLogger::Instance()->LogToFile("---- End of Stack Trace ----\n");
-}
\ No newline at end of file
+}
diff --git a/src/AudioBufferSource.h b/src/AudioBufferSource.h
index a899d8d..225de2e 100644
--- a/src/AudioBufferSource.h
+++ b/src/AudioBufferSource.h
@@ -32,6 +32,7 @@
#define OPENSHOT_AUDIOBUFFERSOURCE_H
#include <iomanip>
+#include <string.h>
#include <OpenShotAudio.h>
/// This namespace is the default namespace for all code in the openshot library
diff --git a/src/FFmpegReader.cpp b/src/FFmpegReader.cpp
index c1eaa74..6d676ad 100644
--- a/src/FFmpegReader.cpp
+++ b/src/FFmpegReader.cpp
@@ -362,7 +362,7 @@ void FFmpegReader::Open() {
if( adapter_ptr != NULL && access( adapter_ptr, W_OK ) == 0 ) {
#elif defined(_WIN32)
if( adapter_ptr != NULL ) {
-#elif defined(__APPLE__)
+#elif defined(__APPLE__) || defined(__HAIKU__)
if( adapter_ptr != NULL ) {
#endif
ZmqLogger::Instance()->AppendDebugMethod("Decode Device present using device");
diff --git a/src/FFmpegWriter.cpp b/src/FFmpegWriter.cpp
index 8707756..6631950 100644
--- a/src/FFmpegWriter.cpp
+++ b/src/FFmpegWriter.cpp
@@ -1404,7 +1404,7 @@ void FFmpegWriter::open_video(AVFormatContext *oc, AVStream *st) {
snprintf(adapter,sizeof(adapter),"/dev/dri/renderD%d", adapter_num+128);
// Maybe 127 is better because the first card would be 1?!
adapter_ptr = adapter;
-#elif defined(_WIN32) || defined(__APPLE__)
+#elif defined(_WIN32) || defined(__APPLE__) || defined(__HAIKU__)
adapter_ptr = NULL;
#endif
}
@@ -1414,7 +1414,7 @@ void FFmpegWriter::open_video(AVFormatContext *oc, AVStream *st) {
// Check if it is there and writable
#if defined(__linux__)
if( adapter_ptr != NULL && access( adapter_ptr, W_OK ) == 0 ) {
-#elif defined(_WIN32) || defined(__APPLE__)
+#elif defined(_WIN32) || defined(__APPLE__) || defined(__HAIKU__)
if( adapter_ptr != NULL ) {
#endif
ZmqLogger::Instance()->AppendDebugMethod("Encode Device present using device", "adapter", adapter_num);
--
2.30.2