pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/multimedia Add lightspark.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/bb2600f1cfc6
branches:  trunk
changeset: 398065:bb2600f1cfc6
user:      nia <nia%pkgsrc.org@localhost>
date:      Tue Jul 09 16:33:30 2019 +0000

description:
Add lightspark.

Lightspark is an open source Flash player implementation for playing
files in SWF format.

diffstat:

 multimedia/Makefile                                               |   3 +-
 multimedia/lightspark/DESCR                                       |   2 +
 multimedia/lightspark/Makefile                                    |  49 ++++++++++
 multimedia/lightspark/PLIST                                       |  28 +++++
 multimedia/lightspark/distinfo                                    |  13 ++
 multimedia/lightspark/patches/patch-CMakeLists.txt                |  42 ++++++++
 multimedia/lightspark/patches/patch-conf_FindLLVM.cmake           |  32 ++++++
 multimedia/lightspark/patches/patch-src_backends_urlutils.cpp     |  15 +++
 multimedia/lightspark/patches/patch-src_main.cpp                  |  21 ++++
 multimedia/lightspark/patches/patch-src_parsing_tags.cpp          |  15 +++
 multimedia/lightspark/patches/patch-src_platforms_engineutils.cpp |  15 +++
 multimedia/lightspark/patches/patch-src_plugin__ppapi_plugin.cpp  |  15 +++
 12 files changed, 249 insertions(+), 1 deletions(-)

diffs (truncated from 308 to 300 lines):

diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/Makefile
--- a/multimedia/Makefile       Tue Jul 09 16:23:04 2019 +0000
+++ b/multimedia/Makefile       Tue Jul 09 16:33:30 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.270 2019/06/30 21:01:24 nia Exp $
+# $NetBSD: Makefile,v 1.271 2019/07/09 16:33:30 nia Exp $
 #
 
 COMMENT=       Multimedia utilities
@@ -140,6 +140,7 @@
 SUBDIR+=       libva-utils
 SUBDIR+=       libvdpau
 SUBDIR+=       libvpx
+SUBDIR+=       lightspark
 SUBDIR+=       lsdvd
 SUBDIR+=       mate-media
 SUBDIR+=       mediainfo
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/DESCR
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/DESCR       Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,2 @@
+Lightspark is an open source Flash player implementation for playing
+files in SWF format.
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/Makefile    Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,49 @@
+# $NetBSD: Makefile,v 1.1 2019/07/09 16:33:30 nia Exp $
+
+DISTNAME=      lightspark-0.8.1
+CATEGORIES=    multimedia
+MASTER_SITES=  ${MASTER_SITE_GITHUB:=lightspark/}
+
+MAINTAINER=    pkgsrc-users%NetBSD.org@localhost
+HOMEPAGE=      https://lightspark.github.io/
+COMMENT=       Open source Flash player
+LICENSE=       gnu-lgpl-v3
+
+USE_CMAKE=     yes
+USE_TOOLS+=    pkg-config msgfmt msgmerge
+USE_LANGUAGES= c c++
+
+CMAKE_ARGS+=   -DLLVM_CONFIG_EXECUTABLE=${LLVM_CONFIG_PATH:Q}
+CMAKE_ARGS+=   -DMANUAL_DIRECTORY=${PKGMANDIR}
+CMAKE_ARGS+=   -DGNASH_EXE_PATH=${PREFIX}/bin/gnash
+CMAKE_ARGS+=   -DETCDIR=${PKG_SYSCONFDIR}
+
+TOOL_DEPENDS+= nasm>=1.1:../../devel/nasm
+
+# MESSAGE(FATAL_ERROR "GCC 4.6+ is required.")
+GCC_REQD+=     4.6
+
+CONF_FILES+=   ${PREFIX}/share/examples/lightspark/xdg/lightspark.conf \
+               ${PKG_SYSCONFDIR}/xdg/lightspark.conf
+
+.include "../../archivers/xz/buildlink3.mk"
+.include "../../audio/SDL2_mixer/buildlink3.mk"
+.include "../../devel/boost-libs/buildlink3.mk"
+.include "../../devel/gettext-lib/buildlink3.mk"
+.include "../../devel/glibmm/buildlink3.mk"
+.include "../../devel/pango/buildlink3.mk"
+.include "../../devel/pcre/buildlink3.mk"
+.include "../../devel/zlib/buildlink3.mk"
+.include "../../devel/SDL2/buildlink3.mk"
+.include "../../graphics/MesaLib/buildlink3.mk"
+.include "../../graphics/cairo/buildlink3.mk"
+.include "../../graphics/freetype2/buildlink3.mk"
+.include "../../graphics/glew/buildlink3.mk"
+.include "../../graphics/hicolor-icon-theme/buildlink3.mk"
+.include "../../lang/libLLVM34/buildlink3.mk"
+.include "../../multimedia/ffmpeg4/buildlink3.mk"
+.include "../../net/rtmpdump/buildlink3.mk"
+.include "../../x11/libXext/buildlink3.mk"
+.include "../../www/curl/buildlink3.mk"
+.include "../../mk/jpeg.buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/PLIST
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/PLIST       Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,28 @@
+@comment $NetBSD: PLIST,v 1.1 2019/07/09 16:33:30 nia Exp $
+bin/lightspark
+bin/tightspark
+lib/PepperFlash/libpepflashplayer.so
+lib/PepperFlash/manifest.json
+lib/liblightspark.so
+lib/liblightspark.so.0.8
+lib/liblightspark.so.${PKGVERSION}
+lib/mozilla/plugins/liblightsparkplugin.so
+man/man1/lightspark.1
+share/applications/lightspark.desktop
+share/examples/lightspark/xdg/lightspark.conf
+share/icons/hicolor/128x128/apps/lightspark.png
+share/icons/hicolor/16x16/apps/lightspark.png
+share/icons/hicolor/192x192/apps/lightspark.png
+share/icons/hicolor/22x22/apps/lightspark.png
+share/icons/hicolor/24x24/apps/lightspark.png
+share/icons/hicolor/256x256/apps/lightspark.png
+share/icons/hicolor/32x32/apps/lightspark.png
+share/icons/hicolor/36x36/apps/lightspark.png
+share/icons/hicolor/48x48/apps/lightspark.png
+share/icons/hicolor/64x64/apps/lightspark.png
+share/icons/hicolor/72x72/apps/lightspark.png
+share/icons/hicolor/96x96/apps/lightspark.png
+share/icons/hicolor/scalable/apps/lightspark.svg
+share/locale/fr/LC_MESSAGES/lightspark.mo
+share/locale/pl/LC_MESSAGES/lightspark.mo
+share/locale/zh_CN/LC_MESSAGES/lightspark.mo
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/distinfo
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/distinfo    Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,13 @@
+$NetBSD: distinfo,v 1.1 2019/07/09 16:33:30 nia Exp $
+
+SHA1 (lightspark-0.8.1.tar.gz) = dd19eb4584b9ffe838f0966a72fadb90c4fbeb73
+RMD160 (lightspark-0.8.1.tar.gz) = e6193626e2733b971da1fee97091340eb1dc2eef
+SHA512 (lightspark-0.8.1.tar.gz) = ee9f02e4aa160d8e68cab743eddce5f4f5de0bb78f5daaaf69890b442701dc42094a59433cef136f6dc85e6fbce989bc8ff7ce8ad1ed1929c8501b13e24f2646
+Size (lightspark-0.8.1.tar.gz) = 1899466 bytes
+SHA1 (patch-CMakeLists.txt) = 5522aed1f23043cfe9b11f3fe72c2dcba5492076
+SHA1 (patch-conf_FindLLVM.cmake) = d9c067e353d65f9995ef94f75a49bd82dddffc82
+SHA1 (patch-src_backends_urlutils.cpp) = bd1e7584703a1045609b13b7379cf3eddcd13ef0
+SHA1 (patch-src_main.cpp) = 3da1e6f80e07ae3ef9485c006fe7fee23d7f0c82
+SHA1 (patch-src_parsing_tags.cpp) = 951f2757ed68f6e0f5964df3fa944aeace4cbda3
+SHA1 (patch-src_platforms_engineutils.cpp) = 884e37623cf8203d86fcb27e479b41af08a509c4
+SHA1 (patch-src_plugin__ppapi_plugin.cpp) = e0e1be7012c2c75b746b36b8d3801c0aa4d81c95
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/patches/patch-CMakeLists.txt
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/patches/patch-CMakeLists.txt        Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,42 @@
+$NetBSD: patch-CMakeLists.txt,v 1.1 2019/07/09 16:33:30 nia Exp $
+
+Use /lib for "private libs" (liblightspark). This may be evil,
+but currently the private rpath isn't being added properly.
+
+Recognize LLVM 3.4.x.
+
+Install config file as example.
+
+--- CMakeLists.txt.orig        2018-06-02 09:25:36.000000000 +0000
++++ CMakeLists.txt
+@@ -171,10 +171,10 @@ IF(UNIX)
+    SET(DATADIR "share")
+    # Absolute path, because this path is embedded in the binary
+    SET(LSDATADIR "${CMAKE_INSTALL_PREFIX}/${DATADIR}/lightspark")
+-   SET(LIBDIR "lib${LIB_SUFFIX}")
++   SET(LIBDIR "lib")
+    #We need a absolute path here because we use it for rpath
+    #later on
+-   SET(PRIVATELIBDIR "${CMAKE_INSTALL_PREFIX}/${LIBDIR}/lightspark")
++   SET(PRIVATELIBDIR "${CMAKE_INSTALL_PREFIX}/${LIBDIR}")
+    SET(CMAKE_INSTALL_RPATH "${PRIVATELIBDIR}")
+ ELSE()
+   SET(ETCDIR ".")
+@@ -236,7 +236,7 @@ ENDIF(${LLVM_STRING_VERSION} VERSION_GRE
+ IF(${LLVM_STRING_VERSION} VERSION_GREATER 3.3)
+       ADD_DEFINITIONS(-DLLVM_34)
+ ENDIF(${LLVM_STRING_VERSION} VERSION_GREATER 3.3)
+-IF(${LLVM_STRING_VERSION} VERSION_GREATER 3.4)
++IF(${LLVM_STRING_VERSION} VERSION_GREATER 3.4 AND NOT ${LLVM_STRING_VERSION} VERSION_LESS 3.5)
+       ADD_DEFINITIONS(-DLLVM_35)
+ ENDIF(${LLVM_STRING_VERSION} VERSION_GREATER 3.4)
+ IF(NOT (${LLVM_STRING_VERSION} VERSION_LESS 3.6))
+@@ -536,7 +536,7 @@ GETTEXT_CREATE_TRANSLATIONS(i18n/lightsp
+ 
+ if(UNIX)
+       INSTALL(FILES etc/xdg/lightspark.conf
+-                    DESTINATION ${ETCDIR}/xdg/)
++                    DESTINATION ${CMAKE_INSTALL_PREFIX}/share/examples/lightspark/xdg)
+ ELSE()
+   INSTALL(FILES COPYING DESTINATION "." RENAME COPYING.txt)
+   INSTALL(FILES COPYING.LESSER DESTINATION "." RENAME COPYING.LESSER.txt)
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/patches/patch-conf_FindLLVM.cmake
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/patches/patch-conf_FindLLVM.cmake   Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,32 @@
+$NetBSD: patch-conf_FindLLVM.cmake,v 1.1 2019/07/09 16:33:30 nia Exp $
+
+Look for pkgsrc llvm.
+
+--- conf/FindLLVM.cmake.orig   2018-06-02 09:25:36.000000000 +0000
++++ conf/FindLLVM.cmake
+@@ -42,14 +42,17 @@ if (LLVM_INCLUDE_DIR)
+   set(LLVM_FOUND TRUE)
+ else (LLVM_INCLUDE_DIR)
+   file(GLOB LLVM_SEARCHPATHS /usr/lib/llvm*/bin)
+-  find_program(LLVM_CONFIG_EXECUTABLE
+-    NAMES llvm-config
+-    PATHS
+-    /opt/local/bin
+-    /opt/llvm/2.7/bin
+-    /opt/llvm/bin
+-    ${LLVM_SEARCHPATHS}
+-    )
++
++  if (NOT LLVM_CONFIG_EXECUTABLE)
++    find_program(LLVM_CONFIG_EXECUTABLE
++      NAMES llvm-config
++      PATHS
++      /opt/local/bin
++      /opt/llvm/2.7/bin
++      /opt/llvm/bin
++      ${LLVM_SEARCHPATHS}
++      )
++  endif (NOT LLVM_CONFIG_EXECUTABLE)
+ 
+   find_program(LLVM_GCC_EXECUTABLE
+     NAMES llvm-gcc llvmgcc
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/patches/patch-src_backends_urlutils.cpp
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/patches/patch-src_backends_urlutils.cpp     Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,15 @@
+$NetBSD: patch-src_backends_urlutils.cpp,v 1.1 2019/07/09 16:33:30 nia Exp $
+
+NetBSD has alloca in stdlib.h, not alloca.h.
+
+--- src/backends/urlutils.cpp.orig     2018-06-02 09:25:36.000000000 +0000
++++ src/backends/urlutils.cpp
+@@ -32,6 +32,8 @@
+ #include <fstream>
+ #ifdef __MINGW32__
+ #include <malloc.h>
++#elif !defined(__GLIBC__) && !defined(__sun)
++#include <stdlib.h>
+ #else
+ #include <alloca.h>
+ #endif
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/patches/patch-src_main.cpp
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/patches/patch-src_main.cpp  Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,21 @@
+$NetBSD: patch-src_main.cpp,v 1.1 2019/07/09 16:33:30 nia Exp $
+
+get_current_dir_name is not portable.
+
+--- src/main.cpp.orig  2018-06-02 09:25:36.000000000 +0000
++++ src/main.cpp
+@@ -396,9 +396,12 @@ int main(int argc, char* argv[])
+       //When running in a local sandbox, set the root URL to the current working dir
+       else if(sandboxType != SecurityManager::REMOTE)
+       {
+-              char * cwd = get_current_dir_name();
++              char cwd[PATH_MAX];
++              if (getcwd(cwd, PATH_MAX) == NULL) {
++                  LOG(LOG_ERROR,_("getcwd failed"));
++                  exit(1);
++              }
+               string cwdStr = string("file://") + string(cwd);
+-              free(cwd);
+               cwdStr += "/";
+               sys->mainClip->setOrigin(cwdStr, fileName);
+       }
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/patches/patch-src_parsing_tags.cpp
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/patches/patch-src_parsing_tags.cpp  Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,15 @@
+$NetBSD: patch-src_parsing_tags.cpp,v 1.1 2019/07/09 16:33:30 nia Exp $
+
+NetBSD has alloca in stdlib.h, not alloca.h.
+
+--- src/parsing/tags.cpp.orig  2018-06-02 09:25:36.000000000 +0000
++++ src/parsing/tags.cpp
+@@ -23,6 +23,8 @@
+ #include <sstream>
+ #ifdef __MINGW32__
+ #include <malloc.h>
++#elif !defined(__GLIBC__) && !defined(__sun)
++#include <stdlib.h>
+ #else
+ #include <alloca.h>
+ #endif
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/patches/patch-src_platforms_engineutils.cpp
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/patches/patch-src_platforms_engineutils.cpp Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,15 @@
+$NetBSD: patch-src_platforms_engineutils.cpp,v 1.1 2019/07/09 16:33:30 nia Exp $
+
+These are undefined, take advantage of SDL defines instead.
+
+--- src/platforms/engineutils.cpp.orig 2018-06-02 09:25:36.000000000 +0000
++++ src/platforms/engineutils.cpp
+@@ -29,7 +29,7 @@
+ #include "platforms/engineutils.h"
+ 
+ //The interpretation of texture data change with the endianness
+-#if __BYTE_ORDER == __BIG_ENDIAN
++#if SDL_BYTEORDER == SDL_BIG_ENDIAN
+ #define GL_UNSIGNED_INT_8_8_8_8_HOST GL_UNSIGNED_INT_8_8_8_8_REV
+ #else
+ #define GL_UNSIGNED_INT_8_8_8_8_HOST GL_UNSIGNED_BYTE
diff -r 59fba6128900 -r bb2600f1cfc6 multimedia/lightspark/patches/patch-src_plugin__ppapi_plugin.cpp
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/lightspark/patches/patch-src_plugin__ppapi_plugin.cpp  Tue Jul 09 16:33:30 2019 +0000
@@ -0,0 +1,15 @@
+$NetBSD: patch-src_plugin__ppapi_plugin.cpp,v 1.1 2019/07/09 16:33:30 nia Exp $
+
+These are undefined, take advantage of SDL defines instead.
+
+--- src/plugin_ppapi/plugin.cpp.orig   2018-06-02 09:25:36.000000000 +0000
++++ src/plugin_ppapi/plugin.cpp
+@@ -75,7 +75,7 @@



Home | Main Index | Thread Index | Old Index