code
string
repo_name
string
path
string
language
string
license
string
size
int64
# Locally computed sha256 13ce2881f8eaf9936691cf66b9f3471a718ae87249d62ade55174201873fb496 kodi-screensaver-planestate-95b6d1ec72f37bcd16cf8e5d49806193dba883f0.tar.gz
shibajee/buildroot
package/kodi-screensaver-planestate/kodi-screensaver-planestate.hash
hash
mit
167
################################################################################ # # kodi-screensaver-planestate # ################################################################################ KODI_SCREENSAVER_PLANESTATE_VERSION = 95b6d1ec72f37bcd16cf8e5d49806193dba883f0 KODI_SCREENSAVER_PLANESTATE_SITE = $(call github,notspiff,screensaver.planestate,$(KODI_SCREENSAVER_PLANESTATE_VERSION)) KODI_SCREENSAVER_PLANESTATE_DEPENDENCIES = kodi libsoil $(eval $(cmake-package))
shibajee/buildroot
package/kodi-screensaver-planestate/kodi-screensaver-planestate.mk
mk
mit
479
config BR2_PACKAGE_KODI_SCREENSAVER_PYRO bool "kodi-screensaver-pyro" depends on BR2_PACKAGE_HAS_LIBGL help Pyro screensaver for Kodi https://github.com/notspiff/screensaver.pyro comment "kodi-screensaver-pyro needs OpenGL" depends on !BR2_PACKAGE_HAS_LIBGL
shibajee/buildroot
package/kodi-screensaver-pyro/Config.in
in
mit
270
# Locally computed sha256 951bc3259407b7f21183c34556b1efc4c40bfafec61008cd543f382f67466184 kodi-screensaver-pyro-2476b77d9954980a27e07eb8eb0727e2af226351.tar.gz
shibajee/buildroot
package/kodi-screensaver-pyro/kodi-screensaver-pyro.hash
hash
mit
161
################################################################################ # # kodi-screensaver-pyro # ################################################################################ KODI_SCREENSAVER_PYRO_VERSION = 2476b77d9954980a27e07eb8eb0727e2af226351 KODI_SCREENSAVER_PYRO_SITE = $(call github,notspiff,screensaver.pyro,$(KODI_SCREENSAVER_PYRO_VERSION)) KODI_SCREENSAVER_PYRO_LICENSE = GPLv2+ KODI_SCREENSAVER_PYRO_LICENSE_FILES = src/Pyro.cpp KODI_SCREENSAVER_PYRO_DEPENDENCIES = kodi $(eval $(cmake-package))
shibajee/buildroot
package/kodi-screensaver-pyro/kodi-screensaver-pyro.mk
mk
mit
525
Fix cross-compilation Use the cross-compiler and not the host version. Patch sent upstream: https://github.com/notspiff/screensavers.rsxs/pull/5 Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> diff -uNr screensavers.rsxs-195e0ec3fbbcb2ee2012cd560e42d05167f0f259.org/CMakeLists.txt screensavers.rsxs-195e0ec3fbbcb2ee2012cd560e42d05167f0f259/CMakeLists.txt --- screensavers.rsxs-195e0ec3fbbcb2ee2012cd560e42d05167f0f259.org/CMakeLists.txt 2015-03-19 12:20:23.000000000 +0100 +++ screensavers.rsxs-195e0ec3fbbcb2ee2012cd560e42d05167f0f259/CMakeLists.txt 2015-07-19 20:26:16.660481032 +0200 @@ -33,6 +33,11 @@ ${PROJECT_SOURCE_DIR}/${rsxs_dir}/src/skyrocket ${PROJECT_SOURCE_DIR}/${rsxs_dir}/src/solarwinds) + +get_filename_component( COMPILER_FILENAME "${CMAKE_C_COMPILER}" NAME ) +string( REGEX REPLACE "-[^-]+$" "" + TOOLCHAIN_NAME "${COMPILER_FILENAME}" ) + include(ExternalProject) set(update_command "") if(BOOTSTRAP_IN_TREE OR NOT DEFINED BOOTSTRAP_IN_TREE) @@ -46,8 +51,11 @@ endif() endif() externalproject_add(rsxs SOURCE_DIR ${PROJECT_SOURCE_DIR}/${rsxs_dir} - CONFIGURE_COMMAND ${configure_start} + CONFIGURE_COMMAND gl_cv_func_gettimeofday_clobber=no + ac_cv_func_malloc_0_nonnull=yes + ${configure_start} --prefix=<INSTALL_DIR> + --host=${TOOLCHAIN_NAME} --without-xscreensaver --disable-cyclone --disable-euphoria
shibajee/buildroot
package/kodi-screensaver-rsxs/0001-cross-compile.patch
patch
mit
1,722
config BR2_PACKAGE_KODI_SCREENSAVER_RSXS bool "kodi-screensaver-rsxs" depends on BR2_PACKAGE_HAS_LIBGL # libglu depends on BR2_PACKAGE_XORG7 # xlib_libXmu select BR2_PACKAGE_XLIB_LIBXMU help RSXS screensaver add-ons for Kodi https://github.com/notspiff/screensavers.rsxs comment "kodi-screensaver-rsxs depends on X.org and needs OpenGL" depends on !BR2_PACKAGE_XORG7 || !BR2_PACKAGE_HAS_LIBGL
shibajee/buildroot
package/kodi-screensaver-rsxs/Config.in
in
mit
407
# Locally computed sha256 0797ffb720056ea2e04ac8b7ee4fc2dca1e42611ef138b347e928d8d7f3c696f kodi-screensaver-rsxs-195e0ec3fbbcb2ee2012cd560e42d05167f0f259.tar.gz
shibajee/buildroot
package/kodi-screensaver-rsxs/kodi-screensaver-rsxs.hash
hash
mit
161
################################################################################ # # kodi-screensaver-rsxs # ################################################################################ KODI_SCREENSAVER_RSXS_VERSION = 195e0ec3fbbcb2ee2012cd560e42d05167f0f259 KODI_SCREENSAVER_RSXS_SITE = $(call github,notspiff,screensavers.rsxs,$(KODI_SCREENSAVER_RSXS_VERSION)) KODI_SCREENSAVER_RSXS_LICENSE = GPLv3 KODI_SCREENSAVER_RSXS_LICENSE_FILES = lib/rsxs-1.0/COPYING KODI_SCREENSAVER_RSXS_DEPENDENCIES = kodi xlib_libXmu $(eval $(cmake-package))
shibajee/buildroot
package/kodi-screensaver-rsxs/kodi-screensaver-rsxs.mk
mk
mit
546
config BR2_PACKAGE_KODI_SCREENSAVER_STARS bool "kodi-screensaver-stars" depends on BR2_PACKAGE_HAS_LIBGL help Starfield screensaver for Kodi https://github.com/notspiff/screensaver.stars comment "kodi-screensaver-stars needs OpenGL" depends on !BR2_PACKAGE_HAS_LIBGL
shibajee/buildroot
package/kodi-screensaver-stars/Config.in
in
mit
279
# Locally computed sha256 79633afcdccf5df31c98d2144bd23086d691e7749255b4295b183b535d9b7abf kodi-screensaver-stars-28bf79d4dce040e9fbdc25f51007e13950cab937.tar.gz
shibajee/buildroot
package/kodi-screensaver-stars/kodi-screensaver-stars.hash
hash
mit
162
################################################################################ # # kodi-screensaver-stars # ################################################################################ KODI_SCREENSAVER_STARS_VERSION = 28bf79d4dce040e9fbdc25f51007e13950cab937 KODI_SCREENSAVER_STARS_SITE = $(call github,notspiff,screensaver.stars,$(KODI_SCREENSAVER_STARS_VERSION)) KODI_SCREENSAVER_STARS_LICENSE = GPLv2+ KODI_SCREENSAVER_STARS_LICENSE_FILES = src/StarField.cpp KODI_SCREENSAVER_STARS_DEPENDENCIES = kodi $(eval $(cmake-package))
shibajee/buildroot
package/kodi-screensaver-stars/kodi-screensaver-stars.mk
mk
mit
538
config BR2_PACKAGE_KODI_VISUALISATION_FISHBMC bool "kodi-visualisation-fishbmc" depends on BR2_PACKAGE_HAS_LIBGL help Fische visualiser for Kodi https://github.com/notspiff/visualization.fishbmc comment "kodi-visualisation-fishbmc needs OpenGL" depends on !BR2_PACKAGE_HAS_LIBGL
shibajee/buildroot
package/kodi-visualisation-fishbmc/Config.in
in
mit
291
# Locally computed sha256 7047d501942bcd5095e0f1424f003caec8eb792b59d16d16ad25f14829844e50 kodi-visualisation-fishbmc-50c38c296a62e096a2216e43b86d864ee265c506.tar.gz
shibajee/buildroot
package/kodi-visualisation-fishbmc/kodi-visualisation-fishbmc.hash
hash
mit
166
################################################################################ # # kodi-visualisation-fishbmc # ################################################################################ KODI_VISUALISATION_FISHBMC_VERSION = 50c38c296a62e096a2216e43b86d864ee265c506 KODI_VISUALISATION_FISHBMC_SITE = $(call github,notspiff,visualization.fishbmc,$(KODI_VISUALISATION_FISHBMC_VERSION)) KODI_VISUALISATION_FISHBMC_LICENSE = GPLv2+ KODI_VISUALISATION_FISHBMC_LICENSE_FILES = visualization.fishbmc/LICENSE KODI_VISUALISATION_FISHBMC_DEPENDENCIES = kodi $(eval $(cmake-package))
shibajee/buildroot
package/kodi-visualisation-fishbmc/kodi-visualisation-fishbmc.mk
mk
mit
582
config BR2_PACKAGE_KODI_VISUALISATION_FOUNTAIN bool "kodi-visualisation-fountain" depends on BR2_PACKAGE_HAS_LIBGL # libsoil select BR2_PACKAGE_LIBSOIL help Fountain visualization for Kodi https://github.com/notspiff/visualization.fountain comment "kodi-visualisation-fountain needs OpenGL" depends on !BR2_PACKAGE_HAS_LIBGL
shibajee/buildroot
package/kodi-visualisation-fountain/Config.in
in
mit
338
# Locally computed sha256 7b2867f415f22e4bc4ba834034f00117fcf76774aea0afc7bf30b5f2d1991dd7 kodi-visualisation-fountain-f22deacd2396a204694d346f85369ea9ea70e16f.tar.gz
shibajee/buildroot
package/kodi-visualisation-fountain/kodi-visualisation-fountain.hash
hash
mit
167
################################################################################ # # kodi-visualisation-fountain # ################################################################################ KODI_VISUALISATION_FOUNTAIN_VERSION = f22deacd2396a204694d346f85369ea9ea70e16f KODI_VISUALISATION_FOUNTAIN_SITE = $(call github,notspiff,visualization.fountain,$(KODI_VISUALISATION_FOUNTAIN_VERSION)) KODI_VISUALISATION_FOUNTAIN_DEPENDENCIES = kodi libsoil $(eval $(cmake-package))
shibajee/buildroot
package/kodi-visualisation-fountain/kodi-visualisation-fountain.mk
mk
mit
479
Fix cross-compilation Use the cross-compiler and not the host version. Patch sent upstream: https://github.com/notspiff/visualization.goom/pull/4 Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> diff -uNr visualization.goom-fb5933ba5b2143d055cc7749dc60a82f6002b305.org/CMakeLists.txt visualization.goom-fb5933ba5b2143d055cc7749dc60a82f6002b305/CMakeLists.txt --- visualization.goom-fb5933ba5b2143d055cc7749dc60a82f6002b305.org/CMakeLists.txt 2014-10-31 11:34:21.000000000 +0100 +++ visualization.goom-fb5933ba5b2143d055cc7749dc60a82f6002b305/CMakeLists.txt 2015-07-19 19:49:43.340054342 +0200 @@ -13,6 +13,10 @@ ${KODI_INCLUDE_DIR} ${PROJECT_SOURCE_DIR}/lib/goom2k4-0/src) +get_filename_component( COMPILER_FILENAME "${CMAKE_C_COMPILER}" NAME ) +string( REGEX REPLACE "-[^-]+$" "" + TOOLCHAIN_NAME "${COMPILER_FILENAME}" ) + include(ExternalProject) set(update_command "") if(BOOTSTRAP_IN_TREE OR NOT DEFINED BOOTSTRAP_IN_TREE) @@ -20,7 +24,7 @@ endif() externalproject_add(libgoom SOURCE_DIR ${PROJECT_SOURCE_DIR}/lib/goom2k4-0 "${update_command}" - CONFIGURE_COMMAND ${PROJECT_SOURCE_DIR}/lib/goom2k4-0/configure --disable-shared --enable-static --with-pic --prefix=<INSTALL_DIR> + CONFIGURE_COMMAND ${PROJECT_SOURCE_DIR}/lib/goom2k4-0/configure --disable-shared --enable-static --with-pic --prefix=<INSTALL_DIR> --host=${TOOLCHAIN_NAME} BUILD_COMMAND ${MAKE} INSTALL_COMMAND "")
shibajee/buildroot
package/kodi-visualisation-goom/0001-cross-compile.patch
patch
mit
1,549
config BR2_PACKAGE_KODI_VISUALISATION_GOOM bool "kodi-visualisation-goom" depends on BR2_PACKAGE_HAS_LIBGL help GOOM visualiser for Kodi https://github.com/notspiff/visualization.goom comment "kodi-visualization-goom needs OpenGL" depends on !BR2_PACKAGE_HAS_LIBGL
shibajee/buildroot
package/kodi-visualisation-goom/Config.in
in
mit
277
# Locally computed sha256 66a71a5c5a1c0016d7020fcc9941634ee465dab14644cdc96023ce0a28408338 kodi-visualisation-goom-16747b7dba9cbdcfdc8df44e849eaf09450fc86f.tar.gz
shibajee/buildroot
package/kodi-visualisation-goom/kodi-visualisation-goom.hash
hash
mit
163
################################################################################ # # kodi-visualisation-goom # ################################################################################ KODI_VISUALISATION_GOOM_VERSION = 16747b7dba9cbdcfdc8df44e849eaf09450fc86f KODI_VISUALISATION_GOOM_SITE = $(call github,notspiff,visualization.goom,$(KODI_VISUALISATION_GOOM_VERSION)) KODI_VISUALISATION_GOOM_LICENSE = GPLv2+ KODI_VISUALISATION_GOOM_LICENSE_FILES = src/Main.cpp KODI_VISUALISATION_GOOM_DEPENDENCIES = kodi $(eval $(cmake-package))
shibajee/buildroot
package/kodi-visualisation-goom/kodi-visualisation-goom.mk
mk
mit
542
From 9c428c3c9f120a11468f98546bcc754d2c3302af Mon Sep 17 00:00:00 2001 From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Thu, 30 Jul 2015 10:02:15 +0200 Subject: [PATCH] FindOpenGLES2: also search for egl with pkg-config The non-pkg-config path looks for both EGL *and* OpenGL ES, but not the pkg-config path, which might lead to missing libraries/headers if egl.pc has more header paths or libraries than glesv2.pc. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> --- CMakeLists.txt | 2 +- FindOpenGLES2.cmake | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8b084cf..81bbe27 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -35,7 +35,7 @@ endif() endif() - include_directories(${OpenGL_INCLUDE_DIR} + include_directories(${OpenGL_INCLUDE_DIR} ${OpenGLES2_INCLUDE_DIRS} ${GLEW_INCLUDE_DIR} ${KODI_INCLUDE_DIR} ${platform_INCLUDE_DIRS} diff --git a/FindOpenGLES2.cmake b/FindOpenGLES2.cmake index e1b7d21..2a9ce0d 100644 --- a/FindOpenGLES2.cmake +++ b/FindOpenGLES2.cmake @@ -7,7 +7,7 @@ find_package(PkgConfig) if(PKG_CONFIG_FOUND) - pkg_check_modules(OpenGLES2 glesv2) + pkg_check_modules(OpenGLES2 glesv2 egl) endif(PKG_CONFIG_FOUND) if(NOT OPENGLES2_FOUND) -- 2.5.0
shibajee/buildroot
package/kodi-visualisation-shadertoy/0001-FindOpenGLES2-also-search-for-egl-with-pkg-config.patch
patch
mit
1,375
config BR2_PACKAGE_KODI_VISUALISATION_SHADERTOY bool "kodi-visualisation-shadertoy" select BR2_PACKAGE_LIBGLEW if BR2_PACKAGE_HAS_LIBGL select BR2_PACKAGE_LIBPLATFORM help Shadertoy visualiser for Kodi https://github.com/notspiff/visualization.shadertoy
shibajee/buildroot
package/kodi-visualisation-shadertoy/Config.in
in
mit
265
# Locally computed sha256 88732c399bb7e1237e8fc375583bb3789c96a28695a3805fb374361a7e5636c5 kodi-visualisation-shadertoy-f9988007681bf37e6c03d6992bae30133b020608.tar.gz
shibajee/buildroot
package/kodi-visualisation-shadertoy/kodi-visualisation-shadertoy.hash
hash
mit
168
################################################################################ # # kodi-visualisation-shadertoy # ################################################################################ KODI_VISUALISATION_SHADERTOY_VERSION = f9988007681bf37e6c03d6992bae30133b020608 KODI_VISUALISATION_SHADERTOY_SITE = $(call github,notspiff,visualization.shadertoy,$(KODI_VISUALISATION_SHADERTOY_VERSION)) KODI_VISUALISATION_SHADERTOY_LICENSE = GPLv2+ KODI_VISUALISATION_SHADERTOY_LICENSE_FILES = src/main.cpp KODI_VISUALISATION_SHADERTOY_DEPENDENCIES = kodi libplatform ifeq ($(BR2_PACKAGE_LIBGLEW),y) KODI_VISUALISATION_SHADERTOY_DEPENDENCIES += libglew endif $(eval $(cmake-package))
shibajee/buildroot
package/kodi-visualisation-shadertoy/kodi-visualisation-shadertoy.mk
mk
mit
685
config BR2_PACKAGE_KODI_VISUALISATION_SPECTRUM bool "kodi-visualisation-spectrum" help Spectrum visualiser for Kodi https://github.com/notspiff/visualization.spectrum
shibajee/buildroot
package/kodi-visualisation-spectrum/Config.in
in
mit
176
# Locally computed sha256 aa417d6ad3d3770029e7d8d9f7f0ca8d56a8a4f47821267b5a8604fc26993334 kodi-visualisation-spectrum-9dbe53a0db73f00ee22e9ca235c98f8137b7bb9e.tar.gz
shibajee/buildroot
package/kodi-visualisation-spectrum/kodi-visualisation-spectrum.hash
hash
mit
167
################################################################################ # # kodi-visualisation-spectrum # ################################################################################ KODI_VISUALISATION_SPECTRUM_VERSION = 9dbe53a0db73f00ee22e9ca235c98f8137b7bb9e KODI_VISUALISATION_SPECTRUM_SITE = $(call github,notspiff,visualization.spectrum,$(KODI_VISUALISATION_SPECTRUM_VERSION)) KODI_VISUALISATION_SPECTRUM_LICENSE = GPLv2+ KODI_VISUALISATION_SPECTRUM_LICENSE_FILES = COPYING KODI_VISUALISATION_SPECTRUM_DEPENDENCIES = kodi $(eval $(cmake-package))
shibajee/buildroot
package/kodi-visualisation-spectrum/kodi-visualisation-spectrum.mk
mk
mit
568
config BR2_PACKAGE_KODI_VISUALISATION_WAVEFORHUE bool "kodi-visualisation-waveforhue" help WaveForHue visualiser for Kodi https://github.com/notspiff/visualization.waveforhue
shibajee/buildroot
package/kodi-visualisation-waveforhue/Config.in
in
mit
184
# Locally computed sha256 2590ce4ee1816ffdf59fe33580a36fba49fbd1f60f4c9022b3315e04debc9c73 kodi-visualisation-waveforhue-e87d5c7d7e7504036b80af8bc89f4cf6489085fe.tar.gz
shibajee/buildroot
package/kodi-visualisation-waveforhue/kodi-visualisation-waveforhue.hash
hash
mit
169
################################################################################ # # kodi-visualisation-waveforhue # ################################################################################ KODI_VISUALISATION_WAVEFORHUE_VERSION = e87d5c7d7e7504036b80af8bc89f4cf6489085fe KODI_VISUALISATION_WAVEFORHUE_SITE = $(call github,notspiff,visualization.waveforhue,$(KODI_VISUALISATION_WAVEFORHUE_VERSION)) KODI_VISUALISATION_WAVEFORHUE_LICENSE = GPLv2+ KODI_VISUALISATION_WAVEFORHUE_LICENSE_FILES = COPYING KODI_VISUALISATION_WAVEFORHUE_DEPENDENCIES = kodi $(eval $(cmake-package))
shibajee/buildroot
package/kodi-visualisation-waveforhue/kodi-visualisation-waveforhue.mk
mk
mit
584
config BR2_PACKAGE_KODI_VISUALISATION_WAVEFORM bool "kodi-visualisation-waveform" help Waveform visualiser for Kodi https://github.com/notspiff/visualization.waveform
shibajee/buildroot
package/kodi-visualisation-waveform/Config.in
in
mit
176
# Locally computed sha256 439bd50fcb1c0912532d0d113f7eeadf28f72bd2cb0c234581ee1acc2a70e45b kodi-visualisation-waveform-89aec48e2975f820004df5a1a53801339a5b3064.tar.gz
shibajee/buildroot
package/kodi-visualisation-waveform/kodi-visualisation-waveform.hash
hash
mit
167
################################################################################ # # kodi-visualisation-waveform # ################################################################################ KODI_VISUALISATION_WAVEFORM_VERSION = 89aec48e2975f820004df5a1a53801339a5b3064 KODI_VISUALISATION_WAVEFORM_SITE = $(call github,notspiff,visualization.waveform,$(KODI_VISUALISATION_WAVEFORM_VERSION)) KODI_VISUALISATION_WAVEFORM_LICENSE = GPLv2+ KODI_VISUALISATION_WAVEFORM_LICENSE_FILES = COPYING KODI_VISUALISATION_WAVEFORM_DEPENDENCIES = kodi $(eval $(cmake-package))
shibajee/buildroot
package/kodi-visualisation-waveform/kodi-visualisation-waveform.mk
mk
mit
568
From 63c255f1f5d68363f49193aceed343e602dc8bdf Mon Sep 17 00:00:00 2001 From: Maxime Hadjinlian <maxime.hadjinlian@gmail.com> Date: Thu, 26 Dec 2013 21:17:10 +0100 Subject: [PATCH] Fixup include path Patch originally taken from : http://repository.timesys.com/buildsources/x/xbmc/xbmc-11.0/xbmc-11.0-fixups.patch Signed-off-by: Maxime Hadjinlian <maxime.hadjinlian@gmail.com> --- lib/enca/configure | 3 --- lib/enca/configure.ac | 3 --- lib/libdvd/libdvdread/misc/dvdread-config.sh | 6 +++--- lib/timidity/configure.in | 6 +++--- 4 files changed, 6 insertions(+), 12 deletions(-) diff --git a/lib/libdvd/libdvdread/misc/dvdread-config.sh b/lib/libdvd/libdvdread/misc/dvdread-config.sh index e170c7e..25ee893 100644 --- a/lib/libdvd/libdvdread/misc/dvdread-config.sh +++ b/lib/libdvd/libdvdread/misc/dvdread-config.sh @@ -48,9 +48,9 @@ if test "$echo_prefix" = "yes"; then fi if test "$echo_cflags" = "yes"; then - echo -I$prefix/include $extracflags + echo $extracflags fi if test "$echo_libs" = "yes"; then - echo -L$libdir $dvdreadlib -fi + echo $dvdreadlib +fi
shibajee/buildroot
package/kodi/0001-Fixup-include-path.patch
patch
mit
1,173
Fix host compile Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> diff -uNr xbmc-656cba5d5c7c5edb166196b48560825b9b1f03fd.org/tools/depends/native/TexturePacker/Makefile xbmc-656cba5d5c7c5edb166196b48560825b9b1f03fd/tools/depends/native/TexturePacker/Makefile --- xbmc-656cba5d5c7c5edb166196b48560825b9b1f03fd.org/tools/depends/native/TexturePacker/Makefile 2015-01-25 09:00:48.000000000 +0100 +++ xbmc-656cba5d5c7c5edb166196b48560825b9b1f03fd/tools/depends/native/TexturePacker/Makefile 2015-01-25 13:03:23.606140953 +0100 @@ -36,7 +36,7 @@ -rm -rf $(PLATFORM)/*; mkdir -p $(PLATFORM) cd $(PLATFORM); cp -a $(SOURCE)/* . cd $(PLATFORM); ./autogen.sh - cd $(PLATFORM); ./configure --prefix=$(PREFIX) $(EXTRA_CONFIGURE) EXTRA_DEFINES="$(NATIVE_ARCH_DEFINES)" + cd $(PLATFORM); ./configure --prefix=$(PREFIX) EXTRA_DEFINES="$(NATIVE_ARCH_DEFINES)" $(APP): $(PLATFORM)
shibajee/buildroot
package/kodi/0002-texturepacker.patch
patch
mit
883
Patch sent upstream: https://github.com/xbmc/xbmc/pull/7551 From a6d6a1a36ff2dff2586fbad2a068e7df14b55fdc Mon Sep 17 00:00:00 2001 From: Bernd Kuhls <bernd.kuhls@t-online.de> Date: Sun, 19 Jul 2015 14:12:03 +0200 Subject: [PATCH 1/1] ALSA: fix device change event support Current uClibc version 0.9.33.2 does not support eventfd_read/write. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> --- configure.ac | 5 ++++- xbmc/linux/FDEventMonitor.cpp | 12 ++++++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index d321f7d..4c6c750 100644 --- a/configure.ac +++ b/configure.ac @@ -911,7 +911,7 @@ AC_FUNC_STRFTIME AC_FUNC_STRTOD AC_FUNC_UTIME_NULL AC_FUNC_VPRINTF -AC_CHECK_FUNCS([atexit dup2 fdatasync floor fs_stat_dev ftime ftruncate getcwd gethostbyaddr gethostbyname gethostname getpagesize getpass gettimeofday inet_ntoa lchown localeconv memchr memmove memset mkdir modf munmap pow rmdir select setenv setlocale socket sqrt strcasecmp strchr strcspn strdup strerror strncasecmp strpbrk strrchr strspn strstr strtol strtoul sysinfo tzset utime posix_fadvise localtime_r]) +AC_CHECK_FUNCS([atexit dup2 fdatasync floor fs_stat_dev ftime ftruncate getcwd gethostbyaddr gethostbyname gethostname getpagesize getpass gettimeofday inet_ntoa lchown localeconv memchr memmove memset mkdir modf munmap pow rmdir select setenv setlocale socket sqrt strcasecmp strchr strcspn strdup strerror strncasecmp strpbrk strrchr strspn strstr strtol strtoul sysinfo tzset utime posix_fadvise localtime_r eventfd_read eventfd_write]) # Check for various sizes AC_CHECK_SIZEOF([int]) @@ -2064,6 +2064,9 @@ fi if test "$use_alsa" = "yes"; then USE_ALSA=1 AC_DEFINE([USE_ALSA],[1],["Define to 1 if alsa is installed"]) + if test "$ac_cv_func_eventfd_read" = "yes" -a "$ac_cv_func_eventfd_write" = "yes"; then + AC_DEFINE([HAVE_EVENTFD],[1],["Define to 1 if eventfd is installed"]) + fi final_message="$final_message\n ALSA:\t\tYes" else USE_ALSA=0 diff --git a/xbmc/linux/FDEventMonitor.cpp b/xbmc/linux/FDEventMonitor.cpp index 4a41477..84efeb9 100644 --- a/xbmc/linux/FDEventMonitor.cpp +++ b/xbmc/linux/FDEventMonitor.cpp @@ -28,6 +28,18 @@ #include "FDEventMonitor.h" +#ifndef HAVE_EVENTFD +static int eventfd_read(int __fd, eventfd_t *__value) +{ + return read(__fd, __value, sizeof(eventfd_t)) == sizeof(eventfd_t) ? 0 : -1; +} + +static int eventfd_write(int __fd, eventfd_t __value) +{ + return write(__fd, &__value, sizeof(eventfd_t)) == sizeof(eventfd_t) ? 0 : -1; +} +#endif + CFDEventMonitor::CFDEventMonitor() : CThread("FDEventMonitor"), m_nextID(0), -- 1.7.10.4
shibajee/buildroot
package/kodi/0003-ALSA-fix-device-change-event-support.patch
patch
mit
2,685
From 6604cce38fed748e98d3bd2bf9d0f368d67eeb3c Mon Sep 17 00:00:00 2001 From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Date: Wed, 29 Jul 2015 23:13:33 +0200 Subject: [PATCH] kodi-config.cmake: use CMAKE_FIND_ROOT_PATH to fix cross-compilation When cross-compiling, the location at build time of the libraries is not the same as the one at run-time. The CMAKE_FIND_ROOT_PATH variable is here to handle this difference, so use it in kodi-config.cmake. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> --- project/cmake/kodi-config.cmake.in | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/project/cmake/kodi-config.cmake.in b/project/cmake/kodi-config.cmake.in index 76626ec..ffb8e1d 100644 --- a/project/cmake/kodi-config.cmake.in +++ b/project/cmake/kodi-config.cmake.in @@ -7,15 +7,15 @@ SET(@APP_NAME_UC@_PREFIX @APP_PREFIX@) ENDIF() IF(NOT @APP_NAME_UC@_INCLUDE_DIR) - SET(@APP_NAME_UC@_INCLUDE_DIR @APP_INCLUDE_DIR@) + SET(@APP_NAME_UC@_INCLUDE_DIR ${CMAKE_FIND_ROOT_PATH}/@APP_INCLUDE_DIR@) ENDIF() IF(NOT @APP_NAME_UC@_LIB_DIR) - SET(@APP_NAME_UC@_LIB_DIR @APP_LIB_DIR@) + SET(@APP_NAME_UC@_LIB_DIR ${CMAKE_FIND_ROOT_PATH}/@APP_LIB_DIR@) ENDIF() IF(NOT WIN32) SET(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} @CXX11_SWITCH@") ENDIF() -LIST(APPEND CMAKE_MODULE_PATH @APP_LIB_DIR@) +LIST(APPEND CMAKE_MODULE_PATH ${CMAKE_FIND_ROOT_PATH}/@APP_LIB_DIR@) ADD_DEFINITIONS(@ARCH_DEFINES@ -DBUILD_KODI_ADDON) if(NOT CORE_SYSTEM_NAME) -- 2.5.0
shibajee/buildroot
package/kodi/0004-kodi-config.cmake-use-CMAKE_FIND_ROOT_PATH-to-fix-cr.patch
patch
mit
1,514
From 2b395fb3f07551ae1ce2e484c14ac59f36e192b0 Mon Sep 17 00:00:00 2001 From: Bernd Kuhls <bernd.kuhls@t-online.de> Date: Thu, 17 Mar 2016 21:47:53 +0100 Subject: [PATCH] native/TexturePacker: fix compilation with gcc 4.6 Kodi itself depends on gcc >= 4.7 due to its use of the C++11 standard. When cross-compiling the host gcc currently also needs to be >= 4.7 due to the texturepacker tool being needed as native binary to compile Textures.xbt for the target system. Cross-compiling on a system where host gcc is at version 4.6 fails atm with this error: cc1plus: error: unrecognized command line option '-std=c++11' make[4]: *** [md5.o] Error 1 make[4]: *** Waiting for unfinished jobs.... cc1plus: error: unrecognized command line option '-std=c++11' cc1plus: error: unrecognized command line option '-std=c++11' make[4]: *** [DecoderManager.o] Error 1 make[4]: *** [XBTFWriter.o] Error 1 cc1plus: error: unrecognized command line option '-std=c++11' make[4]: *** [TexturePacker.o] Error 1 cc1plus: error: unrecognized command line option '-std=c++11' make[4]: *** [decoder/PNGDecoder.o] Error 1 make[3]: *** [all] Error 2 make[2]: *** [native/TexturePacker] Error 2 Using this patch the problem is fixed and a working TexturePacker host binary is created. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> Patch sent upstream: https://github.com/xbmc/xbmc/pull/9378 --- tools/depends/native/TexturePacker/src/Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/depends/native/TexturePacker/src/Makefile.am b/tools/depends/native/TexturePacker/src/Makefile.am index c1fc8be..d075290 100644 --- a/tools/depends/native/TexturePacker/src/Makefile.am +++ b/tools/depends/native/TexturePacker/src/Makefile.am @@ -2,7 +2,7 @@ AUTOMAKE_OPTIONS = subdir-objects AM_CFLAGS = -DTARGET_POSIX -DUSE_LZO_PACKING AM_CFLAGS += @EXTRA_DEFINES@ -AM_CXXFLAGS = $(AM_CFLAGS) -std=c++11 +AM_CXXFLAGS = $(AM_CFLAGS) -std=c++0x AM_CPPFLAGS = \ -I. \ -- 2.7.0
shibajee/buildroot
package/kodi/0005-native-TexturePacker-fix-compilation-with-gcc-4.6.patch
patch
mit
1,996
Add support for ffmpeg 3.0 Changes from original commit are only in file paths & quilt refresh. commit c31b7d374062f87c7512d9872cbceac920465913 Author: Philip Langdale <philipl@overt.org> Date: Mon Sep 21 19:49:36 2015 -0700 ffmpeg: Update AVPixelFormat and AV_PIX_FMT_* to compile with master The deprecated PixelFormat and PIX_FMT_* names have been removed in ffmpeg master. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> [Downloaded from https://gitweb.gentoo.org/repo/gentoo.git/tree/media-tv/kodi/files/kodi-16-ffmpeg3.patch] Index: xbmc-16.0-Jarvis/xbmc/cores/FFmpeg.h =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/FFmpeg.h +++ xbmc-16.0-Jarvis/xbmc/cores/FFmpeg.h @@ -24,7 +24,6 @@ #include "utils/CPUInfo.h" extern "C" { -#include "libswscale/swscale.h" #include "libavcodec/avcodec.h" #include "libavformat/avformat.h" #include "libavutil/avutil.h" @@ -33,23 +32,6 @@ extern "C" { #include "libpostproc/postprocess.h" } -inline int SwScaleCPUFlags() -{ - unsigned int cpuFeatures = g_cpuInfo.GetCPUFeatures(); - int flags = 0; - - if (cpuFeatures & CPU_FEATURE_MMX) - flags |= SWS_CPU_CAPS_MMX; - if (cpuFeatures & CPU_FEATURE_MMX2) - flags |= SWS_CPU_CAPS_MMX2; - if (cpuFeatures & CPU_FEATURE_3DNOW) - flags |= SWS_CPU_CAPS_3DNOW; - if (cpuFeatures & CPU_FEATURE_ALTIVEC) - flags |= SWS_CPU_CAPS_ALTIVEC; - - return flags; -} - inline int PPCPUFlags() { unsigned int cpuFeatures = g_cpuInfo.GetCPUFeatures(); Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/DVDCodecUtils.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/DVDCodecUtils.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/DVDCodecUtils.cpp @@ -39,7 +39,7 @@ extern "C" { #include "libswscale/swscale.h" } -// allocate a new picture (PIX_FMT_YUV420P) +// allocate a new picture (AV_PIX_FMT_YUV420P) DVDVideoPicture* CDVDCodecUtils::AllocatePicture(int iWidth, int iHeight) { DVDVideoPicture* pPicture = new DVDVideoPicture; @@ -264,13 +264,13 @@ DVDVideoPicture* CDVDCodecUtils::Convert int dstformat; if (format == RENDER_FMT_UYVY422) - dstformat = PIX_FMT_UYVY422; + dstformat = AV_PIX_FMT_UYVY422; else - dstformat = PIX_FMT_YUYV422; + dstformat = AV_PIX_FMT_YUYV422; - struct SwsContext *ctx = sws_getContext(pSrc->iWidth, pSrc->iHeight, PIX_FMT_YUV420P, + struct SwsContext *ctx = sws_getContext(pSrc->iWidth, pSrc->iHeight, AV_PIX_FMT_YUV420P, pPicture->iWidth, pPicture->iHeight, (AVPixelFormat)dstformat, - SWS_BILINEAR | SwScaleCPUFlags(), NULL, NULL, NULL); + SWS_BILINEAR, NULL, NULL, NULL); sws_scale(ctx, src, srcStride, 0, pSrc->iHeight, dst, dstStride); sws_freeContext(ctx); } @@ -403,25 +403,25 @@ double CDVDCodecUtils::NormalizeFramedur } struct EFormatMap { - PixelFormat pix_fmt; + AVPixelFormat pix_fmt; ERenderFormat format; }; static const EFormatMap g_format_map[] = { - { PIX_FMT_YUV420P, RENDER_FMT_YUV420P } -, { PIX_FMT_YUVJ420P, RENDER_FMT_YUV420P } -, { PIX_FMT_YUV420P10, RENDER_FMT_YUV420P10 } -, { PIX_FMT_YUV420P16, RENDER_FMT_YUV420P16 } -, { PIX_FMT_UYVY422, RENDER_FMT_UYVY422 } -, { PIX_FMT_YUYV422, RENDER_FMT_YUYV422 } -, { PIX_FMT_VAAPI_VLD, RENDER_FMT_VAAPI } -, { PIX_FMT_DXVA2_VLD, RENDER_FMT_DXVA } -, { PIX_FMT_NONE , RENDER_FMT_NONE } + { AV_PIX_FMT_YUV420P, RENDER_FMT_YUV420P } +, { AV_PIX_FMT_YUVJ420P, RENDER_FMT_YUV420P } +, { AV_PIX_FMT_YUV420P10, RENDER_FMT_YUV420P10 } +, { AV_PIX_FMT_YUV420P16, RENDER_FMT_YUV420P16 } +, { AV_PIX_FMT_UYVY422, RENDER_FMT_UYVY422 } +, { AV_PIX_FMT_YUYV422, RENDER_FMT_YUYV422 } +, { AV_PIX_FMT_VAAPI_VLD, RENDER_FMT_VAAPI } +, { AV_PIX_FMT_DXVA2_VLD, RENDER_FMT_DXVA } +, { AV_PIX_FMT_NONE , RENDER_FMT_NONE } }; ERenderFormat CDVDCodecUtils::EFormatFromPixfmt(int fmt) { - for(const EFormatMap *p = g_format_map; p->pix_fmt != PIX_FMT_NONE; ++p) + for(const EFormatMap *p = g_format_map; p->pix_fmt != AV_PIX_FMT_NONE; ++p) { if(p->pix_fmt == fmt) return p->format; @@ -431,10 +431,10 @@ ERenderFormat CDVDCodecUtils::EFormatFro int CDVDCodecUtils::PixfmtFromEFormat(ERenderFormat fmt) { - for(const EFormatMap *p = g_format_map; p->pix_fmt != PIX_FMT_NONE; ++p) + for(const EFormatMap *p = g_format_map; p->pix_fmt != AV_PIX_FMT_NONE; ++p) { if(p->format == fmt) return p->pix_fmt; } - return PIX_FMT_NONE; + return AV_PIX_FMT_NONE; } Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecFFmpeg.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecFFmpeg.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecFFmpeg.cpp @@ -77,8 +77,8 @@ enum DecoderState STATE_SW_MULTI }; -enum PixelFormat CDVDVideoCodecFFmpeg::GetFormat( struct AVCodecContext * avctx - , const PixelFormat * fmt ) +enum AVPixelFormat CDVDVideoCodecFFmpeg::GetFormat( struct AVCodecContext * avctx + , const AVPixelFormat * fmt ) { CDVDVideoCodecFFmpeg* ctx = (CDVDVideoCodecFFmpeg*)avctx->opaque; @@ -104,8 +104,8 @@ enum PixelFormat CDVDVideoCodecFFmpeg::G avctx->hwaccel_context = 0; } - const PixelFormat * cur = fmt; - while(*cur != PIX_FMT_NONE) + const AVPixelFormat * cur = fmt; + while(*cur != AV_PIX_FMT_NONE) { #ifdef HAVE_LIBVDPAU if(VDPAU::CDecoder::IsVDPAUFormat(*cur) && CSettings::GetInstance().GetBool(CSettings::SETTING_VIDEOPLAYER_USEVDPAU)) @@ -137,7 +137,7 @@ enum PixelFormat CDVDVideoCodecFFmpeg::G #endif #ifdef HAVE_LIBVA // mpeg4 vaapi decoding is disabled - if(*cur == PIX_FMT_VAAPI_VLD && CSettings::GetInstance().GetBool(CSettings::SETTING_VIDEOPLAYER_USEVAAPI)) + if(*cur == AV_PIX_FMT_VAAPI_VLD && CSettings::GetInstance().GetBool(CSettings::SETTING_VIDEOPLAYER_USEVAAPI)) { VAAPI::CDecoder* dec = new VAAPI::CDecoder(); if(dec->Open(avctx, ctx->m_pCodecContext, *cur, ctx->m_uSurfacesCount) == true) @@ -214,11 +214,11 @@ bool CDVDVideoCodecFFmpeg::Open(CDVDStre for(std::vector<ERenderFormat>::iterator it = options.m_formats.begin(); it != options.m_formats.end(); ++it) { - m_formats.push_back((PixelFormat)CDVDCodecUtils::PixfmtFromEFormat(*it)); + m_formats.push_back((AVPixelFormat)CDVDCodecUtils::PixfmtFromEFormat(*it)); if(*it == RENDER_FMT_YUV420P) - m_formats.push_back(PIX_FMT_YUVJ420P); + m_formats.push_back(AV_PIX_FMT_YUVJ420P); } - m_formats.push_back(PIX_FMT_NONE); /* always add none to get a terminated list in ffmpeg world */ + m_formats.push_back(AV_PIX_FMT_NONE); /* always add none to get a terminated list in ffmpeg world */ pCodec = avcodec_find_decoder(hints.codec); @@ -655,7 +655,7 @@ bool CDVDVideoCodecFFmpeg::GetPictureCom pDvdVideoPicture->color_transfer = m_pCodecContext->color_trc; pDvdVideoPicture->color_matrix = m_pCodecContext->colorspace; if(m_pCodecContext->color_range == AVCOL_RANGE_JPEG - || m_pCodecContext->pix_fmt == PIX_FMT_YUVJ420P) + || m_pCodecContext->pix_fmt == AV_PIX_FMT_YUVJ420P) pDvdVideoPicture->color_range = 1; else pDvdVideoPicture->color_range = 0; @@ -738,8 +738,8 @@ bool CDVDVideoCodecFFmpeg::GetPicture(DV pDvdVideoPicture->iFlags |= pDvdVideoPicture->data[0] ? 0 : DVP_FLAG_DROPPED; pDvdVideoPicture->extended_format = 0; - PixelFormat pix_fmt; - pix_fmt = (PixelFormat)m_pFrame->format; + AVPixelFormat pix_fmt; + pix_fmt = (AVPixelFormat)m_pFrame->format; pDvdVideoPicture->format = CDVDCodecUtils::EFormatFromPixfmt(pix_fmt); return true; Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecFFmpeg.h =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecFFmpeg.h +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecFFmpeg.h @@ -46,7 +46,7 @@ public: public: IHardwareDecoder() {} virtual ~IHardwareDecoder() {}; - virtual bool Open (AVCodecContext* avctx, AVCodecContext* mainctx, const enum PixelFormat, unsigned int surfaces) = 0; + virtual bool Open (AVCodecContext* avctx, AVCodecContext* mainctx, const enum AVPixelFormat, unsigned int surfaces) = 0; virtual int Decode (AVCodecContext* avctx, AVFrame* frame) = 0; virtual bool GetPicture(AVCodecContext* avctx, AVFrame* frame, DVDVideoPicture* picture) = 0; virtual int Check (AVCodecContext* avctx) = 0; @@ -77,7 +77,7 @@ public: void SetHardware(IHardwareDecoder* hardware); protected: - static enum PixelFormat GetFormat(struct AVCodecContext * avctx, const PixelFormat * fmt); + static enum AVPixelFormat GetFormat(struct AVCodecContext * avctx, const AVPixelFormat * fmt); int FilterOpen(const std::string& filters, bool scale); void FilterClose(); @@ -119,7 +119,7 @@ protected: int m_iLastKeyframe; double m_dts; bool m_started; - std::vector<PixelFormat> m_formats; + std::vector<AVPixelFormat> m_formats; double m_decoderPts; int m_skippedDeint; bool m_requestSkipDeint; Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecVDA.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecVDA.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecVDA.cpp @@ -554,11 +554,11 @@ void CDVDVideoCodecVDA::DisplayQueuePop( void CDVDVideoCodecVDA::UYVY422_to_YUV420P(uint8_t *yuv422_ptr, int yuv422_stride, DVDVideoPicture *picture) { - // convert PIX_FMT_UYVY422 to PIX_FMT_YUV420P. + // convert AV_PIX_FMT_UYVY422 to AV_PIX_FMT_YUV420P. struct SwsContext *swcontext = sws_getContext( - m_videobuffer.iWidth, m_videobuffer.iHeight, PIX_FMT_UYVY422, - m_videobuffer.iWidth, m_videobuffer.iHeight, PIX_FMT_YUV420P, - SWS_FAST_BILINEAR | SwScaleCPUFlags(), NULL, NULL, NULL); + m_videobuffer.iWidth, m_videobuffer.iHeight, AV_PIX_FMT_UYVY422, + m_videobuffer.iWidth, m_videobuffer.iHeight, AV_PIX_FMT_YUV420P, + SWS_FAST_BILINEAR, NULL, NULL, NULL); if (swcontext) { uint8_t *src[] = { yuv422_ptr, 0, 0, 0 }; @@ -574,11 +574,11 @@ void CDVDVideoCodecVDA::UYVY422_to_YUV42 void CDVDVideoCodecVDA::BGRA_to_YUV420P(uint8_t *bgra_ptr, int bgra_stride, DVDVideoPicture *picture) { - // convert PIX_FMT_BGRA to PIX_FMT_YUV420P. + // convert AV_PIX_FMT_BGRA to AV_PIX_FMT_YUV420P. struct SwsContext *swcontext = sws_getContext( - m_videobuffer.iWidth, m_videobuffer.iHeight, PIX_FMT_BGRA, - m_videobuffer.iWidth, m_videobuffer.iHeight, PIX_FMT_YUV420P, - SWS_FAST_BILINEAR | SwScaleCPUFlags(), NULL, NULL, NULL); + m_videobuffer.iWidth, m_videobuffer.iHeight, AV_PIX_FMT_BGRA, + m_videobuffer.iWidth, m_videobuffer.iHeight, AV_PIX_FMT_YUV420P, + SWS_FAST_BILINEAR, NULL, NULL, NULL); if (swcontext) { uint8_t *src[] = { bgra_ptr, 0, 0, 0 }; Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/DXVA.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/DXVA.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/DXVA.cpp @@ -886,7 +886,7 @@ static bool CheckCompatibility(AVCodecCo return true; } -bool CDecoder::Open(AVCodecContext *avctx, AVCodecContext* mainctx, enum PixelFormat fmt, unsigned int surfaces) +bool CDecoder::Open(AVCodecContext *avctx, AVCodecContext* mainctx, enum AVPixelFormat fmt, unsigned int surfaces) { if (!CheckCompatibility(avctx)) return false; @@ -1135,9 +1135,9 @@ bool CDecoder::OpenDecoder() return true; } -bool CDecoder::Supports(enum PixelFormat fmt) +bool CDecoder::Supports(enum AVPixelFormat fmt) { - if(fmt == PIX_FMT_DXVA2_VLD) + if(fmt == AV_PIX_FMT_DXVA2_VLD) return true; return false; } Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/DXVA.h =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/DXVA.h +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/DXVA.h @@ -141,7 +141,7 @@ class CDecoder public: CDecoder(); ~CDecoder(); - virtual bool Open (AVCodecContext* avctx, AVCodecContext* mainctx, const enum PixelFormat, unsigned int surfaces); + virtual bool Open (AVCodecContext* avctx, AVCodecContext* mainctx, const enum AVPixelFormat, unsigned int surfaces); virtual int Decode (AVCodecContext* avctx, AVFrame* frame); virtual bool GetPicture(AVCodecContext* avctx, AVFrame* frame, DVDVideoPicture* picture); virtual int Check (AVCodecContext* avctx); @@ -154,7 +154,7 @@ public: int GetBuffer(AVCodecContext *avctx, AVFrame *pic, int flags); void RelBuffer(uint8_t *data); - static bool Supports(enum PixelFormat fmt); + static bool Supports(enum AVPixelFormat fmt); void CloseDXVADecoder(); Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VAAPI.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/VAAPI.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VAAPI.cpp @@ -479,7 +479,7 @@ CDecoder::~CDecoder() Close(); } -bool CDecoder::Open(AVCodecContext* avctx, AVCodecContext* mainctx, const enum PixelFormat fmt, unsigned int surfaces) +bool CDecoder::Open(AVCodecContext* avctx, AVCodecContext* mainctx, const enum AVPixelFormat fmt, unsigned int surfaces) { // don't support broken wrappers by default // nvidia cards with a vaapi to vdpau wrapper Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VAAPI.h =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/VAAPI.h +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VAAPI.h @@ -406,7 +406,7 @@ public: CDecoder(); virtual ~CDecoder(); - virtual bool Open (AVCodecContext* avctx, AVCodecContext* mainctx, const enum PixelFormat, unsigned int surfaces = 0); + virtual bool Open (AVCodecContext* avctx, AVCodecContext* mainctx, const enum AVPixelFormat, unsigned int surfaces = 0); virtual int Decode (AVCodecContext* avctx, AVFrame* frame); virtual bool GetPicture(AVCodecContext* avctx, AVFrame* frame, DVDVideoPicture* picture); virtual void Reset(); Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VDA.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/VDA.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VDA.cpp @@ -186,7 +186,7 @@ void CDecoder::Close() m_bitstream = NULL; } -bool CDecoder::Open(AVCodecContext *avctx, AVCodecContext* mainctx, enum PixelFormat fmt, unsigned int surfaces) +bool CDecoder::Open(AVCodecContext *avctx, AVCodecContext* mainctx, enum AVPixelFormat fmt, unsigned int surfaces) { Close(); Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VDA.h =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/VDA.h +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VDA.h @@ -35,7 +35,7 @@ class CDecoder public: CDecoder(); ~CDecoder(); - virtual bool Open(AVCodecContext* avctx, AVCodecContext* mainctx, const enum PixelFormat, unsigned int surfaces = 0); + virtual bool Open(AVCodecContext* avctx, AVCodecContext* mainctx, const enum AVPixelFormat, unsigned int surfaces = 0); virtual int Decode(AVCodecContext* avctx, AVFrame* frame); virtual bool GetPicture(AVCodecContext* avctx, AVFrame* frame, DVDVideoPicture* picture); virtual int Check(AVCodecContext* avctx); Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VDPAU.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/VDPAU.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VDPAU.cpp @@ -486,7 +486,7 @@ CDecoder::CDecoder() : m_vdpauOutput(&m_ m_vdpauConfig.context = 0; } -bool CDecoder::Open(AVCodecContext* avctx, AVCodecContext* mainctx, const enum PixelFormat fmt, unsigned int surfaces) +bool CDecoder::Open(AVCodecContext* avctx, AVCodecContext* mainctx, const enum AVPixelFormat fmt, unsigned int surfaces) { // check if user wants to decode this format with VDPAU std::string gpuvendor = g_Windowing.GetRenderVendor(); @@ -760,7 +760,7 @@ int CDecoder::Check(AVCodecContext* avct return 0; } -bool CDecoder::IsVDPAUFormat(PixelFormat format) +bool CDecoder::IsVDPAUFormat(AVPixelFormat format) { if (format == AV_PIX_FMT_VDPAU) return true; Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VDPAU.h =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDCodecs/Video/VDPAU.h +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDCodecs/Video/VDPAU.h @@ -556,7 +556,7 @@ public: CDecoder(); virtual ~CDecoder(); - virtual bool Open (AVCodecContext* avctx, AVCodecContext* mainctx, const enum PixelFormat, unsigned int surfaces = 0); + virtual bool Open (AVCodecContext* avctx, AVCodecContext* mainctx, const enum AVPixelFormat, unsigned int surfaces = 0); virtual int Decode (AVCodecContext* avctx, AVFrame* frame); virtual bool GetPicture(AVCodecContext* avctx, AVFrame* frame, DVDVideoPicture* picture); virtual void Reset(); @@ -571,7 +571,7 @@ public: bool Supports(VdpVideoMixerFeature feature); bool Supports(EINTERLACEMETHOD method); EINTERLACEMETHOD AutoInterlaceMethod(); - static bool IsVDPAUFormat(PixelFormat fmt); + static bool IsVDPAUFormat(AVPixelFormat fmt); static void FFReleaseBuffer(void *opaque, uint8_t *data); static int FFGetBuffer(AVCodecContext *avctx, AVFrame *pic, int flags); Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxFFmpeg.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxFFmpeg.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxFFmpeg.cpp @@ -1638,7 +1638,7 @@ void CDVDDemuxFFmpeg::ParsePacket(AVPack // for video we need a decoder to get desired information into codec context if (st->codec->codec_type == AVMEDIA_TYPE_VIDEO && st->codec->extradata && - (!st->codec->width || st->codec->pix_fmt == PIX_FMT_NONE)) + (!st->codec->width || st->codec->pix_fmt == AV_PIX_FMT_NONE)) { // open a decoder, it will be cleared down by ffmpeg on closing the stream if (!st->codec->codec) @@ -1695,7 +1695,7 @@ bool CDVDDemuxFFmpeg::IsVideoReady() st = m_pFormatContext->streams[idx]; if (st->codec->codec_type == AVMEDIA_TYPE_VIDEO) { - if (st->codec->width && st->codec->pix_fmt != PIX_FMT_NONE) + if (st->codec->width && st->codec->pix_fmt != AV_PIX_FMT_NONE) return true; hasVideo = true; } @@ -1708,7 +1708,7 @@ bool CDVDDemuxFFmpeg::IsVideoReady() st = m_pFormatContext->streams[i]; if (st->codec->codec_type == AVMEDIA_TYPE_VIDEO) { - if (st->codec->width && st->codec->pix_fmt != PIX_FMT_NONE) + if (st->codec->width && st->codec->pix_fmt != AV_PIX_FMT_NONE) return true; hasVideo = true; } Index: xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDFileInfo.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/dvdplayer/DVDFileInfo.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/dvdplayer/DVDFileInfo.cpp @@ -275,7 +275,7 @@ bool CDVDFileInfo::ExtractThumb(const st uint8_t *pOutBuf = new uint8_t[nWidth * nHeight * 4]; struct SwsContext *context = sws_getContext(picture.iWidth, picture.iHeight, - PIX_FMT_YUV420P, nWidth, nHeight, PIX_FMT_BGRA, SWS_FAST_BILINEAR | SwScaleCPUFlags(), NULL, NULL, NULL); + AV_PIX_FMT_YUV420P, nWidth, nHeight, AV_PIX_FMT_BGRA, SWS_FAST_BILINEAR, NULL, NULL, NULL); if (context) { Index: xbmc-16.0-Jarvis/xbmc/cores/VideoRenderers/LinuxRendererGL.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/VideoRenderers/LinuxRendererGL.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/VideoRenderers/LinuxRendererGL.cpp @@ -2932,7 +2932,7 @@ void CLinuxRendererGL::ToRGBFrame(YV12Im } else if (m_format == RENDER_FMT_NV12) { - srcFormat = PIX_FMT_NV12; + srcFormat = AV_PIX_FMT_NV12; for (int i = 0; i < 2; i++) { src[i] = im->plane[i]; @@ -2941,13 +2941,13 @@ void CLinuxRendererGL::ToRGBFrame(YV12Im } else if (m_format == RENDER_FMT_YUYV422) { - srcFormat = PIX_FMT_YUYV422; + srcFormat = AV_PIX_FMT_YUYV422; src[0] = im->plane[0]; srcStride[0] = im->stride[0]; } else if (m_format == RENDER_FMT_UYVY422) { - srcFormat = PIX_FMT_UYVY422; + srcFormat = AV_PIX_FMT_UYVY422; src[0] = im->plane[0]; srcStride[0] = im->stride[0]; } @@ -2965,8 +2965,8 @@ void CLinuxRendererGL::ToRGBFrame(YV12Im m_context = sws_getCachedContext(m_context, im->width, im->height, (AVPixelFormat)srcFormat, - im->width, im->height, (AVPixelFormat)PIX_FMT_BGRA, - SWS_FAST_BILINEAR | SwScaleCPUFlags(), NULL, NULL, NULL); + im->width, im->height, (AVPixelFormat)AV_PIX_FMT_BGRA, + SWS_FAST_BILINEAR, NULL, NULL, NULL); uint8_t *dst[] = { m_rgbBuffer, 0, 0, 0 }; int dstStride[] = { (int)m_sourceWidth * 4, 0, 0, 0 }; @@ -2995,7 +2995,7 @@ void CLinuxRendererGL::ToRGBFields(YV12I if (m_format == RENDER_FMT_YUV420P) { - srcFormat = PIX_FMT_YUV420P; + srcFormat = AV_PIX_FMT_YUV420P; for (int i = 0; i < 3; i++) { srcTop[i] = im->plane[i]; @@ -3006,7 +3006,7 @@ void CLinuxRendererGL::ToRGBFields(YV12I } else if (m_format == RENDER_FMT_NV12) { - srcFormat = PIX_FMT_NV12; + srcFormat = AV_PIX_FMT_NV12; for (int i = 0; i < 2; i++) { srcTop[i] = im->plane[i]; @@ -3017,7 +3017,7 @@ void CLinuxRendererGL::ToRGBFields(YV12I } else if (m_format == RENDER_FMT_YUYV422) { - srcFormat = PIX_FMT_YUYV422; + srcFormat = AV_PIX_FMT_YUYV422; srcTop[0] = im->plane[0]; srcStrideTop[0] = im->stride[0] * 2; srcBot[0] = im->plane[0] + im->stride[0]; @@ -3025,7 +3025,7 @@ void CLinuxRendererGL::ToRGBFields(YV12I } else if (m_format == RENDER_FMT_UYVY422) { - srcFormat = PIX_FMT_UYVY422; + srcFormat = AV_PIX_FMT_UYVY422; srcTop[0] = im->plane[0]; srcStrideTop[0] = im->stride[0] * 2; srcBot[0] = im->plane[0] + im->stride[0]; @@ -3045,8 +3045,8 @@ void CLinuxRendererGL::ToRGBFields(YV12I m_context = sws_getCachedContext(m_context, im->width, im->height >> 1, (AVPixelFormat)srcFormat, - im->width, im->height >> 1, (AVPixelFormat)PIX_FMT_BGRA, - SWS_FAST_BILINEAR | SwScaleCPUFlags(), NULL, NULL, NULL); + im->width, im->height >> 1, (AVPixelFormat)AV_PIX_FMT_BGRA, + SWS_FAST_BILINEAR, NULL, NULL, NULL); uint8_t *dstTop[] = { m_rgbBuffer, 0, 0, 0 }; uint8_t *dstBot[] = { m_rgbBuffer + m_sourceWidth * m_sourceHeight * 2, 0, 0, 0 }; int dstStride[] = { (int)m_sourceWidth * 4, 0, 0, 0 }; Index: xbmc-16.0-Jarvis/xbmc/cores/VideoRenderers/LinuxRendererGLES.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/VideoRenderers/LinuxRendererGLES.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/VideoRenderers/LinuxRendererGLES.cpp @@ -2006,8 +2006,8 @@ void CLinuxRendererGLES::UploadYV12Textu #endif { m_sw_context = sws_getCachedContext(m_sw_context, - im->width, im->height, PIX_FMT_YUV420P, - im->width, im->height, PIX_FMT_RGBA, + im->width, im->height, AV_PIX_FMT_YUV420P, + im->width, im->height, AV_PIX_FMT_RGBA, SWS_FAST_BILINEAR, NULL, NULL, NULL); uint8_t *src[] = { im->plane[0], im->plane[1], im->plane[2], 0 }; Index: xbmc-16.0-Jarvis/xbmc/cores/VideoRenderers/WinRenderer.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/cores/VideoRenderers/WinRenderer.cpp +++ xbmc-16.0-Jarvis/xbmc/cores/VideoRenderers/WinRenderer.cpp @@ -94,16 +94,16 @@ CWinRenderer::~CWinRenderer() UnInit(); } -static enum PixelFormat PixelFormatFromFormat(ERenderFormat format) +static enum AVPixelFormat PixelFormatFromFormat(ERenderFormat format) { - if (format == RENDER_FMT_DXVA) return PIX_FMT_NV12; - if (format == RENDER_FMT_YUV420P) return PIX_FMT_YUV420P; - if (format == RENDER_FMT_YUV420P10) return PIX_FMT_YUV420P10; - if (format == RENDER_FMT_YUV420P16) return PIX_FMT_YUV420P16; - if (format == RENDER_FMT_NV12) return PIX_FMT_NV12; - if (format == RENDER_FMT_UYVY422) return PIX_FMT_UYVY422; - if (format == RENDER_FMT_YUYV422) return PIX_FMT_YUYV422; - return PIX_FMT_NONE; + if (format == RENDER_FMT_DXVA) return AV_PIX_FMT_NV12; + if (format == RENDER_FMT_YUV420P) return AV_PIX_FMT_YUV420P; + if (format == RENDER_FMT_YUV420P10) return AV_PIX_FMT_YUV420P10; + if (format == RENDER_FMT_YUV420P16) return AV_PIX_FMT_YUV420P16; + if (format == RENDER_FMT_NV12) return AV_PIX_FMT_NV12; + if (format == RENDER_FMT_UYVY422) return AV_PIX_FMT_UYVY422; + if (format == RENDER_FMT_YUYV422) return AV_PIX_FMT_YUYV422; + return AV_PIX_FMT_NONE; } void CWinRenderer::ManageTextures() @@ -719,13 +719,13 @@ void CWinRenderer::Render(DWORD flags) void CWinRenderer::RenderSW() { - enum PixelFormat format = PixelFormatFromFormat(m_format); + enum AVPixelFormat format = PixelFormatFromFormat(m_format); // 1. convert yuv to rgb m_sw_scale_ctx = sws_getCachedContext(m_sw_scale_ctx, m_sourceWidth, m_sourceHeight, format, - m_sourceWidth, m_sourceHeight, PIX_FMT_BGRA, - SWS_FAST_BILINEAR | SwScaleCPUFlags(), NULL, NULL, NULL); + m_sourceWidth, m_sourceHeight, AV_PIX_FMT_BGRA, + SWS_FAST_BILINEAR, NULL, NULL, NULL); YUVBuffer* buf = (YUVBuffer*)m_VideoBuffers[m_iYV12RenderBuffer]; Index: xbmc-16.0-Jarvis/xbmc/pictures/Picture.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/pictures/Picture.cpp +++ xbmc-16.0-Jarvis/xbmc/pictures/Picture.cpp @@ -342,9 +342,9 @@ bool CPicture::ScaleImage(uint8_t *in_pi uint8_t *out_pixels, unsigned int out_width, unsigned int out_height, unsigned int out_pitch, CPictureScalingAlgorithm::Algorithm scalingAlgorithm /* = CPictureScalingAlgorithm::NoAlgorithm */) { - struct SwsContext *context = sws_getContext(in_width, in_height, PIX_FMT_BGRA, - out_width, out_height, PIX_FMT_BGRA, - CPictureScalingAlgorithm::ToSwscale(scalingAlgorithm) | SwScaleCPUFlags(), NULL, NULL, NULL); + struct SwsContext *context = sws_getContext(in_width, in_height, AV_PIX_FMT_BGRA, + out_width, out_height, AV_PIX_FMT_BGRA, + CPictureScalingAlgorithm::ToSwscale(scalingAlgorithm), NULL, NULL, NULL); uint8_t *src[] = { in_pixels, 0, 0, 0 }; int srcStride[] = { (int)in_pitch, 0, 0, 0 }; Index: xbmc-16.0-Jarvis/xbmc/video/FFmpegVideoDecoder.cpp =================================================================== --- xbmc-16.0-Jarvis.orig/xbmc/video/FFmpegVideoDecoder.cpp +++ xbmc-16.0-Jarvis/xbmc/video/FFmpegVideoDecoder.cpp @@ -252,7 +252,7 @@ bool FFmpegVideoDecoder::nextFrame( CBas return false; // Due to a bug in swsscale we need to allocate one extra line of data - if ( avpicture_alloc( m_pFrameRGB, PIX_FMT_RGB32, m_frameRGBwidth, m_frameRGBheight + 1 ) < 0 ) + if ( avpicture_alloc( m_pFrameRGB, AV_PIX_FMT_RGB32, m_frameRGBwidth, m_frameRGBheight + 1 ) < 0 ) return false; } @@ -287,7 +287,7 @@ bool FFmpegVideoDecoder::nextFrame( CBas // We got the video frame, render it into the picture buffer struct SwsContext * context = sws_getContext( m_pCodecCtx->width, m_pCodecCtx->height, m_pCodecCtx->pix_fmt, - m_frameRGBwidth, m_frameRGBheight, PIX_FMT_RGB32, SWS_FAST_BILINEAR, NULL, NULL, NULL ); + m_frameRGBwidth, m_frameRGBheight, AV_PIX_FMT_RGB32, SWS_FAST_BILINEAR, NULL, NULL, NULL ); sws_scale( context, m_pFrame->data, m_pFrame->linesize, 0, m_pCodecCtx->height, m_pFrameRGB->data, m_pFrameRGB->linesize );
shibajee/buildroot
package/kodi/0006-ffmpeg30.patch
patch
mit
30,186
From f63563615e357b7d794a38e1d37276c325d1466f Mon Sep 17 00:00:00 2001 From: popcornmix <popcornmix@gmail.com> Date: Sat, 7 May 2016 13:47:42 +0100 Subject: [PATCH] [exif] Fix for out-of-memory errors with large numbers of jpegs This reverts part of https://github.com/xbmc/xbmc/pull/7472 Basically the commit made the 4 comments in the exif block increase from 2K to 64K each, so you now need 256K per photo. When opening a folder exif information for all photos is extracted. So, for a folder of 5000 jpegs, 1.2GB of RAM is needed just for the comments. As a 64K comment string is of no use to kodi, just truncate them to 2K like we used to. See: http://trac.kodi.tv/ticket/16193 http://forum.kodi.tv/showthread.php?tid=251908 Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> (backported from upstream commit in master branch: https://github.com/xbmc/xbmc/commit/f63563615e357b7d794a38e1d37276c325d1466f) --- lib/libexif/libexif.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/libexif/libexif.h b/lib/libexif/libexif.h index aa8da07..519ac30 100644 --- a/lib/libexif/libexif.h +++ b/lib/libexif/libexif.h @@ -81,7 +81,7 @@ typedef struct { #define EXIF_COMMENT_CHARSET_UNICODE 3 // Exif: Unicode (UTF-16) #define EXIF_COMMENT_CHARSET_JIS 4 // Exif: JIS X208-1990 -#define MAX_COMMENT 65533 // 2 bytes - 2 for the length param +#define MAX_COMMENT 2000 #define MAX_DATE_COPIES 10 typedef struct { -- 2.8.1
shibajee/buildroot
package/kodi/0007-exif-Fix-for-out-of-memory-errors-with-large-numbers.patch
patch
mit
1,466
From 78571ed421e3fd3d5244cd76670e4e1bab69132f Mon Sep 17 00:00:00 2001 From: Bernd Kuhls <bernd.kuhls@t-online.de> Date: Fri, 27 May 2016 17:30:28 +0200 Subject: [PATCH 1/1] Fix nullpadding issue when reading certain id3v1 tags backported from upstream commit to master branch: https://github.com/xbmc/xbmc/commit/cdabf9dd9e82f4b2d639fb769db08227a7c52046 to fix problems with taglib-1.11: http://trac.kodi.tv/ticket/16454 https://github.com/taglib/taglib/issues/741#issuecomment-218059031 Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> --- xbmc/music/tags/TagLoaderTagLib.cpp | 21 --------------------- xbmc/music/tags/TagLoaderTagLib.h | 3 +++ 2 files changed, 3 insertions(+), 21 deletions(-) diff --git a/xbmc/music/tags/TagLoaderTagLib.cpp b/xbmc/music/tags/TagLoaderTagLib.cpp index b78a591..0fc346a 100644 --- a/xbmc/music/tags/TagLoaderTagLib.cpp +++ b/xbmc/music/tags/TagLoaderTagLib.cpp @@ -46,31 +46,12 @@ #include "utils/URIUtils.h" #include "utils/log.h" #include "utils/StringUtils.h" -#include "utils/CharsetConverter.h" #include "utils/Base64.h" #include "settings/AdvancedSettings.h" using namespace TagLib; using namespace MUSIC_INFO; -template<class T> -class TagStringHandler : public T -{ -public: - TagStringHandler() {} - virtual ~TagStringHandler() {} - virtual String parse(const ByteVector &data) const - { - std::string strSource(data.data(), data.size()); - std::string strUTF8; - g_charsetConverter.unknownToUTF8(strSource, strUTF8); - return String(strUTF8, String::UTF8); - } -}; - -static const TagStringHandler<ID3v1::StringHandler> ID3v1StringHandler; -static const TagStringHandler<ID3v2::Latin1StringHandler> ID3v2StringHandler; - CTagLoaderTagLib::CTagLoaderTagLib() { } @@ -824,8 +805,6 @@ bool CTagLoaderTagLib::Load(const std::string& strFileName, CMusicInfoTag& tag, return false; } - ID3v1::Tag::setStringHandler(&ID3v1StringHandler); - ID3v2::Tag::setLatin1StringHandler(&ID3v2StringHandler); TagLib::File* file = NULL; TagLib::APE::File* apeFile = NULL; TagLib::ASF::File* asfFile = NULL; diff --git a/xbmc/music/tags/TagLoaderTagLib.h b/xbmc/music/tags/TagLoaderTagLib.h index f83ea4f..0edb84f 100644 --- a/xbmc/music/tags/TagLoaderTagLib.h +++ b/xbmc/music/tags/TagLoaderTagLib.h @@ -44,6 +44,9 @@ #include <taglib/mp4tag.h> #include "ImusicInfoTagLoader.h" +#include <string> +#include <vector> + namespace MUSIC_INFO { class CMusicInfoTag; -- 2.8.1
shibajee/buildroot
package/kodi/0008-Fix-nullpadding-issue-when-reading-certain-id3v1-tag.patch
patch
mit
2,506
From 8f82e51563f0e1bc9b7a8adf669ad2b66e7ce3e5 Mon Sep 17 00:00:00 2001 From: Bernd Kuhls <bernd.kuhls@t-online.de> Date: Thu, 28 Apr 2016 17:17:40 +0200 Subject: [PATCH] lib/cximage-6.0: fix compilation with gcc6 For a quick fix I renamed min() to cxmin() and max() to cxmax() to prevent the conflict with the gcc definition. Forum thread for reference: http://forum.kodi.tv/showthread.php?tid=263884 Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> (Patch sent upstream: https://github.com/xbmc/xbmc/pull/9703) --- lib/cximage-6.0/CxImage/ximabmp.cpp | 6 +- lib/cximage-6.0/CxImage/ximadef.h | 8 +- lib/cximage-6.0/CxImage/ximadsp.cpp | 182 +++++++++++++++++------------------ lib/cximage-6.0/CxImage/ximage.cpp | 4 +- lib/cximage-6.0/CxImage/ximagif.cpp | 6 +- lib/cximage-6.0/CxImage/ximahist.cpp | 12 +-- lib/cximage-6.0/CxImage/ximaint.cpp | 8 +- lib/cximage-6.0/CxImage/ximaiter.h | 4 +- lib/cximage-6.0/CxImage/ximajbg.cpp | 2 +- lib/cximage-6.0/CxImage/ximapal.cpp | 14 +-- lib/cximage-6.0/CxImage/ximapng.cpp | 12 +-- lib/cximage-6.0/CxImage/ximaraw.cpp | 4 +- lib/cximage-6.0/CxImage/ximasel.cpp | 50 +++++----- lib/cximage-6.0/CxImage/ximath.cpp | 8 +- lib/cximage-6.0/CxImage/ximatif.cpp | 6 +- lib/cximage-6.0/CxImage/ximatran.cpp | 138 +++++++++++++------------- lib/cximage-6.0/CxImage/ximawnd.cpp | 16 +-- 17 files changed, 236 insertions(+), 244 deletions(-) diff --git a/lib/cximage-6.0/CxImage/ximabmp.cpp b/lib/cximage-6.0/CxImage/ximabmp.cpp index 726ff91..55842b1 100644 --- a/lib/cximage-6.0/CxImage/ximabmp.cpp +++ b/lib/cximage-6.0/CxImage/ximabmp.cpp @@ -46,7 +46,7 @@ bool CxImageBMP::Encode(CxFile * hFile) bihtoh(&infohdr); // Write the file header - hFile->Write(&hdr,min(14,sizeof(BITMAPFILEHEADER)),1); + hFile->Write(&hdr,cxmin(14,sizeof(BITMAPFILEHEADER)),1); hFile->Write(&infohdr,sizeof(BITMAPINFOHEADER),1); //and DIB+ALPHA interlaced BYTE *srcalpha = AlphaGetPointer(); @@ -64,7 +64,7 @@ bool CxImageBMP::Encode(CxFile * hFile) #endif //CXIMAGE_SUPPORT_ALPHA { // Write the file header - hFile->Write(&hdr,min(14,sizeof(BITMAPFILEHEADER)),1); + hFile->Write(&hdr,cxmin(14,sizeof(BITMAPFILEHEADER)),1); //copy attributes memcpy(pDib,&head,sizeof(BITMAPINFOHEADER)); bihtoh((BITMAPINFOHEADER*)pDib); @@ -86,7 +86,7 @@ bool CxImageBMP::Decode(CxFile * hFile) BITMAPFILEHEADER bf; DWORD off = hFile->Tell(); //<CSC> cx_try { - if (hFile->Read(&bf,min(14,sizeof(bf)),1)==0) cx_throw("Not a BMP"); + if (hFile->Read(&bf,cxmin(14,sizeof(bf)),1)==0) cx_throw("Not a BMP"); bf.bfSize = my_ntohl(bf.bfSize); bf.bfOffBits = my_ntohl(bf.bfOffBits); diff --git a/lib/cximage-6.0/CxImage/ximadef.h b/lib/cximage-6.0/CxImage/ximadef.h index fe383bf..53ea452 100644 --- a/lib/cximage-6.0/CxImage/ximadef.h +++ b/lib/cximage-6.0/CxImage/ximadef.h @@ -53,12 +53,8 @@ #define CXIMAGE_SUPPORT_WINDOWS 0 #endif -#ifndef min -#define min(a,b) (((a)<(b))?(a):(b)) -#endif -#ifndef max -#define max(a,b) (((a)>(b))?(a):(b)) -#endif +#define cxmin(a,b) (((a)<(b))?(a):(b)) +#define cxmax(a,b) (((a)>(b))?(a):(b)) #ifndef PI #define PI 3.141592653589793f diff --git a/lib/cximage-6.0/CxImage/ximadsp.cpp b/lib/cximage-6.0/CxImage/ximadsp.cpp index 8425bb2..813253b 100644 --- a/lib/cximage-6.0/CxImage/ximadsp.cpp +++ b/lib/cximage-6.0/CxImage/ximadsp.cpp @@ -389,8 +389,8 @@ RGBQUAD CxImage::RGBtoHSL(RGBQUAD lRGBColor) G = lRGBColor.rgbGreen; B = lRGBColor.rgbBlue; - cMax = max( max(R,G), B); /* calculate lightness */ - cMin = min( min(R,G), B); + cMax = cxmax( cxmax(R,G), B); /* calculate lightness */ + cMin = cxmin( cxmin(R,G), B); L = (BYTE)((((cMax+cMin)*HSLMAX)+RGBMAX)/(2*RGBMAX)); if (cMax==cMin){ /* r=g=b --> achromatic case */ @@ -489,9 +489,9 @@ RGBQUAD CxImage::YUVtoRGB(RGBQUAD lYUVColor) G = (int)( Y - 0.344f * U - 0.714f * V); B = (int)( Y + 1.770f * U); - R= min(255,max(0,R)); - G= min(255,max(0,G)); - B= min(255,max(0,B)); + R= cxmin(255,cxmax(0,R)); + G= cxmin(255,cxmax(0,G)); + B= cxmin(255,cxmax(0,B)); RGBQUAD rgb={(BYTE)B,(BYTE)G,(BYTE)R,0}; return rgb; } @@ -510,9 +510,9 @@ RGBQUAD CxImage::RGBtoYUV(RGBQUAD lRGBColor) U = (int)((B-Y) * 0.565f + 128); V = (int)((R-Y) * 0.713f + 128); - Y= min(255,max(0,Y)); - U= min(255,max(0,U)); - V= min(255,max(0,V)); + Y= cxmin(255,cxmax(0,Y)); + U= cxmin(255,cxmax(0,U)); + V= cxmin(255,cxmax(0,V)); RGBQUAD yuv={(BYTE)V,(BYTE)U,(BYTE)Y,0}; return yuv; } @@ -528,9 +528,9 @@ RGBQUAD CxImage::YIQtoRGB(RGBQUAD lYIQColor) G = (int)( Y - 0.273f * I - 0.647f * Q); B = (int)( Y - 1.104f * I + 1.701f * Q); - R= min(255,max(0,R)); - G= min(255,max(0,G)); - B= min(255,max(0,B)); + R= cxmin(255,cxmax(0,R)); + G= cxmin(255,cxmax(0,G)); + B= cxmin(255,cxmax(0,B)); RGBQUAD rgb={(BYTE)B,(BYTE)G,(BYTE)R,0}; return rgb; } @@ -546,9 +546,9 @@ RGBQUAD CxImage::RGBtoYIQ(RGBQUAD lRGBColor) I = (int)( 0.5960f * R - 0.2742f * G - 0.3219f * B + 128); Q = (int)( 0.2109f * R - 0.5229f * G + 0.3120f * B + 128); - Y= min(255,max(0,Y)); - I= min(255,max(0,I)); - Q= min(255,max(0,Q)); + Y= cxmin(255,cxmax(0,Y)); + I= cxmin(255,cxmax(0,I)); + Q= cxmin(255,cxmax(0,Q)); RGBQUAD yiq={(BYTE)Q,(BYTE)I,(BYTE)Y,0}; return yiq; } @@ -565,9 +565,9 @@ RGBQUAD CxImage::XYZtoRGB(RGBQUAD lXYZColor) G = (int)( -0.969256f * X + 1.875992f * Y + 0.041556f * Z * k); B = (int)( 0.055648f * X - 0.204043f * Y + 1.057311f * Z * k); - R= min(255,max(0,R)); - G= min(255,max(0,G)); - B= min(255,max(0,B)); + R= cxmin(255,cxmax(0,R)); + G= cxmin(255,cxmax(0,G)); + B= cxmin(255,cxmax(0,B)); RGBQUAD rgb={(BYTE)B,(BYTE)G,(BYTE)R,0}; return rgb; } @@ -583,9 +583,9 @@ RGBQUAD CxImage::RGBtoXYZ(RGBQUAD lRGBColor) Y = (int)( 0.212671f * R + 0.715160f * G + 0.072169f * B); Z = (int)((0.019334f * R + 0.119193f * G + 0.950227f * B)*0.918483657f); - //X= min(255,max(0,X)); - //Y= min(255,max(0,Y)); - //Z= min(255,max(0,Z)); + //X= cxmin(255,cxmax(0,X)); + //Y= cxmin(255,cxmax(0,Y)); + //Z= cxmin(255,cxmax(0,Z)); RGBQUAD xyz={(BYTE)Z,(BYTE)Y,(BYTE)X,0}; return xyz; } @@ -707,7 +707,7 @@ bool CxImage::Light(long brightness, long contrast) BYTE cTable[256]; //<nipper> for (int i=0;i<256;i++) { - cTable[i] = (BYTE)max(0,min(255,(int)((i-128)*c + brightness + 0.5f))); + cTable[i] = (BYTE)cxmax(0,cxmin(255,(int)((i-128)*c + brightness + 0.5f))); } return Lut(cTable); @@ -830,11 +830,11 @@ bool CxImage::Filter(long* kernel, long Ksize, long Kfactor, long Koffset) } } if (Kfactor==0 || ksumcur==0){ - cPtr2[iY1] = (BYTE)min(255, max(0,(int)(b + Koffset))); + cPtr2[iY1] = (BYTE)cxmin(255, cxmax(0,(int)(b + Koffset))); } else if (ksumtot == ksumcur) { - cPtr2[iY1] = (BYTE)min(255, max(0,(int)(b/Kfactor + Koffset))); + cPtr2[iY1] = (BYTE)cxmin(255, cxmax(0,(int)(b/Kfactor + Koffset))); } else { - cPtr2[iY1] = (BYTE)min(255, max(0,(int)((b*ksumtot)/(ksumcur*Kfactor) + Koffset))); + cPtr2[iY1] = (BYTE)cxmin(255, cxmax(0,(int)((b*ksumtot)/(ksumcur*Kfactor) + Koffset))); } } } @@ -863,17 +863,17 @@ bool CxImage::Filter(long* kernel, long Ksize, long Kfactor, long Koffset) } } if (Kfactor==0 || ksumcur==0){ - c.rgbRed = (BYTE)min(255, max(0,(int)(r + Koffset))); - c.rgbGreen = (BYTE)min(255, max(0,(int)(g + Koffset))); - c.rgbBlue = (BYTE)min(255, max(0,(int)(b + Koffset))); + c.rgbRed = (BYTE)cxmin(255, cxmax(0,(int)(r + Koffset))); + c.rgbGreen = (BYTE)cxmin(255, cxmax(0,(int)(g + Koffset))); + c.rgbBlue = (BYTE)cxmin(255, cxmax(0,(int)(b + Koffset))); } else if (ksumtot == ksumcur) { - c.rgbRed = (BYTE)min(255, max(0,(int)(r/Kfactor + Koffset))); - c.rgbGreen = (BYTE)min(255, max(0,(int)(g/Kfactor + Koffset))); - c.rgbBlue = (BYTE)min(255, max(0,(int)(b/Kfactor + Koffset))); + c.rgbRed = (BYTE)cxmin(255, cxmax(0,(int)(r/Kfactor + Koffset))); + c.rgbGreen = (BYTE)cxmin(255, cxmax(0,(int)(g/Kfactor + Koffset))); + c.rgbBlue = (BYTE)cxmin(255, cxmax(0,(int)(b/Kfactor + Koffset))); } else { - c.rgbRed = (BYTE)min(255, max(0,(int)((r*ksumtot)/(ksumcur*Kfactor) + Koffset))); - c.rgbGreen = (BYTE)min(255, max(0,(int)((g*ksumtot)/(ksumcur*Kfactor) + Koffset))); - c.rgbBlue = (BYTE)min(255, max(0,(int)((b*ksumtot)/(ksumcur*Kfactor) + Koffset))); + c.rgbRed = (BYTE)cxmin(255, cxmax(0,(int)((r*ksumtot)/(ksumcur*Kfactor) + Koffset))); + c.rgbGreen = (BYTE)cxmin(255, cxmax(0,(int)((g*ksumtot)/(ksumcur*Kfactor) + Koffset))); + c.rgbBlue = (BYTE)cxmin(255, cxmax(0,(int)((b*ksumtot)/(ksumcur*Kfactor) + Koffset))); } tmp.BlindSetPixelColor(x,y,c); } @@ -1078,8 +1078,8 @@ bool CxImage::Edge(long Ksize) // void CxImage::Mix(CxImage & imgsrc2, ImageOpType op, long lXOffset, long lYOffset, bool bMixAlpha) { - long lWide = min(GetWidth(),imgsrc2.GetWidth()-lXOffset); - long lHeight = min(GetHeight(),imgsrc2.GetHeight()-lYOffset); + long lWide = cxmin(GetWidth(),imgsrc2.GetWidth()-lXOffset); + long lHeight = cxmin(GetHeight(),imgsrc2.GetHeight()-lYOffset); bool bEditAlpha = imgsrc2.AlphaIsValid() & bMixAlpha; @@ -1112,16 +1112,16 @@ void CxImage::Mix(CxImage & imgsrc2, ImageOpType op, long lXOffset, long lYOffse if (bEditAlpha) rgbDest.rgbReserved = (BYTE)((rgb1.rgbReserved+rgb2.rgbReserved)/2); break; case OpAdd: - rgbDest.rgbBlue = (BYTE)max(0,min(255,rgb1.rgbBlue+rgb2.rgbBlue)); - rgbDest.rgbGreen = (BYTE)max(0,min(255,rgb1.rgbGreen+rgb2.rgbGreen)); - rgbDest.rgbRed = (BYTE)max(0,min(255,rgb1.rgbRed+rgb2.rgbRed)); - if (bEditAlpha) rgbDest.rgbReserved = (BYTE)max(0,min(255,rgb1.rgbReserved+rgb2.rgbReserved)); + rgbDest.rgbBlue = (BYTE)cxmax(0,cxmin(255,rgb1.rgbBlue+rgb2.rgbBlue)); + rgbDest.rgbGreen = (BYTE)cxmax(0,cxmin(255,rgb1.rgbGreen+rgb2.rgbGreen)); + rgbDest.rgbRed = (BYTE)cxmax(0,cxmin(255,rgb1.rgbRed+rgb2.rgbRed)); + if (bEditAlpha) rgbDest.rgbReserved = (BYTE)cxmax(0,cxmin(255,rgb1.rgbReserved+rgb2.rgbReserved)); break; case OpSub: - rgbDest.rgbBlue = (BYTE)max(0,min(255,rgb1.rgbBlue-rgb2.rgbBlue)); - rgbDest.rgbGreen = (BYTE)max(0,min(255,rgb1.rgbGreen-rgb2.rgbGreen)); - rgbDest.rgbRed = (BYTE)max(0,min(255,rgb1.rgbRed-rgb2.rgbRed)); - if (bEditAlpha) rgbDest.rgbReserved = (BYTE)max(0,min(255,rgb1.rgbReserved-rgb2.rgbReserved)); + rgbDest.rgbBlue = (BYTE)cxmax(0,cxmin(255,rgb1.rgbBlue-rgb2.rgbBlue)); + rgbDest.rgbGreen = (BYTE)cxmax(0,cxmin(255,rgb1.rgbGreen-rgb2.rgbGreen)); + rgbDest.rgbRed = (BYTE)cxmax(0,cxmin(255,rgb1.rgbRed-rgb2.rgbRed)); + if (bEditAlpha) rgbDest.rgbReserved = (BYTE)cxmax(0,cxmin(255,rgb1.rgbReserved-rgb2.rgbReserved)); break; case OpAnd: rgbDest.rgbBlue = (BYTE)(rgb1.rgbBlue&rgb2.rgbBlue); @@ -1202,11 +1202,11 @@ void CxImage::Mix(CxImage & imgsrc2, ImageOpType op, long lXOffset, long lYOffse double dSmallAmt = dSmall*((double)rgb2.rgbBlue); if( lAverage < lThresh+1){ - rgbDest.rgbBlue = (BYTE)max(0,min(255,(int)(dLarge*((double)rgb1.rgbBlue) + + rgbDest.rgbBlue = (BYTE)cxmax(0,cxmin(255,(int)(dLarge*((double)rgb1.rgbBlue) + dSmallAmt))); - rgbDest.rgbGreen = (BYTE)max(0,min(255,(int)(dLarge*((double)rgb1.rgbGreen) + + rgbDest.rgbGreen = (BYTE)cxmax(0,cxmin(255,(int)(dLarge*((double)rgb1.rgbGreen) + dSmallAmt))); - rgbDest.rgbRed = (BYTE)max(0,min(255,(int)(dLarge*((double)rgb1.rgbRed) + + rgbDest.rgbRed = (BYTE)cxmax(0,cxmin(255,(int)(dLarge*((double)rgb1.rgbRed) + dSmallAmt))); } else @@ -1274,9 +1274,9 @@ bool CxImage::ShiftRGB(long r, long g, long b) #endif //CXIMAGE_SUPPORT_SELECTION { color = BlindGetPixelColor(x,y); - color.rgbRed = (BYTE)max(0,min(255,(int)(color.rgbRed + r))); - color.rgbGreen = (BYTE)max(0,min(255,(int)(color.rgbGreen + g))); - color.rgbBlue = (BYTE)max(0,min(255,(int)(color.rgbBlue + b))); + color.rgbRed = (BYTE)cxmax(0,cxmin(255,(int)(color.rgbRed + r))); + color.rgbGreen = (BYTE)cxmax(0,cxmin(255,(int)(color.rgbGreen + g))); + color.rgbBlue = (BYTE)cxmax(0,cxmin(255,(int)(color.rgbBlue + b))); BlindSetPixelColor(x,y,color); } } @@ -1284,9 +1284,9 @@ bool CxImage::ShiftRGB(long r, long g, long b) } else { for(DWORD j=0; j<head.biClrUsed; j++){ color = GetPaletteColor((BYTE)j); - color.rgbRed = (BYTE)max(0,min(255,(int)(color.rgbRed + r))); - color.rgbGreen = (BYTE)max(0,min(255,(int)(color.rgbGreen + g))); - color.rgbBlue = (BYTE)max(0,min(255,(int)(color.rgbBlue + b))); + color.rgbRed = (BYTE)cxmax(0,cxmin(255,(int)(color.rgbRed + r))); + color.rgbGreen = (BYTE)cxmax(0,cxmin(255,(int)(color.rgbGreen + g))); + color.rgbBlue = (BYTE)cxmax(0,cxmin(255,(int)(color.rgbBlue + b))); SetPaletteColor((BYTE)j,color); } } @@ -1310,7 +1310,7 @@ bool CxImage::Gamma(float gamma) BYTE cTable[256]; //<nipper> for (int i=0;i<256;i++) { - cTable[i] = (BYTE)max(0,min(255,(int)( pow((double)i, dinvgamma) / dMax))); + cTable[i] = (BYTE)cxmax(0,cxmin(255,(int)( pow((double)i, dinvgamma) / dMax))); } return Lut(cTable); @@ -1337,21 +1337,21 @@ bool CxImage::GammaRGB(float gammaR, float gammaG, float gammaB) dMax = pow(255.0, dinvgamma) / 255.0; BYTE cTableR[256]; for (i=0;i<256;i++) { - cTableR[i] = (BYTE)max(0,min(255,(int)( pow((double)i, dinvgamma) / dMax))); + cTableR[i] = (BYTE)cxmax(0,cxmin(255,(int)( pow((double)i, dinvgamma) / dMax))); } dinvgamma = 1/gammaG; dMax = pow(255.0, dinvgamma) / 255.0; BYTE cTableG[256]; for (i=0;i<256;i++) { - cTableG[i] = (BYTE)max(0,min(255,(int)( pow((double)i, dinvgamma) / dMax))); + cTableG[i] = (BYTE)cxmax(0,cxmin(255,(int)( pow((double)i, dinvgamma) / dMax))); } dinvgamma = 1/gammaB; dMax = pow(255.0, dinvgamma) / 255.0; BYTE cTableB[256]; for (i=0;i<256;i++) { - cTableB[i] = (BYTE)max(0,min(255,(int)( pow((double)i, dinvgamma) / dMax))); + cTableB[i] = (BYTE)cxmax(0,cxmin(255,(int)( pow((double)i, dinvgamma) / dMax))); } return Lut(cTableR, cTableG, cTableB); @@ -1442,11 +1442,11 @@ bool CxImage::Noise(long level) { color = BlindGetPixelColor(x,y); n=(long)((rand()/(float)RAND_MAX - 0.5)*level); - color.rgbRed = (BYTE)max(0,min(255,(int)(color.rgbRed + n))); + color.rgbRed = (BYTE)cxmax(0,cxmin(255,(int)(color.rgbRed + n))); n=(long)((rand()/(float)RAND_MAX - 0.5)*level); - color.rgbGreen = (BYTE)max(0,min(255,(int)(color.rgbGreen + n))); + color.rgbGreen = (BYTE)cxmax(0,cxmin(255,(int)(color.rgbGreen + n))); n=(long)((rand()/(float)RAND_MAX - 0.5)*level); - color.rgbBlue = (BYTE)max(0,min(255,(int)(color.rgbBlue + n))); + color.rgbBlue = (BYTE)cxmax(0,cxmin(255,(int)(color.rgbBlue + n))); BlindSetPixelColor(x,y,color); } } @@ -1561,8 +1561,8 @@ bool CxImage::FFT2(CxImage* srcReal, CxImage* srcImag, CxImage* dstReal, CxImage //DFT buffers double *real2,*imag2; - real2 = (double*)malloc(max(w,h) * sizeof(double)); - imag2 = (double*)malloc(max(w,h) * sizeof(double)); + real2 = (double*)malloc(cxmax(w,h) * sizeof(double)); + imag2 = (double*)malloc(cxmax(w,h) * sizeof(double)); /* Transform the rows */ real = (double *)malloc(w * sizeof(double)); @@ -1617,7 +1617,7 @@ bool CxImage::FFT2(CxImage* srcReal, CxImage* srcImag, CxImage* dstReal, CxImage /* converting from double to byte, there is a HUGE loss in the dynamics "nn" tries to keep an acceptable SNR, but 8bit=48dB: don't ask more */ - double nn=pow((double)2,(double)log((double)max(w,h))/(double)log((double)2)-4); + double nn=pow((double)2,(double)log((double)cxmax(w,h))/(double)log((double)2)-4); //reversed gain for reversed transform if (direction==-1) nn=1/nn; //bMagnitude : just to see it on the screen @@ -1626,15 +1626,15 @@ bool CxImage::FFT2(CxImage* srcReal, CxImage* srcImag, CxImage* dstReal, CxImage for (j=0;j<h;j++) { for (k=0;k<w;k++) { if (bMagnitude){ - tmpReal->SetPixelIndex(k,j,(BYTE)max(0,min(255,(nn*(3+log(_cabs(grid[k][j]))))))); + tmpReal->SetPixelIndex(k,j,(BYTE)cxmax(0,cxmin(255,(nn*(3+log(_cabs(grid[k][j]))))))); if (grid[k][j].x==0){ - tmpImag->SetPixelIndex(k,j,(BYTE)max(0,min(255,(128+(atan(grid[k][j].y/0.0000000001)*nn))))); + tmpImag->SetPixelIndex(k,j,(BYTE)cxmax(0,cxmin(255,(128+(atan(grid[k][j].y/0.0000000001)*nn))))); } else { - tmpImag->SetPixelIndex(k,j,(BYTE)max(0,min(255,(128+(atan(grid[k][j].y/grid[k][j].x)*nn))))); + tmpImag->SetPixelIndex(k,j,(BYTE)cxmax(0,cxmin(255,(128+(atan(grid[k][j].y/grid[k][j].x)*nn))))); } } else { - tmpReal->SetPixelIndex(k,j,(BYTE)max(0,min(255,(128 + grid[k][j].x*nn)))); - tmpImag->SetPixelIndex(k,j,(BYTE)max(0,min(255,(128 + grid[k][j].y*nn)))); + tmpReal->SetPixelIndex(k,j,(BYTE)cxmax(0,cxmin(255,(128 + grid[k][j].x*nn)))); + tmpImag->SetPixelIndex(k,j,(BYTE)cxmax(0,cxmin(255,(128 + grid[k][j].y*nn)))); } } } @@ -1922,7 +1922,7 @@ bool CxImage::RepairChannel(CxImage *ch, float radius) correction = ((1.0+iy*iy)*ixx - ix*iy*ixy + (1.0+ix*ix)*iyy)/(1.0+ix*ix+iy*iy); - tmp.BlindSetPixelIndex(x,y,(BYTE)min(255,max(0,(xy0 + radius * correction + 0.5)))); + tmp.BlindSetPixelIndex(x,y,(BYTE)cxmin(255,cxmax(0,(xy0 + radius * correction + 0.5)))); } } @@ -1943,7 +1943,7 @@ bool CxImage::RepairChannel(CxImage *ch, float radius) correction = ((1.0+iy*iy)*ixx - ix*iy*ixy + (1.0+ix*ix)*iyy)/(1.0+ix*ix+iy*iy); - tmp.BlindSetPixelIndex(x,y,(BYTE)min(255,max(0,(xy0 + radius * correction + 0.5)))); + tmp.BlindSetPixelIndex(x,y,(BYTE)cxmin(255,cxmax(0,(xy0 + radius * correction + 0.5)))); } } for (x=0;x<=w;x+=w){ @@ -1963,7 +1963,7 @@ bool CxImage::RepairChannel(CxImage *ch, float radius) correction = ((1.0+iy*iy)*ixx - ix*iy*ixy + (1.0+ix*ix)*iyy)/(1.0+ix*ix+iy*iy); - tmp.BlindSetPixelIndex(x,y,(BYTE)min(255,max(0,(xy0 + radius * correction + 0.5)))); + tmp.BlindSetPixelIndex(x,y,(BYTE)cxmin(255,cxmax(0,(xy0 + radius * correction + 0.5)))); } } @@ -2621,8 +2621,8 @@ bool CxImage::SelectiveBlur(float radius, BYTE threshold, CxImage* iDst) } //build the difference mask - BYTE thresh_dw = (BYTE)max( 0 ,(int)(128 - threshold)); - BYTE thresh_up = (BYTE)min(255,(int)(128 + threshold)); + BYTE thresh_dw = (BYTE)cxmax( 0 ,(int)(128 - threshold)); + BYTE thresh_up = (BYTE)cxmin(255,(int)(128 + threshold)); long kernel[]={-100,-100,-100,-100,801,-100,-100,-100,-100}; if (!Tmp.Filter(kernel,3,800,128)){ delete [] pPalette; @@ -2755,7 +2755,7 @@ bool CxImage::UnsharpMask(float radius /*= 5.0*/, float amount /*= 0.5*/, int th if (abs(diff) < threshold){ dest_row[z] = cur_row[z]; } else { - dest_row[z] = (BYTE)min(255, max(0,(int)(cur_row[z] + amount * diff))); + dest_row[z] = (BYTE)cxmin(255, cxmax(0,(int)(cur_row[z] + amount * diff))); } } } @@ -2952,7 +2952,7 @@ bool CxImage::RedEyeRemove(float strength) float a = 1.0f-5.0f*((float)((x-0.5f*(xmax+xmin))*(x-0.5f*(xmax+xmin))+(y-0.5f*(ymax+ymin))*(y-0.5f*(ymax+ymin))))/((float)((xmax-xmin)*(ymax-ymin))); if (a<0) a=0; color = BlindGetPixelColor(x,y); - color.rgbRed = (BYTE)(a*min(color.rgbGreen,color.rgbBlue)+(1.0f-a)*color.rgbRed); + color.rgbRed = (BYTE)(a*cxmin(color.rgbGreen,color.rgbBlue)+(1.0f-a)*color.rgbRed); BlindSetPixelColor(x,y,color); } } @@ -2990,7 +2990,7 @@ bool CxImage::Saturate(const long saturation, const long colorspace) case 1: { for (int i=0;i<256;i++) { - cTable[i] = (BYTE)max(0,min(255,(int)(i + saturation))); + cTable[i] = (BYTE)cxmax(0,cxmin(255,(int)(i + saturation))); } for(long y=ymin; y<ymax; y++){ info.nProgress = (long)(100*(y-ymin)/(ymax-ymin)); @@ -3012,7 +3012,7 @@ bool CxImage::Saturate(const long saturation, const long colorspace) case 2: { for (int i=0;i<256;i++) { - cTable[i] = (BYTE)max(0,min(255,(int)((i-128)*(100 + saturation)/100.0f + 128.5f))); + cTable[i] = (BYTE)cxmax(0,cxmin(255,(int)((i-128)*(100 + saturation)/100.0f + 128.5f))); } for(long y=ymin; y<ymax; y++){ info.nProgress = (long)(100*(y-ymin)/(ymax-ymin)); @@ -3242,10 +3242,10 @@ int CxImage::OptimalThreshold(long method, RECT * pBox, CxImage* pContrastMask) long xmin,xmax,ymin,ymax; if (pBox){ - xmin = max(pBox->left,0); - xmax = min(pBox->right,head.biWidth); - ymin = max(pBox->bottom,0); - ymax = min(pBox->top,head.biHeight); + xmin = cxmax(pBox->left,0); + xmax = cxmin(pBox->right,head.biWidth); + ymin = cxmax(pBox->bottom,0); + ymax = cxmin(pBox->top,head.biHeight); } else { xmin = ymin = 0; xmax = head.biWidth; ymax=head.biHeight; @@ -3463,7 +3463,7 @@ bool CxImage::AdaptiveThreshold(long method, long nBoxSize, CxImage* pContrastMa r.top = r.bottom + nBoxSize; int threshold = OptimalThreshold(method, &r, pContrastMask); if (threshold <0) return false; - mask.SetPixelIndex(x,y,(BYTE)max(0,min(255,nBias+((1.0f-fGlobalLocalBalance)*threshold + fGlobalLocalBalance*globalthreshold)))); + mask.SetPixelIndex(x,y,(BYTE)cxmax(0,cxmin(255,nBias+((1.0f-fGlobalLocalBalance)*threshold + fGlobalLocalBalance*globalthreshold)))); } } @@ -3490,10 +3490,6 @@ bool CxImage::AdaptiveThreshold(long method, long nBoxSize, CxImage* pContrastMa * Note: nOpacity=0 && bSelectFilledArea=true act as a "magic wand" * \return true if everything is ok */ -#if defined(XBMC) && !defined(_WIN32) -int max(int a, int b) { return a > b ? a : b; } -int min(int a, int b) { return a < b ? a : b; } -#endif bool CxImage::FloodFill(const long xStart, const long yStart, const RGBQUAD cFillColor, const BYTE nTolerance, BYTE nOpacity, const bool bSelectFilledArea, const BYTE nSelectionLevel) @@ -3538,8 +3534,8 @@ bool CxImage::FloodFill(const long xStart, const long yStart, const RGBQUAD cFil if (IsIndexed()){ //--- Generic indexed image, no tolerance OR Grayscale image with tolerance BYTE idxRef = GetPixelIndex(xStart,yStart); BYTE idxFill = GetNearestIndex(cFillColor); - BYTE idxMin = (BYTE)min(255, max(0,(int)(idxRef - nTolerance))); - BYTE idxMax = (BYTE)min(255, max(0,(int)(idxRef + nTolerance))); + BYTE idxMin = (BYTE)cxmin(255, cxmax(0,(int)(idxRef - nTolerance))); + BYTE idxMax = (BYTE)cxmin(255, cxmax(0,(int)(idxRef + nTolerance))); while(!q.empty()) { @@ -3575,12 +3571,12 @@ bool CxImage::FloodFill(const long xStart, const long yStart, const RGBQUAD cFil } else { //--- RGB image RGBQUAD cRef = GetPixelColor(xStart,yStart); RGBQUAD cRefMin, cRefMax; - cRefMin.rgbRed = (BYTE)min(255, max(0,(int)(cRef.rgbRed - nTolerance))); - cRefMin.rgbGreen = (BYTE)min(255, max(0,(int)(cRef.rgbGreen - nTolerance))); - cRefMin.rgbBlue = (BYTE)min(255, max(0,(int)(cRef.rgbBlue - nTolerance))); - cRefMax.rgbRed = (BYTE)min(255, max(0,(int)(cRef.rgbRed + nTolerance))); - cRefMax.rgbGreen = (BYTE)min(255, max(0,(int)(cRef.rgbGreen + nTolerance))); - cRefMax.rgbBlue = (BYTE)min(255, max(0,(int)(cRef.rgbBlue + nTolerance))); + cRefMin.rgbRed = (BYTE)cxmin(255, cxmax(0,(int)(cRef.rgbRed - nTolerance))); + cRefMin.rgbGreen = (BYTE)cxmin(255, cxmax(0,(int)(cRef.rgbGreen - nTolerance))); + cRefMin.rgbBlue = (BYTE)cxmin(255, cxmax(0,(int)(cRef.rgbBlue - nTolerance))); + cRefMax.rgbRed = (BYTE)cxmin(255, cxmax(0,(int)(cRef.rgbRed + nTolerance))); + cRefMax.rgbGreen = (BYTE)cxmin(255, cxmax(0,(int)(cRef.rgbGreen + nTolerance))); + cRefMax.rgbBlue = (BYTE)cxmin(255, cxmax(0,(int)(cRef.rgbBlue + nTolerance))); while(!q.empty()) { diff --git a/lib/cximage-6.0/CxImage/ximage.cpp b/lib/cximage-6.0/CxImage/ximage.cpp index e81d3c6..26c6993 100644 --- a/lib/cximage-6.0/CxImage/ximage.cpp +++ b/lib/cximage-6.0/CxImage/ximage.cpp @@ -460,7 +460,7 @@ bool CxImage::CreateFromArray(BYTE* pArray,DWORD dwWidth,DWORD dwHeight,DWORD dw src+=4; } } else { - memcpy(dst,src,min(info.dwEffWidth,dwBytesperline)); + memcpy(dst,src,cxmin(info.dwEffWidth,dwBytesperline)); } } return true; @@ -500,7 +500,7 @@ bool CxImage::CreateFromMatrix(BYTE** ppMatrix,DWORD dwWidth,DWORD dwHeight,DWOR src+=4; } } else { - memcpy(dst,src,min(info.dwEffWidth,dwBytesperline)); + memcpy(dst,src,cxmin(info.dwEffWidth,dwBytesperline)); } } } diff --git a/lib/cximage-6.0/CxImage/ximagif.cpp b/lib/cximage-6.0/CxImage/ximagif.cpp index b89e061..64b1ccc 100644 --- a/lib/cximage-6.0/CxImage/ximagif.cpp +++ b/lib/cximage-6.0/CxImage/ximagif.cpp @@ -478,7 +478,7 @@ bool CxImageGIF::Encode(CxFile * fp, CxImage ** pImages, int pagecount, bool bLo ghost.EncodeHeader(fp); if (m_loops!=1){ - ghost.SetLoops(max(0,m_loops-1)); + ghost.SetLoops(cxmax(0,m_loops-1)); ghost.EncodeLoopExtension(fp); } @@ -1340,10 +1340,10 @@ void CxImageGIF::GetComment(char* sz_comment_out) //////////////////////////////////////////////////////////////////////////////// void CxImageGIF::GifMix(CxImage & imgsrc2, struct_image & imgdesc) { - long ymin = max(0,(long)(GetHeight()-imgdesc.t - imgdesc.h)); + long ymin = cxmax(0,(long)(GetHeight()-imgdesc.t - imgdesc.h)); long ymax = GetHeight()-imgdesc.t; long xmin = imgdesc.l; - long xmax = min(GetWidth(), (DWORD)(imgdesc.l + imgdesc.w)); + long xmax = cxmin(GetWidth(), (DWORD)(imgdesc.l + imgdesc.w)); long ibg2= imgsrc2.GetTransIndex(); BYTE i2; diff --git a/lib/cximage-6.0/CxImage/ximahist.cpp b/lib/cximage-6.0/CxImage/ximahist.cpp index a2aed03..5391107 100644 --- a/lib/cximage-6.0/CxImage/ximahist.cpp +++ b/lib/cximage-6.0/CxImage/ximahist.cpp @@ -110,7 +110,7 @@ bool CxImage::HistogramStretch(long method, double threshold) // calculate LUT BYTE lut[256]; for (x = 0; x <256; x++){ - lut[x] = (BYTE)max(0,min(255,(255 * (x - minc) / (maxc - minc)))); + lut[x] = (BYTE)cxmax(0,cxmin(255,(255 * (x - minc) / (maxc - minc)))); } for (y=0; y<head.biHeight; y++) { @@ -152,7 +152,7 @@ bool CxImage::HistogramStretch(long method, double threshold) // calculate LUT BYTE lut[256]; for (x = 0; x <256; x++){ - lut[x] = (BYTE)max(0,min(255,(255 * (x - minc) / (maxc - minc)))); + lut[x] = (BYTE)cxmax(0,cxmin(255,(255 * (x - minc) / (maxc - minc)))); } // normalize image @@ -225,7 +225,7 @@ bool CxImage::HistogramStretch(long method, double threshold) BYTE range = maxR - minR; if (range != 0) { for (x = 0; x <256; x++){ - lutR[x] = (BYTE)max(0,min(255,(255 * (x - minR) / range))); + lutR[x] = (BYTE)cxmax(0,cxmin(255,(255 * (x - minR) / range))); } } else lutR[minR] = minR; @@ -233,7 +233,7 @@ bool CxImage::HistogramStretch(long method, double threshold) range = maxG - minG; if (range != 0) { for (x = 0; x <256; x++){ - lutG[x] = (BYTE)max(0,min(255,(255 * (x - minG) / range))); + lutG[x] = (BYTE)cxmax(0,cxmin(255,(255 * (x - minG) / range))); } } else lutG[minG] = minG; @@ -241,7 +241,7 @@ bool CxImage::HistogramStretch(long method, double threshold) range = maxB - minB; if (range != 0) { for (x = 0; x <256; x++){ - lutB[x] = (BYTE)max(0,min(255,(255 * (x - minB) / range))); + lutB[x] = (BYTE)cxmax(0,cxmin(255,(255 * (x - minB) / range))); } } else lutB[minB] = minB; @@ -292,7 +292,7 @@ bool CxImage::HistogramStretch(long method, double threshold) // calculate LUT BYTE lut[256]; for (x = 0; x <256; x++){ - lut[x] = (BYTE)max(0,min(255,(255 * (x - minc) / (maxc - minc)))); + lut[x] = (BYTE)cxmax(0,cxmin(255,(255 * (x - minc) / (maxc - minc)))); } for(y=0; y<head.biHeight; y++){ diff --git a/lib/cximage-6.0/CxImage/ximaint.cpp b/lib/cximage-6.0/CxImage/ximaint.cpp index 989d76c..5d49213 100644 --- a/lib/cximage-6.0/CxImage/ximaint.cpp +++ b/lib/cximage-6.0/CxImage/ximaint.cpp @@ -26,8 +26,8 @@ void CxImage::OverflowCoordinates(long &x, long &y, OverflowMethod const ofMetho switch (ofMethod) { case OM_REPEAT: //clip coordinates - x=max(x,0); x=min(x, head.biWidth-1); - y=max(y,0); y=min(y, head.biHeight-1); + x=cxmax(x,0); x=cxmin(x, head.biWidth-1); + y=cxmax(y,0); y=cxmin(y, head.biHeight-1); break; case OM_WRAP: //wrap coordinates @@ -59,8 +59,8 @@ void CxImage::OverflowCoordinates(float &x, float &y, OverflowMethod const ofMet switch (ofMethod) { case OM_REPEAT: //clip coordinates - x=max(x,0); x=min(x, head.biWidth-1); - y=max(y,0); y=min(y, head.biHeight-1); + x=cxmax(x,0); x=cxmin(x, head.biWidth-1); + y=cxmax(y,0); y=cxmin(y, head.biHeight-1); break; case OM_WRAP: //wrap coordinates diff --git a/lib/cximage-6.0/CxImage/ximaiter.h b/lib/cximage-6.0/CxImage/ximaiter.h index 9788919..01a720b 100644 --- a/lib/cximage-6.0/CxImage/ximaiter.h +++ b/lib/cximage-6.0/CxImage/ximaiter.h @@ -140,7 +140,7 @@ inline void CImageIterator::SetY(int y) inline void CImageIterator::SetRow(BYTE *buf, int n) { if (n<0) n = (int)ima->GetEffWidth(); - else n = min(n,(int)ima->GetEffWidth()); + else n = cxmin(n,(int)ima->GetEffWidth()); if ((IterImage!=NULL)&&(buf!=NULL)&&(n>0)) memcpy(IterImage,buf,n); } @@ -148,7 +148,7 @@ inline void CImageIterator::SetRow(BYTE *buf, int n) inline void CImageIterator::GetRow(BYTE *buf, int n) { if ((IterImage!=NULL)&&(buf!=NULL)&&(n>0)) - memcpy(buf,IterImage,min(n,(int)ima->GetEffWidth())); + memcpy(buf,IterImage,cxmin(n,(int)ima->GetEffWidth())); } ///////////////////////////////////////////////////////////////////// inline BYTE* CImageIterator::GetRow() diff --git a/lib/cximage-6.0/CxImage/ximajbg.cpp b/lib/cximage-6.0/CxImage/ximajbg.cpp index 06fb9bf..8a01e28 100644 --- a/lib/cximage-6.0/CxImage/ximajbg.cpp +++ b/lib/cximage-6.0/CxImage/ximajbg.cpp @@ -145,7 +145,7 @@ bool CxImageJBG::Encode(CxFile * hFile) jbg_enc_init(&jbig_state, w, h, planes, &buffer, jbig_data_out, hFile); //jbg_enc_layers(&jbig_state, 2); - //jbg_enc_lrlmax(&jbig_state, 800, 600); + //jbg_enc_lrlcxmax(&jbig_state, 800, 600); // Specify a few other options (each is ignored if negative) int dl = -1, dh = -1, d = -1, l0 = -1, mx = -1; diff --git a/lib/cximage-6.0/CxImage/ximapal.cpp b/lib/cximage-6.0/CxImage/ximapal.cpp index b3bd3da..3788c98 100644 --- a/lib/cximage-6.0/CxImage/ximapal.cpp +++ b/lib/cximage-6.0/CxImage/ximapal.cpp @@ -398,8 +398,8 @@ void CxImage::RGBtoBGR(BYTE *buffer, int length) { if (buffer && (head.biClrUsed==0)){ BYTE temp; - length = min(length,(int)info.dwEffWidth); - length = min(length,(int)(3*head.biWidth)); + length = cxmin(length,(int)info.dwEffWidth); + length = cxmin(length,(int)(3*head.biWidth)); for (int i=0;i<length;i+=3){ temp = buffer[i]; buffer[i] = buffer[i+2]; buffer[i+2] = temp; } @@ -444,7 +444,7 @@ void CxImage::SetPalette(DWORD n, BYTE *r, BYTE *g, BYTE *b) if (!g) g = r; if (!b) b = g; RGBQUAD* ppal=GetPalette(); - DWORD m=min(n,head.biClrUsed); + DWORD m=cxmin(n,head.biClrUsed); for (DWORD i=0; i<m;i++){ ppal[i].rgbRed=r[i]; ppal[i].rgbGreen=g[i]; @@ -457,7 +457,7 @@ void CxImage::SetPalette(rgb_color *rgb,DWORD nColors) { if ((!rgb)||(pDib==NULL)||(head.biClrUsed==0)) return; RGBQUAD* ppal=GetPalette(); - DWORD m=min(nColors,head.biClrUsed); + DWORD m=cxmin(nColors,head.biClrUsed); for (DWORD i=0; i<m;i++){ ppal[i].rgbRed=rgb[i].r; ppal[i].rgbGreen=rgb[i].g; @@ -469,7 +469,7 @@ void CxImage::SetPalette(rgb_color *rgb,DWORD nColors) void CxImage::SetPalette(RGBQUAD* pPal,DWORD nColors) { if ((pPal==NULL)||(pDib==NULL)||(head.biClrUsed==0)) return; - memcpy(GetPalette(),pPal,min(GetPaletteSize(),nColors*sizeof(RGBQUAD))); + memcpy(GetPalette(),pPal,cxmin(GetPaletteSize(),nColors*sizeof(RGBQUAD))); info.last_c_isvalid = false; } //////////////////////////////////////////////////////////////////////////////// @@ -654,10 +654,10 @@ void CxImage::SetClrImportant(DWORD ncolors) switch(head.biBitCount){ case 1: - head.biClrImportant = min(ncolors,2); + head.biClrImportant = cxmin(ncolors,2); break; case 4: - head.biClrImportant = min(ncolors,16); + head.biClrImportant = cxmin(ncolors,16); break; case 8: head.biClrImportant = ncolors; diff --git a/lib/cximage-6.0/CxImage/ximapng.cpp b/lib/cximage-6.0/CxImage/ximapng.cpp index a58441c..4b5cc50 100644 --- a/lib/cximage-6.0/CxImage/ximapng.cpp +++ b/lib/cximage-6.0/CxImage/ximapng.cpp @@ -206,9 +206,9 @@ bool CxImagePNG::Decode(CxFile *hFile) } else SetGrayPalette(); //<DP> needed for grayscale PNGs #ifdef USE_NEW_LIBPNG_API - int nshift = max(0,(_bit_depth>>3)-1)<<3; + int nshift = cxmax(0,(_bit_depth>>3)-1)<<3; #else - int nshift = max(0,(info_ptr->bit_depth>>3)-1)<<3; + int nshift = cxmax(0,(info_ptr->bit_depth>>3)-1)<<3; #endif #ifdef USE_NEW_LIBPNG_API @@ -255,10 +255,10 @@ bool CxImagePNG::Decode(CxFile *hFile) if (pal){ DWORD ip; #ifdef USE_NEW_LIBPNG_API - for (ip=0;ip<min(head.biClrUsed,(unsigned long)_num_trans);ip++) + for (ip=0;ip<cxmin(head.biClrUsed,(unsigned long)_num_trans);ip++) pal[ip].rgbReserved=_trans_alpha[ip]; #else - for (ip=0;ip<min(head.biClrUsed,(unsigned long)info_ptr->num_trans);ip++) + for (ip=0;ip<cxmin(head.biClrUsed,(unsigned long)info_ptr->num_trans);ip++) #if PNG_LIBPNG_VER > 10399 pal[ip].rgbReserved=info_ptr->trans_alpha[ip]; #else @@ -737,9 +737,9 @@ bool CxImagePNG::Encode(CxFile *hFile) #endif // CXIMAGE_SUPPORT_ALPHA // <vho> #ifdef USE_NEW_LIBPNG_API - int row_size = max(info.dwEffWidth, (_width * _channels * _bit_depth / 8)); + int row_size = cxmax(info.dwEffWidth, (_width * _channels * _bit_depth / 8)); #else - int row_size = max(info.dwEffWidth, info_ptr->width*info_ptr->channels*(info_ptr->bit_depth/8)); + int row_size = cxmax(info.dwEffWidth, info_ptr->width*info_ptr->channels*(info_ptr->bit_depth/8)); info_ptr->rowbytes = row_size; #endif BYTE *row_pointers = new BYTE[row_size]; diff --git a/lib/cximage-6.0/CxImage/ximaraw.cpp b/lib/cximage-6.0/CxImage/ximaraw.cpp index fd86f96..52d964d 100644 --- a/lib/cximage-6.0/CxImage/ximaraw.cpp +++ b/lib/cximage-6.0/CxImage/ximaraw.cpp @@ -216,7 +216,7 @@ bool CxImageRAW::Decode(CxFile *hFile) DWORD size = dcr.width * (dcr.colors*dcr.opt.output_bps/8); RGBtoBGR(ppm,size); - memcpy(GetBits(dcr.height - 1 - row), ppm, min(size,GetEffWidth())); + memcpy(GetBits(dcr.height - 1 - row), ppm, cxmin(size,GetEffWidth())); } free (ppm); @@ -298,7 +298,7 @@ bool CxImageRAW::GetExifThumbnail(const char *filename, const char *outname, int // Resizing. if (image.GetWidth() > 256 || image.GetHeight() > 256) { - float amount = 256.0f / max(image.GetWidth(), image.GetHeight()); + float amount = 256.0f / cxmax(image.GetWidth(), image.GetHeight()); image.Resample((long)(image.GetWidth() * amount), (long)(image.GetHeight() * amount), 0); } diff --git a/lib/cximage-6.0/CxImage/ximasel.cpp b/lib/cximage-6.0/CxImage/ximasel.cpp index 3a7c9a1..37cd10f 100644 --- a/lib/cximage-6.0/CxImage/ximasel.cpp +++ b/lib/cximage-6.0/CxImage/ximasel.cpp @@ -113,15 +113,15 @@ bool CxImage::SelectionAddRect(RECT r, BYTE level) if (r.left<r.right) {r2.left=r.left; r2.right=r.right; } else {r2.left=r.right ; r2.right=r.left; } if (r.bottom<r.top) {r2.bottom=r.bottom; r2.top=r.top; } else {r2.bottom=r.top ; r2.top=r.bottom; } - if (info.rSelectionBox.top <= r2.top) info.rSelectionBox.top = max(0L,min(head.biHeight,r2.top+1)); - if (info.rSelectionBox.left > r2.left) info.rSelectionBox.left = max(0L,min(head.biWidth,r2.left)); - if (info.rSelectionBox.right <= r2.right) info.rSelectionBox.right = max(0L,min(head.biWidth,r2.right+1)); - if (info.rSelectionBox.bottom > r2.bottom) info.rSelectionBox.bottom = max(0L,min(head.biHeight,r2.bottom)); + if (info.rSelectionBox.top <= r2.top) info.rSelectionBox.top = cxmax(0L,cxmin(head.biHeight,r2.top+1)); + if (info.rSelectionBox.left > r2.left) info.rSelectionBox.left = cxmax(0L,cxmin(head.biWidth,r2.left)); + if (info.rSelectionBox.right <= r2.right) info.rSelectionBox.right = cxmax(0L,cxmin(head.biWidth,r2.right+1)); + if (info.rSelectionBox.bottom > r2.bottom) info.rSelectionBox.bottom = cxmax(0L,cxmin(head.biHeight,r2.bottom)); - long ymin = max(0L,min(head.biHeight,r2.bottom)); - long ymax = max(0L,min(head.biHeight,r2.top+1)); - long xmin = max(0L,min(head.biWidth,r2.left)); - long xmax = max(0L,min(head.biWidth,r2.right+1)); + long ymin = cxmax(0L,cxmin(head.biHeight,r2.bottom)); + long ymax = cxmax(0L,cxmin(head.biHeight,r2.top+1)); + long xmin = cxmax(0L,cxmin(head.biWidth,r2.left)); + long xmax = cxmax(0L,cxmin(head.biWidth,r2.right+1)); for (long y=ymin; y<ymax; y++) memset(pSelection + xmin + y * head.biWidth, level, xmax-xmin); @@ -144,18 +144,18 @@ bool CxImage::SelectionAddEllipse(RECT r, BYTE level) long xcenter = (r.right + r.left)/2; long ycenter = (r.top + r.bottom)/2; - if (info.rSelectionBox.left > (xcenter - xradius)) info.rSelectionBox.left = max(0L,min(head.biWidth,(xcenter - xradius))); - if (info.rSelectionBox.right <= (xcenter + xradius)) info.rSelectionBox.right = max(0L,min(head.biWidth,(xcenter + xradius + 1))); - if (info.rSelectionBox.bottom > (ycenter - yradius)) info.rSelectionBox.bottom = max(0L,min(head.biHeight,(ycenter - yradius))); - if (info.rSelectionBox.top <= (ycenter + yradius)) info.rSelectionBox.top = max(0L,min(head.biHeight,(ycenter + yradius + 1))); + if (info.rSelectionBox.left > (xcenter - xradius)) info.rSelectionBox.left = cxmax(0L,cxmin(head.biWidth,(xcenter - xradius))); + if (info.rSelectionBox.right <= (xcenter + xradius)) info.rSelectionBox.right = cxmax(0L,cxmin(head.biWidth,(xcenter + xradius + 1))); + if (info.rSelectionBox.bottom > (ycenter - yradius)) info.rSelectionBox.bottom = cxmax(0L,cxmin(head.biHeight,(ycenter - yradius))); + if (info.rSelectionBox.top <= (ycenter + yradius)) info.rSelectionBox.top = cxmax(0L,cxmin(head.biHeight,(ycenter + yradius + 1))); - long xmin = max(0L,min(head.biWidth,xcenter - xradius)); - long xmax = max(0L,min(head.biWidth,xcenter + xradius + 1)); - long ymin = max(0L,min(head.biHeight,ycenter - yradius)); - long ymax = max(0L,min(head.biHeight,ycenter + yradius + 1)); + long xmin = cxmax(0L,cxmin(head.biWidth,xcenter - xradius)); + long xmax = cxmax(0L,cxmin(head.biWidth,xcenter + xradius + 1)); + long ymin = cxmax(0L,cxmin(head.biHeight,ycenter - yradius)); + long ymax = cxmax(0L,cxmin(head.biHeight,ycenter + yradius + 1)); long y,yo; - for (y=ymin; y<min(ycenter,ymax); y++){ + for (y=ymin; y<cxmin(ycenter,ymax); y++){ for (long x=xmin; x<xmax; x++){ yo = (long)(ycenter - yradius * sqrt(1-pow((float)(x - xcenter)/(float)xradius,2))); if (yo<y) pSelection[x + y * head.biWidth] = level; @@ -268,10 +268,10 @@ bool CxImage::SelectionAddPolygon(POINT *points, long npoints, BYTE level) RECT r2; if (current->x < next->x) {r2.left=current->x; r2.right=next->x; } else {r2.left=next->x ; r2.right=current->x; } if (current->y < next->y) {r2.bottom=current->y; r2.top=next->y; } else {r2.bottom=next->y ; r2.top=current->y; } - if (localbox.top < r2.top) localbox.top = max(0L,min(head.biHeight-1,r2.top+1)); - if (localbox.left > r2.left) localbox.left = max(0L,min(head.biWidth-1,r2.left-1)); - if (localbox.right < r2.right) localbox.right = max(0L,min(head.biWidth-1,r2.right+1)); - if (localbox.bottom > r2.bottom) localbox.bottom = max(0L,min(head.biHeight-1,r2.bottom-1)); + if (localbox.top < r2.top) localbox.top = cxmax(0L,cxmin(head.biHeight-1,r2.top+1)); + if (localbox.left > r2.left) localbox.left = cxmax(0L,cxmin(head.biWidth-1,r2.left-1)); + if (localbox.right < r2.right) localbox.right = cxmax(0L,cxmin(head.biWidth-1,r2.right+1)); + if (localbox.bottom > r2.bottom) localbox.bottom = cxmax(0L,cxmin(head.biHeight-1,r2.bottom-1)); i++; } @@ -385,10 +385,10 @@ bool CxImage::SelectionAddPolygon(POINT *points, long npoints, BYTE level) for (x=localbox.left; x<=localbox.right; x++) if (plocal[x + yoffset]!=1) pSelection[x + yoffset]=level; } - if (info.rSelectionBox.top <= localbox.top) info.rSelectionBox.top = min(head.biHeight,localbox.top + 1); - if (info.rSelectionBox.left > localbox.left) info.rSelectionBox.left = min(head.biWidth,localbox.left); - if (info.rSelectionBox.right <= localbox.right) info.rSelectionBox.right = min(head.biWidth,localbox.right + 1); - if (info.rSelectionBox.bottom > localbox.bottom) info.rSelectionBox.bottom = min(head.biHeight,localbox.bottom); + if (info.rSelectionBox.top <= localbox.top) info.rSelectionBox.top = cxmin(head.biHeight,localbox.top + 1); + if (info.rSelectionBox.left > localbox.left) info.rSelectionBox.left = cxmin(head.biWidth,localbox.left); + if (info.rSelectionBox.right <= localbox.right) info.rSelectionBox.right = cxmin(head.biWidth,localbox.right + 1); + if (info.rSelectionBox.bottom > localbox.bottom) info.rSelectionBox.bottom = cxmin(head.biHeight,localbox.bottom); free(plocal); free(pix); diff --git a/lib/cximage-6.0/CxImage/ximath.cpp b/lib/cximage-6.0/CxImage/ximath.cpp index 37533e2..f84eb72 100644 --- a/lib/cximage-6.0/CxImage/ximath.cpp +++ b/lib/cximage-6.0/CxImage/ximath.cpp @@ -64,10 +64,10 @@ CxRect2 CxRect2::CrossSection(CxRect2 const &r2) const */ { CxRect2 cs; - cs.botLeft.x=max(botLeft.x, r2.botLeft.x); - cs.botLeft.y=max(botLeft.y, r2.botLeft.y); - cs.topRight.x=min(topRight.x, r2.topRight.x); - cs.topRight.y=min(topRight.y, r2.topRight.y); + cs.botLeft.x=cxmax(botLeft.x, r2.botLeft.x); + cs.botLeft.y=cxmax(botLeft.y, r2.botLeft.y); + cs.topRight.x=cxmin(topRight.x, r2.topRight.x); + cs.topRight.y=cxmin(topRight.y, r2.topRight.y); if (cs.botLeft.x<=cs.topRight.x && cs.botLeft.y<=cs.topRight.y) { return cs; } else { diff --git a/lib/cximage-6.0/CxImage/ximatif.cpp b/lib/cximage-6.0/CxImage/ximatif.cpp index 658392a..002766c 100644 --- a/lib/cximage-6.0/CxImage/ximatif.cpp +++ b/lib/cximage-6.0/CxImage/ximatif.cpp @@ -470,9 +470,9 @@ bool CxImageTIF::Decode(CxFile * hFile) if ( cb > 0.00304 ) cb = 1.055 * pow(cb,0.41667) - 0.055; else cb = 12.92 * cb; - c.rgbRed =(BYTE)max(0,min(255,(int)(cr*255))); - c.rgbGreen=(BYTE)max(0,min(255,(int)(cg*255))); - c.rgbBlue =(BYTE)max(0,min(255,(int)(cb*255))); + c.rgbRed =(BYTE)cxmax(0,cxmin(255,(int)(cr*255))); + c.rgbGreen=(BYTE)cxmax(0,cxmin(255,(int)(cg*255))); + c.rgbBlue =(BYTE)cxmax(0,cxmin(255,(int)(cb*255))); SetPixelColor(xi,yi,c); #if CXIMAGE_SUPPORT_ALPHA diff --git a/lib/cximage-6.0/CxImage/ximatran.cpp b/lib/cximage-6.0/CxImage/ximatran.cpp index 64a71e7..84d5e03 100644 --- a/lib/cximage-6.0/CxImage/ximatran.cpp +++ b/lib/cximage-6.0/CxImage/ximatran.cpp @@ -302,12 +302,12 @@ bool CxImage::RotateLeft(CxImage* iDst) for (ys = 0; ys < newHeight; ys+=RBLOCK) { if (head.biBitCount==24) { //RGB24 optimized pixel access: - for (x = xs; x < min(newWidth, xs+RBLOCK); x++){ //do rotation + for (x = xs; x < cxmin(newWidth, xs+RBLOCK); x++){ //do rotation info.nProgress = (long)(100*x/newWidth); x2=newWidth-x-1; dstPtr = (BYTE*) imgDest.BlindGetPixelPointer(x,ys); srcPtr = (BYTE*) BlindGetPixelPointer(ys, x2); - for (y = ys; y < min(newHeight, ys+RBLOCK); y++){ + for (y = ys; y < cxmin(newHeight, ys+RBLOCK); y++){ //imgDest.SetPixelColor(x, y, GetPixelColor(y, x2)); *(dstPtr) = *(srcPtr); *(dstPtr+1) = *(srcPtr+1); @@ -318,19 +318,19 @@ bool CxImage::RotateLeft(CxImage* iDst) }//for x } else { //anything else than 24bpp (and 1bpp): palette - for (x = xs; x < min(newWidth, xs+RBLOCK); x++){ + for (x = xs; x < cxmin(newWidth, xs+RBLOCK); x++){ info.nProgress = (long)(100*x/newWidth); //<Anatoly Ivasyuk> x2=newWidth-x-1; - for (y = ys; y < min(newHeight, ys+RBLOCK); y++){ + for (y = ys; y < cxmin(newHeight, ys+RBLOCK); y++){ imgDest.SetPixelIndex(x, y, BlindGetPixelIndex(y, x2)); }//for y }//for x }//if (version selection) #if CXIMAGE_SUPPORT_ALPHA if (AlphaIsValid()) { - for (x = xs; x < min(newWidth, xs+RBLOCK); x++){ + for (x = xs; x < cxmin(newWidth, xs+RBLOCK); x++){ x2=newWidth-x-1; - for (y = ys; y < min(newHeight, ys+RBLOCK); y++){ + for (y = ys; y < cxmin(newHeight, ys+RBLOCK); y++){ imgDest.AlphaSet(x,y,BlindAlphaGet(y, x2)); }//for y }//for x @@ -343,9 +343,9 @@ bool CxImage::RotateLeft(CxImage* iDst) imgDest.info.rSelectionBox.right = newWidth-info.rSelectionBox.bottom; imgDest.info.rSelectionBox.bottom = info.rSelectionBox.left; imgDest.info.rSelectionBox.top = info.rSelectionBox.right; - for (x = xs; x < min(newWidth, xs+RBLOCK); x++){ + for (x = xs; x < cxmin(newWidth, xs+RBLOCK); x++){ x2=newWidth-x-1; - for (y = ys; y < min(newHeight, ys+RBLOCK); y++){ + for (y = ys; y < cxmin(newHeight, ys+RBLOCK); y++){ imgDest.SelectionSet(x,y,BlindSelectionGet(y, x2)); }//for y }//for x @@ -447,12 +447,12 @@ bool CxImage::RotateRight(CxImage* iDst) for (ys = 0; ys < newHeight; ys+=RBLOCK) { if (head.biBitCount==24) { //RGB24 optimized pixel access: - for (y = ys; y < min(newHeight, ys+RBLOCK); y++){ + for (y = ys; y < cxmin(newHeight, ys+RBLOCK); y++){ info.nProgress = (long)(100*y/newHeight); //<Anatoly Ivasyuk> y2=newHeight-y-1; dstPtr = (BYTE*) imgDest.BlindGetPixelPointer(xs,y); srcPtr = (BYTE*) BlindGetPixelPointer(y2, xs); - for (x = xs; x < min(newWidth, xs+RBLOCK); x++){ + for (x = xs; x < cxmin(newWidth, xs+RBLOCK); x++){ //imgDest.SetPixelColor(x, y, GetPixelColor(y2, x)); *(dstPtr) = *(srcPtr); *(dstPtr+1) = *(srcPtr+1); @@ -463,19 +463,19 @@ bool CxImage::RotateRight(CxImage* iDst) }//for y } else { //anything else than BW & RGB24: palette - for (y = ys; y < min(newHeight, ys+RBLOCK); y++){ + for (y = ys; y < cxmin(newHeight, ys+RBLOCK); y++){ info.nProgress = (long)(100*y/newHeight); //<Anatoly Ivasyuk> y2=newHeight-y-1; - for (x = xs; x < min(newWidth, xs+RBLOCK); x++){ + for (x = xs; x < cxmin(newWidth, xs+RBLOCK); x++){ imgDest.SetPixelIndex(x, y, BlindGetPixelIndex(y2, x)); }//for x }//for y }//if #if CXIMAGE_SUPPORT_ALPHA if (AlphaIsValid()){ - for (y = ys; y < min(newHeight, ys+RBLOCK); y++){ + for (y = ys; y < cxmin(newHeight, ys+RBLOCK); y++){ y2=newHeight-y-1; - for (x = xs; x < min(newWidth, xs+RBLOCK); x++){ + for (x = xs; x < cxmin(newWidth, xs+RBLOCK); x++){ imgDest.AlphaSet(x,y,BlindAlphaGet(y2, x)); }//for x }//for y @@ -488,9 +488,9 @@ bool CxImage::RotateRight(CxImage* iDst) imgDest.info.rSelectionBox.right = info.rSelectionBox.top; imgDest.info.rSelectionBox.bottom = newHeight-info.rSelectionBox.right; imgDest.info.rSelectionBox.top = newHeight-info.rSelectionBox.left; - for (y = ys; y < min(newHeight, ys+RBLOCK); y++){ + for (y = ys; y < cxmin(newHeight, ys+RBLOCK); y++){ y2=newHeight-y-1; - for (x = xs; x < min(newWidth, xs+RBLOCK); x++){ + for (x = xs; x < cxmin(newWidth, xs+RBLOCK); x++){ imgDest.SelectionSet(x,y,BlindSelectionGet(y2, x)); }//for x }//for y @@ -608,10 +608,10 @@ bool CxImage::Rotate(float angle, CxImage* iDst) newP4.x = (float)(p4.x*cos_angle - p4.y*sin_angle); newP4.y = (float)(p4.x*sin_angle + p4.y*cos_angle); - leftTop.x = min(min(newP1.x,newP2.x),min(newP3.x,newP4.x)); - leftTop.y = min(min(newP1.y,newP2.y),min(newP3.y,newP4.y)); - rightBottom.x = max(max(newP1.x,newP2.x),max(newP3.x,newP4.x)); - rightBottom.y = max(max(newP1.y,newP2.y),max(newP3.y,newP4.y)); + leftTop.x = cxmin(cxmin(newP1.x,newP2.x),cxmin(newP3.x,newP4.x)); + leftTop.y = cxmin(cxmin(newP1.y,newP2.y),cxmin(newP3.y,newP4.y)); + rightBottom.x = cxmax(cxmax(newP1.x,newP2.x),cxmax(newP3.x,newP4.x)); + rightBottom.y = cxmax(cxmax(newP1.y,newP2.y),cxmax(newP3.y,newP4.y)); leftBottom.x = leftTop.x; leftBottom.y = rightBottom.y; rightTop.x = rightBottom.x; @@ -740,10 +740,10 @@ bool CxImage::Rotate2(float angle, }//if //(read new dimensions from location of corners) - float minx = (float) min(min(newp[0].x,newp[1].x),min(newp[2].x,newp[3].x)); - float miny = (float) min(min(newp[0].y,newp[1].y),min(newp[2].y,newp[3].y)); - float maxx = (float) max(max(newp[0].x,newp[1].x),max(newp[2].x,newp[3].x)); - float maxy = (float) max(max(newp[0].y,newp[1].y),max(newp[2].y,newp[3].y)); + float minx = (float) cxmin(cxmin(newp[0].x,newp[1].x),cxmin(newp[2].x,newp[3].x)); + float miny = (float) cxmin(cxmin(newp[0].y,newp[1].y),cxmin(newp[2].y,newp[3].y)); + float maxx = (float) cxmax(cxmax(newp[0].x,newp[1].x),cxmax(newp[2].x,newp[3].x)); + float maxy = (float) cxmax(cxmax(newp[0].y,newp[1].y),cxmax(newp[2].y,newp[3].y)); int newWidth = (int) floor(maxx-minx+0.5f); int newHeight= (int) floor(maxy-miny+0.5f); float ssx=((maxx+minx)- ((float) newWidth-1))/2.0f; //start for x @@ -1003,12 +1003,12 @@ bool CxImage::Resample(long newx, long newy, int mode, CxImage* iDst) if (info.nEscape) break; fY = y * yScale; ifY = (int)fY; - ifY1 = min(ymax, ifY+1); + ifY1 = cxmin(ymax, ifY+1); dy = fY - ifY; for(long x=0; x<newx; x++){ fX = x * xScale; ifX = (int)fX; - ifX1 = min(xmax, ifX+1); + ifX1 = cxmin(xmax, ifX+1); dx = fX - ifX; // Interpolate using the four nearest pixels in the source if (head.biClrUsed){ @@ -1328,9 +1328,9 @@ bool CxImage::DecreaseBpp(DWORD nbit, bool errordiffusion, RGBQUAD* ppal, DWORD eb=(long)c.rgbBlue - (long)ce.rgbBlue; c = GetPixelColor(x+1,y); - c.rgbRed = (BYTE)min(255L,max(0L,(long)c.rgbRed + ((er*7)/16))); - c.rgbGreen = (BYTE)min(255L,max(0L,(long)c.rgbGreen + ((eg*7)/16))); - c.rgbBlue = (BYTE)min(255L,max(0L,(long)c.rgbBlue + ((eb*7)/16))); + c.rgbRed = (BYTE)cxmin(255L,cxmax(0L,(long)c.rgbRed + ((er*7)/16))); + c.rgbGreen = (BYTE)cxmin(255L,cxmax(0L,(long)c.rgbGreen + ((eg*7)/16))); + c.rgbBlue = (BYTE)cxmin(255L,cxmax(0L,(long)c.rgbBlue + ((eb*7)/16))); SetPixelColor(x+1,y,c); int coeff=1; for(int i=-1; i<2; i++){ @@ -1343,9 +1343,9 @@ bool CxImage::DecreaseBpp(DWORD nbit, bool errordiffusion, RGBQUAD* ppal, DWORD coeff=1; break; } c = GetPixelColor(x+i,y+1); - c.rgbRed = (BYTE)min(255L,max(0L,(long)c.rgbRed + ((er * coeff)/16))); - c.rgbGreen = (BYTE)min(255L,max(0L,(long)c.rgbGreen + ((eg * coeff)/16))); - c.rgbBlue = (BYTE)min(255L,max(0L,(long)c.rgbBlue + ((eb * coeff)/16))); + c.rgbRed = (BYTE)cxmin(255L,cxmax(0L,(long)c.rgbRed + ((er * coeff)/16))); + c.rgbGreen = (BYTE)cxmin(255L,cxmax(0L,(long)c.rgbGreen + ((eg * coeff)/16))); + c.rgbBlue = (BYTE)cxmin(255L,cxmax(0L,(long)c.rgbBlue + ((eb * coeff)/16))); SetPixelColor(x+i,y+1,c); } } @@ -1566,10 +1566,10 @@ bool CxImage::Dither(long method) } nlevel = GetPixelIndex(x + 1, y) + (error * 8) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + 1, y, level); nlevel = GetPixelIndex(x + 2, y) + (error * 4) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + 2, y, level); int i; for (i = -2; i < 3; i++) { @@ -1591,7 +1591,7 @@ bool CxImage::Dither(long method) break; } nlevel = GetPixelIndex(x + i, y + 1) + (error * coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + i, y + 1, level); } } @@ -1620,10 +1620,10 @@ bool CxImage::Dither(long method) } nlevel = GetPixelIndex(x + 1, y) + (error * 8) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + 1, y, level); nlevel = GetPixelIndex(x + 2, y) + (error * 4) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + 2, y, level); int i; for (i = -2; i < 3; i++) { @@ -1645,7 +1645,7 @@ bool CxImage::Dither(long method) break; } nlevel = GetPixelIndex(x + i, y + 1) + (error * coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + i, y + 1, level); } for (i = -2; i < 3; i++) { @@ -1667,7 +1667,7 @@ bool CxImage::Dither(long method) break; } nlevel = GetPixelIndex(x + i, y + 2) + (error * coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + i, y + 2, level); } } @@ -1696,10 +1696,10 @@ bool CxImage::Dither(long method) } nlevel = GetPixelIndex(x + 1, y) + (error * 7) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + 1, y, level); nlevel = GetPixelIndex(x + 2, y) + (error * 5) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + 2, y, level); int i; for (i = -2; i < 3; i++) { @@ -1721,7 +1721,7 @@ bool CxImage::Dither(long method) break; } nlevel = GetPixelIndex(x + i, y + 1) + (error * coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + i, y + 1, level); } for (i = -2; i < 3; i++) { @@ -1743,7 +1743,7 @@ bool CxImage::Dither(long method) break; } nlevel = GetPixelIndex(x + i, y + 2) + (error * coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + i, y + 2, level); } } @@ -1772,10 +1772,10 @@ bool CxImage::Dither(long method) } nlevel = GetPixelIndex(x + 1, y) + (error * 5) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + 1, y, level); nlevel = GetPixelIndex(x + 2, y) + (error * 3) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + 2, y, level); int i; for (i = -2; i < 3; i++) { @@ -1797,7 +1797,7 @@ bool CxImage::Dither(long method) break; } nlevel = GetPixelIndex(x + i, y + 1) + (error * coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + i, y + 1, level); } for (i = -1; i < 2; i++) { @@ -1813,7 +1813,7 @@ bool CxImage::Dither(long method) break; } nlevel = GetPixelIndex(x + i, y + 2) + (error * coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(x + i, y + 2, level); } } @@ -1845,76 +1845,76 @@ bool CxImage::Dither(long method) int tmp_index_y = y; int tmp_coeff = 32; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x - 3; tmp_index_y = y + 1; tmp_coeff = 12; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x - 1; tmp_coeff = 26; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x + 1; tmp_coeff = 30; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x + 3; tmp_coeff = 16; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x - 2; tmp_index_y = y + 2; tmp_coeff = 12; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x; tmp_coeff = 26; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x + 2; tmp_coeff = 12; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x - 3; tmp_index_y = y + 3; tmp_coeff = 5; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x - 1; tmp_coeff = 12; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x + 1; tmp_coeff = 12; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); tmp_index_x = x + 3; tmp_coeff = 5; nlevel = GetPixelIndex(tmp_index_x, tmp_index_y) + (error * tmp_coeff) / TotalCoeffSum; - level = (BYTE)min(255, max(0, (int)nlevel)); + level = (BYTE)cxmin(255, cxmax(0, (int)nlevel)); SetPixelIndex(tmp_index_x, tmp_index_y, level); } } @@ -1941,7 +1941,7 @@ bool CxImage::Dither(long method) Bmatrix[i] = (BYTE)(dither); } - int scale = max(0,(8-2*order)); + int scale = cxmax(0,(8-2*order)); int level; for (long y=0;y<head.biHeight;y++){ info.nProgress = (long)(100*y/head.biHeight); @@ -1981,7 +1981,7 @@ bool CxImage::Dither(long method) } nlevel = GetPixelIndex(x+1,y) + (error * 7)/16; - level = (BYTE)min(255,max(0,(int)nlevel)); + level = (BYTE)cxmin(255,cxmax(0,(int)nlevel)); SetPixelIndex(x+1,y,level); for(int i=-1; i<2; i++){ switch(i){ @@ -1993,7 +1993,7 @@ bool CxImage::Dither(long method) coeff=1; break; } nlevel = GetPixelIndex(x+i,y+1) + (error * coeff)/16; - level = (BYTE)min(255,max(0,(int)nlevel)); + level = (BYTE)cxmin(255,cxmax(0,(int)nlevel)); SetPixelIndex(x+i,y+1,level); } } @@ -2031,7 +2031,7 @@ bool CxImage::CropRotatedRectangle( long topx, long topy, long width, long heigh if ( fabs(angle)<0.0002 ) return Crop( topx, topy, topx+width, topy+height, iDst); - startx = min(topx, topx - (long)(sin_angle*(double)height)); + startx = cxmin(topx, topx - (long)(sin_angle*(double)height)); endx = topx + (long)(cos_angle*(double)width); endy = topy + (long)(cos_angle*(double)height + sin_angle*(double)width); // check: corners of the rectangle must be inside @@ -2079,10 +2079,10 @@ bool CxImage::Crop(long left, long top, long right, long bottom, CxImage* iDst) { if (!pDib) return false; - long startx = max(0L,min(left,head.biWidth)); - long endx = max(0L,min(right,head.biWidth)); - long starty = head.biHeight - max(0L,min(top,head.biHeight)); - long endy = head.biHeight - max(0L,min(bottom,head.biHeight)); + long startx = cxmax(0L,cxmin(left,head.biWidth)); + long endx = cxmax(0L,cxmin(right,head.biWidth)); + long starty = head.biHeight - cxmax(0L,cxmin(top,head.biHeight)); + long endy = head.biHeight - cxmax(0L,cxmin(bottom,head.biHeight)); if (startx==endx || starty==endy) return false; @@ -2443,8 +2443,8 @@ bool CxImage::CircleTransform(int type,long rmax,float Koeff) nx=x+(x%32)-16; ny=y; } -// nx=max(xmin,min(nx,xmax)); -// ny=max(ymin,min(ny,ymax)); +// nx=cxmax(xmin,cxmin(nx,xmax)); +// ny=cxmax(ymin,cxmin(ny,ymax)); } else { nx=-1;ny=-1;} if (head.biClrUsed==0){ diff --git a/lib/cximage-6.0/CxImage/ximawnd.cpp b/lib/cximage-6.0/CxImage/ximawnd.cpp index 2ae2f93..7029cc7 100644 --- a/lib/cximage-6.0/CxImage/ximawnd.cpp +++ b/lib/cximage-6.0/CxImage/ximawnd.cpp @@ -682,10 +682,10 @@ long CxImage::Draw(HDC hdc, long x, long y, long cx, long cy, RECT* pClipRect, b RECT clipbox,paintbox; GetClipBox(hdc,&clipbox); - paintbox.top = min(clipbox.bottom,max(clipbox.top,y)); - paintbox.left = min(clipbox.right,max(clipbox.left,x)); - paintbox.right = max(clipbox.left,min(clipbox.right,x+cx)); - paintbox.bottom = max(clipbox.top,min(clipbox.bottom,y+cy)); + paintbox.top = cxmin(clipbox.bottom,cxmax(clipbox.top,y)); + paintbox.left = cxmin(clipbox.right,cxmax(clipbox.left,x)); + paintbox.right = cxmax(clipbox.left,cxmin(clipbox.right,x+cx)); + paintbox.bottom = cxmax(clipbox.top,cxmin(clipbox.bottom,y+cy)); long destw = paintbox.right - paintbox.left; long desth = paintbox.bottom - paintbox.top; @@ -730,12 +730,12 @@ long CxImage::Draw(HDC hdc, long x, long y, long cx, long cy, RECT* pClipRect, b for(yy=0;yy<desth;yy++){ dy = head.biHeight-(ymax-yy-y)*fy; - sy = max(0L,(long)floor(dy)); + sy = cxmax(0L,(long)floor(dy)); psrc = info.pImage+sy*info.dwEffWidth; pdst = pbase+yy*ew; for(xx=0;xx<destw;xx++){ dx = (xx+xmin-x)*fx; - sx = max(0L,(long)floor(dx)); + sx = cxmax(0L,(long)floor(dx)); #if CXIMAGE_SUPPORT_INTERPOLATION if (bSmooth){ if (fx > 1 && fy > 1) { @@ -813,7 +813,7 @@ long CxImage::Draw(HDC hdc, long x, long y, long cx, long cy, RECT* pClipRect, b for(yy=0;yy<desth;yy++){ dy = head.biHeight-(ymax-yy-y)*fy; - sy = max(0L,(long)floor(dy)); + sy = cxmax(0L,(long)floor(dy)); alphaoffset = sy*head.biWidth; pdst = pbase + yy*ew; @@ -821,7 +821,7 @@ long CxImage::Draw(HDC hdc, long x, long y, long cx, long cy, RECT* pClipRect, b for(xx=0;xx<destw;xx++){ dx = (xx+xmin-x)*fx; - sx = max(0L,(long)floor(dx)); + sx = cxmax(0L,(long)floor(dx)); if (bAlpha) a=pAlpha[alphaoffset+sx]; else a=255; a =(BYTE)((a*(1+info.nAlphaMax))>>8); -- 2.8.0.rc3
shibajee/buildroot
package/kodi/0009-lib-cximage-6.0-fix-compilation-with-gcc6.patch
patch
mit
63,929
From 7d3c70b163bc67aeb1fdef8fd2347b39f311c584 Mon Sep 17 00:00:00 2001 From: fritsch <peter.fruehberger@gmail.com> Date: Sun, 24 Jul 2016 20:24:07 +0200 Subject: [PATCH] Curl: Adjust multi_cleanup method which returns CURLMcode Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> (backported from upstream commit: https://github.com/xbmc/xbmc/commit/2a8d3e7f6cffea52740b8392a3be8ec251d5ff70) --- xbmc/filesystem/DllLibCurl.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xbmc/filesystem/DllLibCurl.h b/xbmc/filesystem/DllLibCurl.h index db97f92..9e78a91 100644 --- a/xbmc/filesystem/DllLibCurl.h +++ b/xbmc/filesystem/DllLibCurl.h @@ -52,7 +52,7 @@ namespace XCURL virtual CURLMcode multi_fdset(CURLM *multi_handle, fd_set *read_fd_set, fd_set *write_fd_set, fd_set *exc_fd_set, int *max_fd)=0; virtual CURLMcode multi_timeout(CURLM *multi_handle, long *timeout)=0; virtual CURLMsg* multi_info_read(CURLM *multi_handle, int *msgs_in_queue)=0; - virtual void multi_cleanup(CURL_HANDLE * handle )=0; + virtual CURLMcode multi_cleanup(CURLM * handle )=0; virtual struct curl_slist* slist_append(struct curl_slist *, const char *)=0; virtual void slist_free_all(struct curl_slist *)=0; }; @@ -77,7 +77,7 @@ namespace XCURL DEFINE_METHOD5(CURLMcode, multi_fdset, (CURLM *p1, fd_set *p2, fd_set *p3, fd_set *p4, int *p5)) DEFINE_METHOD2(CURLMcode, multi_timeout, (CURLM *p1, long *p2)) DEFINE_METHOD2(CURLMsg*, multi_info_read, (CURLM *p1, int *p2)) - DEFINE_METHOD1(void, multi_cleanup, (CURLM *p1)) + DEFINE_METHOD1(CURLMcode, multi_cleanup, (CURLM *p1)) DEFINE_METHOD2(struct curl_slist*, slist_append, (struct curl_slist * p1, const char * p2)) DEFINE_METHOD1(void, slist_free_all, (struct curl_slist * p1)) DEFINE_METHOD1(const char *, easy_strerror, (CURLcode p1))
shibajee/buildroot
package/kodi/0010-curl-support-version-7.5.0-and-upwards.patch
patch
mit
1,868
config BR2_PACKAGE_KODI_ARCH_SUPPORTS bool default y if (BR2_arm || (BR2_mipsel && BR2_TOOLCHAIN_USES_GLIBC) || BR2_i386 || BR2_x86_64) \ && BR2_PACKAGE_FFMPEG_ARCH_SUPPORTS \ && BR2_TOOLCHAIN_HAS_SYNC_8 comment "kodi needs a uClibc or glibc toolchain w/ C++, threads, wchar, dynamic library, gcc >= 4.7, host gcc >= 4.6" depends on BR2_PACKAGE_KODI_ARCH_SUPPORTS depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS \ || !BR2_USE_WCHAR || BR2_STATIC_LIBS \ || !BR2_HOST_GCC_AT_LEAST_4_6 \ || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_7 \ || BR2_TOOLCHAIN_USES_MUSL depends on BR2_USE_MMU config BR2_PACKAGE_KODI_EGL_GLES bool default y depends on BR2_PACKAGE_HAS_LIBEGL depends on BR2_PACKAGE_HAS_LIBGLES depends on !BR2_PACKAGE_KODI_GL # prefer GL if available config BR2_PACKAGE_KODI_GL bool default y depends on BR2_PACKAGE_HAS_LIBGL depends on !BR2_arm # kodi needs egl/gles on arm comment "kodi needs an OpenGL or an openGL ES and EGL backend" depends on BR2_i386 || BR2_x86_64 depends on !BR2_PACKAGE_KODI_GL && !BR2_PACKAGE_KODI_EGL_GLES comment "kodi requires an OpenGL ES and EGL backend" depends on BR2_arm depends on !BR2_PACKAGE_KODI_EGL_GLES menuconfig BR2_PACKAGE_KODI bool "kodi" depends on BR2_INSTALL_LIBSTDCPP depends on BR2_HOST_GCC_AT_LEAST_4_6 depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_7 depends on BR2_TOOLCHAIN_HAS_THREADS depends on !BR2_TOOLCHAIN_USES_MUSL depends on BR2_PACKAGE_KODI_EGL_GLES || BR2_PACKAGE_KODI_GL depends on BR2_USE_MMU # python depends on BR2_USE_WCHAR depends on !BR2_STATIC_LIBS # python depends on BR2_PACKAGE_KODI_ARCH_SUPPORTS select BR2_NEEDS_HOST_JAVA select BR2_PACKAGE_BOOST select BR2_PACKAGE_BOOST_THREAD select BR2_PACKAGE_BZIP2 select BR2_PACKAGE_EXPAT select BR2_PACKAGE_FFMPEG select BR2_PACKAGE_FFMPEG_GPL select BR2_PACKAGE_FFMPEG_POSTPROC # postproc depends on GPL select BR2_PACKAGE_FFMPEG_SWSCALE select BR2_PACKAGE_FONTCONFIG select BR2_PACKAGE_FREETYPE select BR2_PACKAGE_GIFLIB select BR2_PACKAGE_JASPER select BR2_PACKAGE_JPEG select BR2_PACKAGE_LIBASS select BR2_PACKAGE_LIBCDIO select BR2_PACKAGE_LIBCROSSGUID select BR2_PACKAGE_LIBCURL select BR2_PACKAGE_LIBDCADEC select BR2_PACKAGE_LIBFRIBIDI select BR2_PACKAGE_LIBGLEW if BR2_PACKAGE_KODI_GL select BR2_PACKAGE_LIBGLU if BR2_PACKAGE_KODI_GL select BR2_PACKAGE_LIBGCRYPT select BR2_PACKAGE_LIBMPEG2 select BR2_PACKAGE_LIBOGG select BR2_PACKAGE_LIBPLIST select BR2_PACKAGE_LIBPNG select BR2_PACKAGE_LIBSAMPLERATE select BR2_PACKAGE_LIBSQUISH select BR2_PACKAGE_LIBVORBIS select BR2_PACKAGE_LIBXML2 select BR2_PACKAGE_LIBXSLT select BR2_PACKAGE_LZO select BR2_PACKAGE_NCURSES select BR2_PACKAGE_OPENSSL select BR2_PACKAGE_PCRE select BR2_PACKAGE_PCRE_UCP select BR2_PACKAGE_PYTHON select BR2_PACKAGE_PYTHON_BSDDB select BR2_PACKAGE_PYTHON_BZIP2 select BR2_PACKAGE_PYTHON_CURSES select BR2_PACKAGE_PYTHON_PYEXPAT select BR2_PACKAGE_PYTHON_READLINE select BR2_PACKAGE_PYTHON_SQLITE select BR2_PACKAGE_PYTHON_SSL select BR2_PACKAGE_PYTHON_UNICODEDATA select BR2_PACKAGE_PYTHON_ZLIB select BR2_PACKAGE_READLINE select BR2_PACKAGE_SQLITE select BR2_PACKAGE_TAGLIB select BR2_PACKAGE_TIFF select BR2_PACKAGE_TINYXML select BR2_PACKAGE_LIBDRM if BR2_PACKAGE_KODI_GL select BR2_PACKAGE_XLIB_LIBXRANDR if BR2_PACKAGE_KODI_GL select BR2_PACKAGE_YAJL select BR2_PACKAGE_ZLIB select BR2_TOOLCHAIN_GLIBC_GCONV_LIBS_COPY if BR2_TOOLCHAIN_USES_GLIBC # runtime UTF conversion support help Kodi is an award-winning free and open source (GPL) software media player and entertainment hub for digital media. http://kodi.tv if BR2_PACKAGE_KODI source "package/kodi-platform/Config.in" config BR2_PACKAGE_KODI_ALSA_LIB bool "alsa" select BR2_PACKAGE_ALSA_LIB help Enable alsa support. config BR2_PACKAGE_KODI_AVAHI bool "avahi" select BR2_PACKAGE_AVAHI select BR2_PACKAGE_AVAHI_DAEMON help Enable Avahi support. Select this if you want Kodi to support Bonjour protocol. config BR2_PACKAGE_KODI_DBUS bool "dbus" select BR2_PACKAGE_DBUS help Enable D-Bus support config BR2_PACKAGE_KODI_LIBBLURAY bool "blu-ray" select BR2_PACKAGE_LIBBLURAY help Enable Blu-ray input support. Select this if you want to play back Blu-ray content. config BR2_PACKAGE_KODI_LIBCEC bool "hdmi cec" depends on BR2_PACKAGE_HAS_UDEV select BR2_PACKAGE_LIBCEC help Enable CEC (Consumer Electronics Control) support. Select this if you want Kodi to support HDMI CEC. comment "hdmi cec support needs udev /dev management" depends on !BR2_PACKAGE_HAS_UDEV config BR2_PACKAGE_KODI_LIRC bool "lirc" help Enable lirc support config BR2_PACKAGE_KODI_LIBMICROHTTPD bool "web server" depends on BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS # libgcrypt, libmicrohttpd select BR2_PACKAGE_LIBMICROHTTPD help Enable webserver feature config BR2_PACKAGE_KODI_LIBNFS bool "nfs" # libnfs -> libtirpc depends on BR2_TOOLCHAIN_HAS_NATIVE_RPC || BR2_TOOLCHAIN_HAS_THREADS select BR2_PACKAGE_LIBNFS help Enable NFS server support. comment "nfs support needs a toolchain w/ threads support" depends on !(BR2_TOOLCHAIN_HAS_THREADS || BR2_TOOLCHAIN_HAS_NATIVE_RPC) config BR2_PACKAGE_KODI_MYSQL bool "mysql" select BR2_PACKAGE_MYSQL help Enable MySQL support config BR2_PACKAGE_KODI_NONFREE bool "nonfree components" help Enable components with non-free licenses. This option currently only controls support for RAR archives. config BR2_PACKAGE_KODI_RTMPDUMP bool "rtmp" select BR2_PACKAGE_RTMPDUMP help Enable RTMP input support. Select this if you want to play back rtmp stream. config BR2_PACKAGE_KODI_LIBSHAIRPLAY bool "shairport" select BR2_PACKAGE_LIBSHAIRPLAY help Enable Shairport support. Select this if you want to stream content from an Apple device. comment "samba support needs a glibc or uClibc toolchain w/ RPC" depends on (!BR2_TOOLCHAIN_USES_GLIBC && \ !BR2_TOOLCHAIN_USES_UCLIBC) || !BR2_TOOLCHAIN_HAS_NATIVE_RPC config BR2_PACKAGE_KODI_LIBSMBCLIENT bool "samba" depends on BR2_TOOLCHAIN_USES_GLIBC || BR2_TOOLCHAIN_USES_UCLIBC depends on BR2_TOOLCHAIN_HAS_NATIVE_RPC depends on BR2_TOOLCHAIN_HAS_SYNC_4 select BR2_PACKAGE_SAMBA4 help Enable Samba support config BR2_PACKAGE_KODI_LIBSSH bool "ssh" select BR2_PACKAGE_LIBSSH help Enable sftp virtual filesystem using libssh. config BR2_PACKAGE_KODI_LIBTHEORA bool "theora" select BR2_PACKAGE_LIBTHEORA help Enable Theora input support. Select this if you want to play back OGG/OGV files (Video). config BR2_PACKAGE_KODI_LIBUSB bool "usb" # https://github.com/xbmc/xbmc/blob/Jarvis/configure.ac#L1554 # "if libudev is available, we don't need libusb" depends on !BR2_PACKAGE_HAS_UDEV select BR2_PACKAGE_LIBUSB select BR2_PACKAGE_LIBUSB_COMPAT help Enable libusb support. config BR2_PACKAGE_KODI_LIBVA bool "va" select BR2_PACKAGE_LIBVA help Enable libva support. config BR2_PACKAGE_KODI_LIBVDPAU bool "vdpau" depends on BR2_PACKAGE_XORG7 select BR2_PACKAGE_LIBVDPAU help Enable libvdpau support. comment "libvdpau support needs X.org" depends on !BR2_PACKAGE_XORG7 config BR2_PACKAGE_KODI_UPNP bool "upnp" help Enable UPnP support config BR2_PACKAGE_KODI_OPTICALDRIVE bool menu "Audio decoder addons" source "package/kodi-audiodecoder-modplug/Config.in" source "package/kodi-audiodecoder-nosefart/Config.in" source "package/kodi-audiodecoder-opus/Config.in" source "package/kodi-audiodecoder-sidplay/Config.in" source "package/kodi-audiodecoder-snesapu/Config.in" source "package/kodi-audiodecoder-stsound/Config.in" source "package/kodi-audiodecoder-timidity/Config.in" source "package/kodi-audiodecoder-vgmstream/Config.in" endmenu menu "Audio DSP addons" source "package/kodi-adsp-basic/Config.in" source "package/kodi-adsp-freesurround/Config.in" endmenu menu "Audio encoder addons" source "package/kodi-audioencoder-flac/Config.in" source "package/kodi-audioencoder-lame/Config.in" source "package/kodi-audioencoder-vorbis/Config.in" source "package/kodi-audioencoder-wav/Config.in" endmenu menu "PVR addons" source "package/kodi-addon-xvdr/Config.in" source "package/kodi-pvr-argustv/Config.in" source "package/kodi-pvr-dvblink/Config.in" source "package/kodi-pvr-dvbviewer/Config.in" source "package/kodi-pvr-filmon/Config.in" source "package/kodi-pvr-hdhomerun/Config.in" source "package/kodi-pvr-hts/Config.in" source "package/kodi-pvr-iptvsimple/Config.in" source "package/kodi-pvr-mediaportal-tvserver/Config.in" source "package/kodi-pvr-mythtv/Config.in" source "package/kodi-pvr-nextpvr/Config.in" source "package/kodi-pvr-njoy/Config.in" source "package/kodi-pvr-pctv/Config.in" source "package/kodi-pvr-stalker/Config.in" source "package/kodi-pvr-vbox/Config.in" source "package/kodi-pvr-vdr-vnsi/Config.in" source "package/kodi-pvr-vuplus/Config.in" source "package/kodi-pvr-wmc/Config.in" endmenu menu "Screensavers" source "package/kodi-screensaver-asteroids/Config.in" source "package/kodi-screensaver-asterwave/Config.in" source "package/kodi-screensaver-biogenesis/Config.in" source "package/kodi-screensaver-cpblobs/Config.in" source "package/kodi-screensaver-crystalmorph/Config.in" source "package/kodi-screensaver-greynetic/Config.in" source "package/kodi-screensaver-matrixtrails/Config.in" source "package/kodi-screensaver-pingpong/Config.in" source "package/kodi-screensaver-planestate/Config.in" source "package/kodi-screensaver-pyro/Config.in" source "package/kodi-screensaver-rsxs/Config.in" source "package/kodi-screensaver-stars/Config.in" endmenu menu "Visualisations" source "package/kodi-visualisation-fishbmc/Config.in" source "package/kodi-visualisation-fountain/Config.in" source "package/kodi-visualisation-goom/Config.in" source "package/kodi-visualisation-shadertoy/Config.in" source "package/kodi-visualisation-spectrum/Config.in" source "package/kodi-visualisation-waveforhue/Config.in" source "package/kodi-visualisation-waveform/Config.in" endmenu endif # BR2_PACKAGE_KODI
shibajee/buildroot
package/kodi/Config.in
in
mit
10,079
#!/bin/sh # # Starts Kodi # BIN=/usr/bin/br-kodi KODI=/usr/lib/xbmc/kodi.bin KODI_ARGS="--standalone -fs -n" PIDFILE=/var/run/kodi.pid start() { printf "Starting Kodi: " start-stop-daemon -S -q -b -m -p $PIDFILE --exec $BIN -- $KODI $KODI_ARGS [ $? = 0 ] && echo "OK" || echo "FAIL" } stop() { printf "Stopping Kodi: " start-stop-daemon -K -q -p $PIDFILE [ $? = 0 ] && echo "OK" || echo "FAIL" } restart() { stop start } case "$1" in start) start ;; stop) stop ;; restart|reload) restart ;; *) echo "Usage: $0 {start|stop|restart}" exit 1 esac
shibajee/buildroot
package/kodi/S50kodi
none
mit
571
#!/bin/sh # We're called with the real Kodi executable as # first argument, followed by any Kodi extra args KODI="${1}" shift # In case someone asked we terminate, just kill # the Kodi process trap_kill() { LOOP=0 killall "${KODI##*/}" } trap trap_kill INT QUIT TERM LOOP=1 while [ ${LOOP} -eq 1 ]; do # Hack: BusyBox ash does not catch signals while a non-builtin # is running, and only catches the signal when the non-builtin # command ends. So, we just background the Kodi binary, and wait # for it. But BusyBox' ash's wait builtin does not return the # exit code even if there was only one job (which is correct # for POSIX). So we explicitly wait for the Kodi job "${KODI}" "${@}" & wait %1 ret=$? case "${ret}" in 0) ;; 64) poweroff; LOOP=0;; 66) reboot; LOOP=0;; *) # Crash sleep 1 ;; esac done exit ${ret}
shibajee/buildroot
package/kodi/br-kodi
none
mit
929
# Locally computed sha256 7d82c8aff2715c83deecdf10c566e26105bec0473af530a1356d4c747ebdfd10 kodi-16.1-Jarvis.tar.gz
shibajee/buildroot
package/kodi/kodi.hash
hash
mit
115
################################################################################ # # kodi # ################################################################################ KODI_VERSION = 16.1-Jarvis KODI_SITE = $(call github,xbmc,xbmc,$(KODI_VERSION)) KODI_LICENSE = GPLv2 KODI_LICENSE_FILES = LICENSE.GPL # needed for binary addons KODI_INSTALL_STAGING = YES KODI_DEPENDENCIES = \ boost \ bzip2 \ expat \ ffmpeg \ fontconfig \ freetype \ giflib \ host-gawk \ host-gettext \ host-giflib \ host-gperf \ host-libjpeg \ host-libpng \ host-lzo \ host-nasm \ host-swig \ host-zip \ jasper \ jpeg \ libass \ libcdio \ libcrossguid \ libcurl \ libdcadec \ libfribidi \ libgcrypt \ libmpeg2 \ libogg \ libplist \ libpng \ libsamplerate \ libsquish \ libvorbis \ libxml2 \ libxslt \ lzo \ ncurses \ openssl \ pcre \ python \ readline \ sqlite \ taglib \ tiff \ tinyxml \ yajl \ zlib KODI_CONF_ENV = \ PYTHON_VERSION="$(PYTHON_VERSION_MAJOR)" \ PYTHON_LDFLAGS="-lpython$(PYTHON_VERSION_MAJOR) -lpthread -ldl -lutil -lm" \ PYTHON_CPPFLAGS="-I$(STAGING_DIR)/usr/include/python$(PYTHON_VERSION_MAJOR)" \ PYTHON_SITE_PKG="$(STAGING_DIR)/usr/lib/python$(PYTHON_VERSION_MAJOR)/site-packages" \ PYTHON_NOVERSIONCHECK="no-check" \ use_texturepacker_native=yes \ USE_TEXTUREPACKER_NATIVE_ROOT="$(HOST_DIR)/usr" \ TEXTUREPACKER_NATIVE_ROOT="$(HOST_DIR)/usr" KODI_CONF_OPTS += \ --with-ffmpeg=shared \ --disable-joystick \ --disable-openmax \ --disable-pulse \ --disable-vtbdecoder \ --enable-optimizations ifeq ($(BR2_PACKAGE_KODI_MYSQL),y) KODI_CONF_OPTS += --enable-mysql KODI_CONF_ENV += ac_cv_path_MYSQL_CONFIG="$(STAGING_DIR)/usr/bin/mysql_config" KODI_DEPENDENCIES += mysql else KODI_CONF_OPTS += --disable-mysql endif ifeq ($(BR2_PACKAGE_KODI_NONFREE),y) KODI_CONF_OPTS += --enable-non-free KODI_LICENSE := $(KODI_LICENSE), unrar KODI_LICENSE_FILES += lib/UnrarXLib/license.txt else KODI_CONF_OPTS += --disable-non-free endif ifeq ($(BR2_PACKAGE_RPI_USERLAND),y) KODI_DEPENDENCIES += rpi-userland KODI_CONF_OPTS += --with-platform=raspberry-pi --enable-player=omxplayer KODI_CONF_ENV += INCLUDES="-I$(STAGING_DIR)/usr/include/interface/vcos/pthreads \ -I$(STAGING_DIR)/usr/include/interface/vmcs_host/linux" \ LIBS="-lvcos -lvchostif" endif ifeq ($(BR2_PACKAGE_HAS_UDEV),y) KODI_DEPENDENCIES += udev KODI_CONF_OPTS += --enable-udev else KODI_CONF_OPTS += --disable-udev endif ifeq ($(BR2_PACKAGE_IMX_VPUWRAP),y) KODI_DEPENDENCIES += imx-vpuwrap KODI_CONF_OPTS += --enable-codec=imxvpu endif ifeq ($(BR2_PACKAGE_LIBCAP),y) KODI_CONF_OPTS += --enable-libcap KODI_DEPENDENCIES += libcap else KODI_CONF_OPTS += --disable-libcap endif ifeq ($(BR2_PACKAGE_KODI_DBUS),y) KODI_DEPENDENCIES += dbus KODI_CONF_OPTS += --enable-dbus else KODI_CONF_OPTS += --disable-dbus endif ifeq ($(BR2_PACKAGE_KODI_ALSA_LIB),y) KODI_DEPENDENCIES += alsa-lib KODI_CONF_OPTS += --enable-alsa else KODI_CONF_OPTS += --disable-alsa endif # quote from kodi/configure.in: "GLES overwrites GL if both set to yes." # we choose the opposite because opengl offers more features, like libva support # GL means X11, and under X11, Kodi needs libdrm; libdrm is forcefully selected # by a modular Xorg server, which Kodi already depends on. ifeq ($(BR2_PACKAGE_KODI_GL),y) KODI_DEPENDENCIES += libglew libglu libgl xlib_libX11 xlib_libXext \ xlib_libXmu xlib_libXrandr xlib_libXt libdrm KODI_CONF_OPTS += --enable-gl --enable-x11 --disable-gles else KODI_CONF_OPTS += --disable-gl --disable-x11 ifeq ($(BR2_PACKAGE_KODI_EGL_GLES),y) KODI_DEPENDENCIES += libegl libgles KODI_CONF_ENV += CXXFLAGS="$(TARGET_CXXFLAGS) `$(PKG_CONFIG_HOST_BINARY) --cflags --libs egl`" KODI_CONF_ENV += CFLAGS="$(TARGET_CFLAGS) `$(PKG_CONFIG_HOST_BINARY) --cflags --libs egl`" KODI_CONF_OPTS += --enable-gles else KODI_CONF_OPTS += --disable-gles endif endif ifeq ($(BR2_PACKAGE_KODI_LIBUSB),y) KODI_DEPENDENCIES += libusb-compat KODI_CONF_OPTS += --enable-libusb else KODI_CONF_OPTS += --disable-libusb endif ifeq ($(BR2_PACKAGE_KODI_LIBMICROHTTPD),y) KODI_DEPENDENCIES += libmicrohttpd KODI_CONF_OPTS += --enable-webserver else KODI_CONF_OPTS += --disable-webserver endif ifeq ($(BR2_PACKAGE_KODI_LIBSMBCLIENT),y) KODI_DEPENDENCIES += samba4 KODI_CONF_OPTS += --enable-samba else KODI_CONF_OPTS += --disable-samba endif ifeq ($(BR2_PACKAGE_KODI_LIBNFS),y) KODI_DEPENDENCIES += libnfs KODI_CONF_OPTS += --enable-nfs else KODI_CONF_OPTS += --disable-nfs endif ifeq ($(BR2_PACKAGE_KODI_RTMPDUMP),y) KODI_DEPENDENCIES += rtmpdump KODI_CONF_OPTS += --enable-rtmp else KODI_CONF_OPTS += --disable-rtmp endif ifeq ($(BR2_PACKAGE_KODI_LIBBLURAY),y) KODI_DEPENDENCIES += libbluray KODI_CONF_OPTS += --enable-libbluray else KODI_CONF_OPTS += --disable-libbluray endif ifeq ($(BR2_PACKAGE_KODI_LIBSHAIRPLAY),y) KODI_DEPENDENCIES += libshairplay KODI_CONF_OPTS += --enable-airplay else KODI_CONF_OPTS += --disable-airplay endif ifeq ($(BR2_PACKAGE_KODI_LIBSSH),y) KODI_DEPENDENCIES += libssh KODI_CONF_OPTS += --enable-ssh else KODI_CONF_OPTS += --disable-ssh endif ifeq ($(BR2_PACKAGE_KODI_AVAHI),y) KODI_DEPENDENCIES += avahi KODI_CONF_OPTS += --enable-avahi else KODI_CONF_OPTS += --disable-avahi endif ifeq ($(BR2_PACKAGE_KODI_LIBCEC),y) KODI_DEPENDENCIES += libcec KODI_CONF_OPTS += --enable-libcec else KODI_CONF_OPTS += --disable-libcec endif ifeq ($(BR2_PACKAGE_KODI_LIRC),y) KODI_CONF_OPTS += --enable-lirc else KODI_CONF_OPTS += --disable-lirc endif ifeq ($(BR2_PACKAGE_KODI_LIBTHEORA),y) KODI_DEPENDENCIES += libtheora endif # kodi needs libva & libva-glx ifeq ($(BR2_PACKAGE_KODI_LIBVA)$(BR2_PACKAGE_MESA3D_DRI_DRIVER),yy) KODI_DEPENDENCIES += mesa3d libva KODI_CONF_OPTS += --enable-vaapi else KODI_CONF_OPTS += --disable-vaapi endif ifeq ($(BR2_PACKAGE_KODI_LIBVDPAU),y) KODI_DEPENDENCIES += libvdpau KODI_CONF_OPTS += --enable-vdpau else KODI_CONF_OPTS += --disable-vdpau endif ifeq ($(BR2_PACKAGE_KODI_UPNP),y) KODI_CONF_OPTS += --enable-upnp else KODI_CONF_OPTS += --disable-upnp endif ifeq ($(BR2_PACKAGE_KODI_OPTICALDRIVE),y) KODI_CONF_OPTS += --enable-optical-drive --enable-dvdcss else KODI_CONF_OPTS += --disable-optical-drive --disable-dvdcss endif # Add HOST_DIR to PATH for codegenerator.mk to find swig define KODI_BOOTSTRAP $(HOST_CONFIGURE_OPTS) $(MAKE) -C $(@D)/tools/depends/native/JsonSchemaBuilder $(HOST_CONFIGURE_OPTS) $(MAKE) -C $(@D)/tools/depends/native/TexturePacker cd $(@D) && PATH=$(BR_PATH) ./bootstrap endef KODI_PRE_CONFIGURE_HOOKS += KODI_BOOTSTRAP define KODI_CLEAN_UNUSED_ADDONS rm -Rf $(TARGET_DIR)/usr/share/kodi/addons/visualization.milkdrop rm -Rf $(TARGET_DIR)/usr/share/kodi/addons/visualization.projectm rm -Rf $(TARGET_DIR)/usr/share/kodi/addons/visualization.itunes endef KODI_POST_INSTALL_TARGET_HOOKS += KODI_CLEAN_UNUSED_ADDONS define KODI_CLEAN_CONFLUENCE_SKIN find $(TARGET_DIR)/usr/share/kodi/addons/skin.confluence/media -name *.png -delete find $(TARGET_DIR)/usr/share/kodi/addons/skin.confluence/media -name *.jpg -delete endef KODI_POST_INSTALL_TARGET_HOOKS += KODI_CLEAN_CONFLUENCE_SKIN define KODI_INSTALL_BR_WRAPPER $(INSTALL) -D -m 0755 package/kodi/br-kodi \ $(TARGET_DIR)/usr/bin/br-kodi endef KODI_POST_INSTALL_TARGET_HOOKS += KODI_INSTALL_BR_WRAPPER # When run from a startup script, Kodi has no $HOME where to store its # configuration, so ends up storing it in /.kodi (yes, at the root of # the rootfs). This is a problem for read-only filesystems. But we can't # easily change that, so create /.kodi as a symlink where we want the # config to eventually be. Add synlinks for the legacy XBMC name as well define KODI_INSTALL_CONFIG_DIR $(INSTALL) -d -m 0755 $(TARGET_DIR)/var/kodi ln -sf /var/kodi $(TARGET_DIR)/.kodi ln -sf /var/kodi $(TARGET_DIR)/var/xbmc ln -sf /var/kodi $(TARGET_DIR)/.xbmc endef KODI_POST_INSTALL_TARGET_HOOKS += KODI_INSTALL_CONFIG_DIR define KODI_INSTALL_INIT_SYSV $(INSTALL) -D -m 755 package/kodi/S50kodi \ $(TARGET_DIR)/etc/init.d/S50kodi endef define KODI_INSTALL_INIT_SYSTEMD $(INSTALL) -D -m 644 package/kodi/kodi.service \ $(TARGET_DIR)/usr/lib/systemd/system/kodi.service mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants ln -fs ../../../../usr/lib/systemd/system/kodi.service \ $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/kodi.service endef $(eval $(autotools-package))
shibajee/buildroot
package/kodi/kodi.mk
mk
mit
8,355
[Unit] Description = Kodi Entertainment Center After = network.target [Service] Type = simple ExecStart = /usr/lib/kodi/kodi.bin --standalone -fs -n Restart = on-failure [Install] WantedBy = multi-user.target
shibajee/buildroot
package/kodi/kodi.service
service
mit
212
From 769693d9ddf63b04dd4aad6cad080f3cee3f997e Mon Sep 17 00:00:00 2001 From: Gustavo Zacarias <gustavo@zacarias.com.ar> Date: Thu, 11 Jun 2015 14:08:38 -0300 Subject: [PATCH] Makefile: use autoconf CXX for proper builds Status: applied upstream. Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar> --- Makefile.in | 1 + 1 file changed, 1 insertion(+) diff --git a/Makefile.in b/Makefile.in index 91fb8b2..fe862cd 100644 --- a/Makefile.in +++ b/Makefile.in @@ -23,6 +23,7 @@ mandir = $(prefix)/share/man/man3 headerdir = $(prefix)/include/kompex CC = @CC@ +CXX = @CXX@ CFLAGS = @CFLAGS@ CPPFLAGS = $(CFLAGS) @CPPFLAGS@ LDFLAGS = @LDFLAGS@ -- 2.3.6
shibajee/buildroot
package/kompexsqlite/0001-Makefile-use-autoconf-CXX-for-proper-builds.patch
patch
mit
667
From 3eb064ffa9b43fb5f245b8abda48a1c152a6f2d7 Mon Sep 17 00:00:00 2001 From: me <noemail@nowhere.com> Date: Thu, 20 Nov 2014 14:37:34 -0700 Subject: [PATCH] Append to CFLAGS and CXXFLAGS as setup by ./configure. This can allow users to Customize the SQLite build process with compile time #defines rather than altering the sources. Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> --- Backported from: 3eb064ffa9b43fb5f245b8abda48a1c152a6f2d7 Makefile-shared.mk | 4 ++-- Makefile-static.mk | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Makefile-shared.mk b/Makefile-shared.mk index b2a4920..d15ce3c 100644 --- a/Makefile-shared.mk +++ b/Makefile-shared.mk @@ -12,10 +12,10 @@ OBJS= \ ${objsdir}/sqlite3.o # C Compiler Flags -CFLAGS= -fPIC -MMD -MP +CFLAGS+= -fPIC -MMD -MP # CC Compiler Flags -CPPFLAGS= -DKOMPEX_SQLITEWRAPPER_EXPORT -DKOMPEX_SQLITEWRAPPER_DYN -fPIC -MMD -MP -I${includedir} +CPPFLAGS+= -DKOMPEX_SQLITEWRAPPER_EXPORT -DKOMPEX_SQLITEWRAPPER_DYN -fPIC -MMD -MP -I${includedir} # Link Libraries and Options LDLIBSOPTIONS= -shared -fPIC diff --git a/Makefile-static.mk b/Makefile-static.mk index 429a4ff..0678681 100644 --- a/Makefile-static.mk +++ b/Makefile-static.mk @@ -12,10 +12,10 @@ OBJS= \ ${objsdir}/sqlite3.o # C Compiler Flags -CFLAGS= -MMD -MP +CFLAGS+= -MMD -MP # CC Compiler Flags -CPPFLAGS= -I${includedir} -MMD -MP +CPPFLAGS+= -I${includedir} -MMD -MP # Link Libraries and Options LDLIBSOPTIONS=
shibajee/buildroot
package/kompexsqlite/0002-append-to-cflags-and-cxxflags.patch
patch
mit
1,483
config BR2_PACKAGE_KOMPEXSQLITE bool "kompexsqlite" depends on BR2_USE_WCHAR depends on BR2_TOOLCHAIN_HAS_THREADS depends on BR2_INSTALL_LIBSTDCPP depends on !BR2_STATIC_LIBS help The Kompex SQLite Wrapper is an open source C++ wrapper library for SQLite. http://sqlitewrapper.kompex-online.com/index.php comment "kompexsqlite needs a toolchain w/ C++, wchar, threads, dynamic library" depends on !BR2_INSTALL_LIBSTDCPP || BR2_STATIC_LIBS || \ !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS
shibajee/buildroot
package/kompexsqlite/Config.in
in
mit
509
# Locally calculated sha256 73bec94fe5dd3a24bd8668b3a131a84dbe39a992579eebab1236aa0e73b2c9cc v1.10.12-1.tar.gz
shibajee/buildroot
package/kompexsqlite/kompexsqlite.hash
hash
mit
111
################################################################################ # # kompexsqlite # ################################################################################ KOMPEXSQLITE_VERSION = v1.10.12-1 KOMPEXSQLITE_SOURCE = $(KOMPEXSQLITE_VERSION).tar.gz KOMPEXSQLITE_SITE = https://github.com/Aethelflaed/kompex-sqlite-wrapper/archive KOMPEXSQLITE_INSTALL_STAGING = YES KOMPEXSQLITE_LICENSE = LGPLv3+ (wrapper), Public Domain (bundled sqlite) KOMPEXSQLITE_LICENSE_FILES = LICENSE.txt $(eval $(autotools-package))
shibajee/buildroot
package/kompexsqlite/kompexsqlite.mk
mk
mit
529
config BR2_PACKAGE_KTAP bool "ktap" depends on BR2_LINUX_KERNEL depends on BR2_TOOLCHAIN_HAS_THREADS help ktap is a script-based dynamic tracing tool for Linux It uses a scripting language and lets users trace the Linux kernel dynamically. ktap is designed to give operational insights with interoperability that allows users to tune, troubleshoot and extend kernel and application. It's similar to Linux Systemtap and Solaris Dtrace. ktap doesn't support kernels older than 3.1. To be able to resolve symbols in DSO and for sdt, you need to enable elfutils. Your kernel must have CONFIG_EVENT_TRACING, CONFIG_PERF_EVENTS, and CONFIG_DEBUG_FS enabled to compile. Buildroot automatically enables these in the kernel configuration. http://www.ktap.org comment "ktap needs a Linux kernel to be built" depends on !BR2_LINUX_KERNEL comment "ktap needs a toolchain w/ threads" depends on !BR2_TOOLCHAIN_HAS_THREADS
shibajee/buildroot
package/ktap/Config.in
in
mit
962
# Locally calculated sha256 bc8b03a53c430ae4fcf594ffdf31e2b2ed47a8fee25dd8fea60aa34f75441707 ktap-eb66d40310c93dc82bc8eac889744c1ed1f01f7b.tar.gz
shibajee/buildroot
package/ktap/ktap.hash
hash
mit
147
################################################################################ # # ktap # ################################################################################ KTAP_VERSION = eb66d40310c93dc82bc8eac889744c1ed1f01f7b KTAP_SITE = $(call github,ktap,ktap,$(KTAP_VERSION)) KTAP_LICENSE = GPLv2 KTAP_LICENSE_FILES = LICENSE-GPL ifeq ($(BR2_PACKAGE_ELFUTILS),y) KTAP_DEPENDENCIES += elfutils else KTAP_FLAGS += NO_LIBELF=1 endif define KTAP_BUILD_CMDS $(MAKE) -C $(@D) $(TARGET_CONFIGURE_OPTS) $(KTAP_FLAGS) ktap endef define KTAP_INSTALL_TARGET_CMDS $(INSTALL) -D -m755 $(@D)/ktap $(TARGET_DIR)/usr/bin/ktap endef KTAP_MODULE_MAKE_OPTS = KVERSION=$(LINUX_VERSION_PROBED) $(eval $(kernel-module)) $(eval $(generic-package))
shibajee/buildroot
package/ktap/ktap.mk
mk
mit
740
config BR2_PACKAGE_KVMTOOL bool "kvmtool" depends on BR2_USE_MMU # guest simple init fork() # No MADV_HUGEPAGE define in uClibc(-ng) depends on (BR2_TOOLCHAIN_USES_GLIBC || BR2_TOOLCHAIN_USES_MUSL) # Only mips big-endian seems to be supported (build breaks) # Should work on powerpc64 but the build breaks with missing types depends on BR2_aarch64 || BR2_arm || BR2_armeb || BR2_i386 || \ BR2_mips || BR2_x86_64 # libfdt is only required for DT architectures... # ...but it's not able to build for static targets depends on !(BR2_STATIC_LIBS && (BR2_aarch64 || BR2_arm || BR2_armeb)) select BR2_PACKAGE_DTC if BR2_aarch64 || BR2_arm || BR2_armeb help kvmtool is a lightweight tool for hosting KVM guests. As a pure virtualization tool it only supports guests using the same architecture, though it supports running 32-bit guests on those 64-bit architectures that allow this. https://git.kernel.org/cgit/linux/kernel/git/will/kvmtool.git/tree/README comment "kvmtool needs a glibc or musl toolchain" depends on BR2_USE_MMU depends on BR2_i386 || BR2_mips || BR2_x86_64 depends on !(BR2_TOOLCHAIN_USES_GLIBC || BR2_TOOLCHAIN_USES_MUSL) comment "kvmtool needs a glibc or musl toolchain w/ dynamic library" depends on BR2_USE_MMU depends on BR2_aarch64 || BR2_arm || BR2_armeb depends on !(BR2_TOOLCHAIN_USES_GLIBC || BR2_TOOLCHAIN_USES_MUSL) || \ BR2_STATIC_LIBS
shibajee/buildroot
package/kvmtool/Config.in
in
mit
1,401
################################################################################ # # kvmtool # ################################################################################ KVMTOOL_VERSION = 372f583d359a5bdcbbe7268809c8d1dc179c64d2 KVMTOOL_SITE = $(BR2_KERNEL_MIRROR)/scm/linux/kernel/git/will/kvmtool.git KVMTOOL_SITE_METHOD = git KVMTOOL_DEPENDENCIES = \ $(if $(BR2_PACKAGE_BINUTILS),binutils) \ $(if $(BR2_PACKAGE_DTC),dtc) \ $(if $(BR2_PACKAGE_LIBAIO),libaio) \ $(if $(BR2_PACKAGE_LIBGTK3),libgtk3) \ $(if $(BR2_PACKAGE_LIBVNCSERVER),libvncserver) \ $(if $(BR2_PACKAGE_SDL),sdl) \ $(if $(BR2_PACKAGE_ZLIB),zlib) KVMTOOL_LICENSE = GPLv2 KVMTOOL_LICENSE_FILES = COPYING # This is required to convert a static binary (init helper) back into # object-file format, and in multilib toolchains like CS 2012.09 for x86 # the default is i386, hence when building for x86_64 things break since # LD doesn't autodetect the input file format. # GCC-as-linker can't accomplish this feat easily either since it's mixing # static content (guest_init.o) with dynamic one (lkvm) making # a relocatable output file. # The purpose of this trick is to embed the init helper into the main # binary to help users in guest system startup, which would otherwise # require more complex guest images. # This needs revisiting if/when X32 ABI support is added. # # If more packages need this (unlikely) an ld wrapper might be a better # solution, using gcc -dumpspecs information. KVMTOOL_EXTRA_LDFLAGS = \ $(if $(BR2_x86_64),-m elf_x86_64) # Disable -Werror, otherwise musl is not happy KVMTOOL_MAKE_OPTS = \ CROSS_COMPILE="$(TARGET_CROSS)" \ LDFLAGS="$(TARGET_LDFLAGS) $(KVMTOOL_EXTRA_LDFLAGS)" \ WERROR=0 define KVMTOOL_BUILD_CMDS $(TARGET_MAKE_ENV) ARCH=$(KERNEL_ARCH) $(MAKE) -C $(@D) $(KVMTOOL_MAKE_OPTS) endef define KVMTOOL_INSTALL_TARGET_CMDS $(TARGET_MAKE_ENV) ARCH=$(KERNEL_ARCH) $(MAKE) -C $(@D) \ $(KVMTOOL_MAKE_OPTS) install DESTDIR=$(TARGET_DIR) prefix=/usr endef $(eval $(generic-package))
shibajee/buildroot
package/kvmtool/kvmtool.mk
mk
mit
2,006
config BR2_PACKAGE_KYUA bool "kyua" depends on BR2_INSTALL_LIBSTDCPP depends on BR2_PACKAGE_HAS_LUAINTERPRETER # lutok depends on !BR2_PACKAGE_LUAJIT # lutok depends on BR2_USE_MMU # atf select BR2_PACKAGE_ATF select BR2_PACKAGE_LUTOK select BR2_PACKAGE_SQLITE help Kyua is a testing framework for infrastructure software, originally designed to equip BSD-based operating systems with a test suite. This means that Kyua is lightweight and simple, and that Kyua integrates well with various build systems and continuous integration frameworks. https://github.com/jmmv/kyua comment "kyua needs a toolchain w/ C++ and full Lua" depends on !BR2_INSTALL_LIBSTDCPP || BR2_PACKAGE_LUAJIT depends on BR2_PACKAGE_HAS_LUAINTERPRETER depends on BR2_USE_MMU
shibajee/buildroot
package/kyua/Config.in
in
mit
778
# Locally calculated sha256 2b8b64a458b642df75086eeb73e8073d105b8d9cff04c9b1a905b68bc8502560 kyua-0.11.tar.gz
shibajee/buildroot
package/kyua/kyua.hash
hash
mit
110
################################################################################ # # kyua # ################################################################################ KYUA_VERSION = 0.11 KYUA_SITE = https://github.com/jmmv/kyua/releases/download/kyua-$(KYUA_VERSION) KYUA_DEPENDENCIES = host-pkgconf atf lutok sqlite KYUA_CONF_OPTS = --without-doxygen --without-atf KYUA_LICENSE = BSD-3c KYUA_LICENSE_FILES = COPYING KYUA_CONF_ENV = \ kyua_cv_attribute_noreturn=yes \ kyua_cv_getcwd_dyn=yes \ kyua_cv_lchmod_works=no \ kyua_cv_getopt_gnu=yes \ kyua_cv_getopt_optind_reset_value=0 \ kyua_cv_signals_lastno=15 define KYUA_INSTALL_CONFIG $(INSTALL) -D -m 644 $(@D)/examples/kyua.conf $(TARGET_DIR)/etc/kyua/kyua.conf endef KYUA_POST_INSTALL_HOOKS += KYUA_INSTALL_CONFIG $(eval $(autotools-package))
shibajee/buildroot
package/kyua/kyua.mk
mk
mit
813
Various patches to fix autoreconf errors. All patches besides - AM_ICONV in configure.in are already applied upstream: http://lame.cvs.sourceforge.net/viewvc/lame/lame/configure.in?r1=1.145&r2=1.146 http://lame.cvs.sourceforge.net/viewvc/lame/lame/doc/html/Makefile.am?r1=1.8&r2=1.9 http://lame.cvs.sourceforge.net/viewvc/lame/lame/doc/man/Makefile.am?r1=1.1&r2=1.2 libmp3lame/i386/Makefile.am patch ported from Debian http://anonscm.debian.org/cgit/pkg-multimedia/lame.git/tree/debian/patches/ansi2knr2devnull.patch Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> diff -uNr lame-3.99.5.org/configure.in lame-3.99.5/configure.in --- lame-3.99.5.org/configure.in 2012-02-28 19:50:27.000000000 +0100 +++ lame-3.99.5/configure.in 2015-04-11 11:36:15.464835008 +0200 @@ -77,9 +77,6 @@ AC_MSG_RESULT(${GCC_version}) fi -dnl more automake stuff -AM_C_PROTOTYPES - AC_CHECK_HEADER(dmalloc.h) if test "${ac_cv_header_dmalloc_h}" = "yes"; then AM_WITH_DMALLOC @@ -376,8 +373,6 @@ AC_CHECK_LIB(curses, initscr, HAVE_TERMCAP="curses") AC_CHECK_LIB(ncurses, initscr, HAVE_TERMCAP="ncurses") -AM_ICONV - dnl math lib AC_CHECK_LIB(m, cos, USE_LIBM="-lm") dnl free fast math library diff -uNr lame-3.99.5.org/doc/html/Makefile.am lame-3.99.5/doc/html/Makefile.am --- lame-3.99.5.org/doc/html/Makefile.am 2010-09-30 22:58:40.000000000 +0200 +++ lame-3.99.5/doc/html/Makefile.am 2015-04-11 11:37:02.880239754 +0200 @@ -1,6 +1,6 @@ ## $Id: Makefile.am,v 1.7 2010/09/30 20:58:40 jaz001 Exp $ -AUTOMAKE_OPTIONS = foreign ansi2knr +AUTOMAKE_OPTIONS = foreign docdir = $(datadir)/doc pkgdocdir = $(docdir)/$(PACKAGE) diff -uNr lame-3.99.5.org/doc/man/Makefile.am lame-3.99.5/doc/man/Makefile.am --- lame-3.99.5.org/doc/man/Makefile.am 2000-10-22 13:39:44.000000000 +0200 +++ lame-3.99.5/doc/man/Makefile.am 2015-04-11 11:37:08.704167318 +0200 @@ -1,6 +1,6 @@ ## $Id: Makefile.am,v 1.1 2000/10/22 11:39:44 aleidinger Exp $ -AUTOMAKE_OPTIONS = foreign ansi2knr +AUTOMAKE_OPTIONS = foreign man_MANS = lame.1 EXTRA_DIST = ${man_MANS} diff -uNr lame-3.99.5.org/libmp3lame/i386/Makefile.am lame-3.99.5/libmp3lame/i386/Makefile.am --- lame-3.99.5.org/libmp3lame/i386/Makefile.am 2011-04-04 11:42:34.000000000 +0200 +++ lame-3.99.5/libmp3lame/i386/Makefile.am 2015-04-11 11:37:35.191833351 +0200 @@ -1,6 +1,6 @@ ## $Id: Makefile.am,v 1.26 2011/04/04 09:42:34 aleidinger Exp $ -AUTOMAKE_OPTIONS = foreign $(top_srcdir)/ansi2knr +AUTOMAKE_OPTIONS = foreign DEFS = @DEFS@ @CONFIG_DEFS@
shibajee/buildroot
package/lame/0001-configure.patch
patch
mit
2,501
Include GTK-1 autoconf directives in build system. Applied-Upstream: http://lame.cvs.sf.net/viewvc/lame/lame/acinclude.m4?r1=1.5&r2=1.6 Downloaded from http://lame.cvs.sf.net/viewvc/lame/lame/acinclude.m4?r1=1.5&r2=1.6&view=patch to fix autoreconf. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> --- a/acinclude.m4 2006/12/21 09:03:03 1.5 +++ b/acinclude.m4 2012/06/18 20:51:05 1.6 @@ -85,4 +85,197 @@ [AC_MSG_WARN(can't check for IEEE854 compliant 80 bit floats)] )])]) # alex_IEEE854_FLOAT80 +# Configure paths for GTK+ +# Owen Taylor 97-11-3 +dnl AM_PATH_GTK([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]]) +dnl Test for GTK, and define GTK_CFLAGS and GTK_LIBS +dnl +AC_DEFUN([AM_PATH_GTK], +[dnl +dnl Get the cflags and libraries from the gtk-config script +dnl +AC_ARG_WITH(gtk-prefix,[ --with-gtk-prefix=PFX Prefix where GTK is installed (optional)], + gtk_config_prefix="$withval", gtk_config_prefix="") +AC_ARG_WITH(gtk-exec-prefix,[ --with-gtk-exec-prefix=PFX Exec prefix where GTK is installed (optional)], + gtk_config_exec_prefix="$withval", gtk_config_exec_prefix="") +AC_ARG_ENABLE(gtktest, [ --disable-gtktest Do not try to compile and run a test GTK program], + , enable_gtktest=yes) + + for module in . $4 + do + case "$module" in + gthread) + gtk_config_args="$gtk_config_args gthread" + ;; + esac + done + + if test x$gtk_config_exec_prefix != x ; then + gtk_config_args="$gtk_config_args --exec-prefix=$gtk_config_exec_prefix" + if test x${GTK_CONFIG+set} != xset ; then + GTK_CONFIG=$gtk_config_exec_prefix/bin/gtk-config + fi + fi + if test x$gtk_config_prefix != x ; then + gtk_config_args="$gtk_config_args --prefix=$gtk_config_prefix" + if test x${GTK_CONFIG+set} != xset ; then + GTK_CONFIG=$gtk_config_prefix/bin/gtk-config + fi + fi + + AC_PATH_PROG(GTK_CONFIG, gtk-config, no) + min_gtk_version=ifelse([$1], ,0.99.7,$1) + AC_MSG_CHECKING(for GTK - version >= $min_gtk_version) + no_gtk="" + if test "$GTK_CONFIG" = "no" ; then + no_gtk=yes + else + GTK_CFLAGS=`$GTK_CONFIG $gtk_config_args --cflags` + GTK_LIBS=`$GTK_CONFIG $gtk_config_args --libs` + gtk_config_major_version=`$GTK_CONFIG $gtk_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` + gtk_config_minor_version=`$GTK_CONFIG $gtk_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` + gtk_config_micro_version=`$GTK_CONFIG $gtk_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` + if test "x$enable_gtktest" = "xyes" ; then + ac_save_CFLAGS="$CFLAGS" + ac_save_LIBS="$LIBS" + CFLAGS="$CFLAGS $GTK_CFLAGS" + LIBS="$GTK_LIBS $LIBS" +dnl +dnl Now check if the installed GTK is sufficiently new. (Also sanity +dnl checks the results of gtk-config to some extent +dnl + rm -f conf.gtktest + AC_TRY_RUN([ +#include <gtk/gtk.h> +#include <stdio.h> +#include <stdlib.h> + +int +main () +{ + int major, minor, micro; + char *tmp_version; + + system ("touch conf.gtktest"); + + /* HP/UX 9 (%@#!) writes to sscanf strings */ + tmp_version = g_strdup("$min_gtk_version"); + if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) { + printf("%s, bad version string\n", "$min_gtk_version"); + exit(1); + } + + if ((gtk_major_version != $gtk_config_major_version) || + (gtk_minor_version != $gtk_config_minor_version) || + (gtk_micro_version != $gtk_config_micro_version)) + { + printf("\n*** 'gtk-config --version' returned %d.%d.%d, but GTK+ (%d.%d.%d)\n", + $gtk_config_major_version, $gtk_config_minor_version, $gtk_config_micro_version, + gtk_major_version, gtk_minor_version, gtk_micro_version); + printf ("*** was found! If gtk-config was correct, then it is best\n"); + printf ("*** to remove the old version of GTK+. You may also be able to fix the error\n"); + printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n"); + printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n"); + printf("*** required on your system.\n"); + printf("*** If gtk-config was wrong, set the environment variable GTK_CONFIG\n"); + printf("*** to point to the correct copy of gtk-config, and remove the file config.cache\n"); + printf("*** before re-running configure\n"); + } +#if defined (GTK_MAJOR_VERSION) && defined (GTK_MINOR_VERSION) && defined (GTK_MICRO_VERSION) + else if ((gtk_major_version != GTK_MAJOR_VERSION) || + (gtk_minor_version != GTK_MINOR_VERSION) || + (gtk_micro_version != GTK_MICRO_VERSION)) + { + printf("*** GTK+ header files (version %d.%d.%d) do not match\n", + GTK_MAJOR_VERSION, GTK_MINOR_VERSION, GTK_MICRO_VERSION); + printf("*** library (version %d.%d.%d)\n", + gtk_major_version, gtk_minor_version, gtk_micro_version); + } +#endif /* defined (GTK_MAJOR_VERSION) ... */ + else + { + if ((gtk_major_version > major) || + ((gtk_major_version == major) && (gtk_minor_version > minor)) || + ((gtk_major_version == major) && (gtk_minor_version == minor) && (gtk_micro_version >= micro))) + { + return 0; + } + else + { + printf("\n*** An old version of GTK+ (%d.%d.%d) was found.\n", + gtk_major_version, gtk_minor_version, gtk_micro_version); + printf("*** You need a version of GTK+ newer than %d.%d.%d. The latest version of\n", + major, minor, micro); + printf("*** GTK+ is always available from ftp://ftp.gtk.org.\n"); + printf("***\n"); + printf("*** If you have already installed a sufficiently new version, this error\n"); + printf("*** probably means that the wrong copy of the gtk-config shell script is\n"); + printf("*** being found. The easiest way to fix this is to remove the old version\n"); + printf("*** of GTK+, but you can also set the GTK_CONFIG environment to point to the\n"); + printf("*** correct copy of gtk-config. (In this case, you will have to\n"); + printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); + printf("*** so that the correct libraries are found at run-time))\n"); + } + } + return 1; +} +],, no_gtk=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) + CFLAGS="$ac_save_CFLAGS" + LIBS="$ac_save_LIBS" + fi + fi + if test "x$no_gtk" = x ; then + AC_MSG_RESULT(yes) + ifelse([$2], , :, [$2]) + else + AC_MSG_RESULT(no) + if test "$GTK_CONFIG" = "no" ; then + echo "*** The gtk-config script installed by GTK could not be found" + echo "*** If GTK was installed in PREFIX, make sure PREFIX/bin is in" + echo "*** your path, or set the GTK_CONFIG environment variable to the" + echo "*** full path to gtk-config." + else + if test -f conf.gtktest ; then + : + else + echo "*** Could not run GTK test program, checking why..." + CFLAGS="$CFLAGS $GTK_CFLAGS" + LIBS="$LIBS $GTK_LIBS" + AC_TRY_LINK([ +#include <gtk/gtk.h> +#include <stdio.h> +], [ return ((gtk_major_version) || (gtk_minor_version) || (gtk_micro_version)); ], + [ echo "*** The test program compiled, but did not run. This usually means" + echo "*** that the run-time linker is not finding GTK or finding the wrong" + echo "*** version of GTK. If it is not finding GTK, you'll need to set your" + echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" + echo "*** to the installed location Also, make sure you have run ldconfig if that" + echo "*** is required on your system" + echo "***" + echo "*** If you have an old version installed, it is best to remove it, although" + echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" + echo "***" + echo "*** If you have a RedHat 5.0 system, you should remove the GTK package that" + echo "*** came with the system with the command" + echo "***" + echo "*** rpm --erase --nodeps gtk gtk-devel" ], + [ echo "*** The test program failed to compile or link. See the file config.log for the" + echo "*** exact error that occured. This usually means GTK was incorrectly installed" + echo "*** or that you have moved GTK since it was installed. In the latter case, you" + echo "*** may want to edit the gtk-config script: $GTK_CONFIG" ]) + CFLAGS="$ac_save_CFLAGS" + LIBS="$ac_save_LIBS" + fi + fi + GTK_CFLAGS="" + GTK_LIBS="" + ifelse([$3], , :, [$3]) + fi + AC_SUBST(GTK_CFLAGS) + AC_SUBST(GTK_LIBS) + rm -f conf.gtktest +])
shibajee/buildroot
package/lame/0002-gtk1-ac-directives.patch
patch
mit
8,986
Fix compile on 32bit Intel Downloaded from http://anonscm.debian.org/cgit/pkg-multimedia/lame.git/tree/debian/patches/msse.patch Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> Description: Build xmm_quantize_sub.c with -msse Author: Sebastian Ramacher <sramacher@debian.org> Bug: http://sourceforge.net/p/lame/bugs/443/ Bug-Debian: https://bugs.debian.org/760047 Forwarded: http://sourceforge.net/p/lame/bugs/443/ Last-Update: 2014-08-31 --- lame-3.99.5+repack1.orig/libmp3lame/vector/Makefile.am +++ lame-3.99.5+repack1/libmp3lame/vector/Makefile.am @@ -20,6 +20,7 @@ xmm_sources = xmm_quantize_sub.c if WITH_XMM liblamevectorroutines_la_SOURCES = $(xmm_sources) +liblamevectorroutines_la_CFLAGS = -msse endif noinst_HEADERS = lame_intrin.h
shibajee/buildroot
package/lame/0003-msse.patch
patch
mit
760
config BR2_PACKAGE_LAME bool "lame" help LAME is a high quality MPEG Audio Layer III (MP3) encoder. http://lame.sourceforge.net/
shibajee/buildroot
package/lame/Config.in
in
mit
138
# Locally computed: sha256 24346b4158e4af3bd9f2e194bb23eb473c75fb7377011523353196b19b9a23ff lame-3.99.5.tar.gz
shibajee/buildroot
package/lame/lame.hash
hash
mit
113
################################################################################ # # lame # ################################################################################ LAME_VERSION_MAJOR = 3.99 LAME_VERSION = $(LAME_VERSION_MAJOR).5 LAME_SITE = http://downloads.sourceforge.net/project/lame/lame/$(LAME_VERSION_MAJOR) LAME_DEPENDENCIES = host-pkgconf LAME_AUTORECONF = YES LAME_INSTALL_STAGING = YES LAME_CONF_ENV = GTK_CONFIG=/bin/false LAME_CONF_OPTS = --enable-dynamic-frontends LAME_LICENSE = LGPLv2+ LAME_LICENSE_FILES = COPYING ifeq ($(BR2_PACKAGE_LIBSNDFILE),y) LAME_DEPENDENCIES += libsndfile LAME_CONF_OPTS += --with-fileio=sndfile endif ifeq ($(BR2_PACKAGE_NCURSES),y) LAME_DEPENDENCIES += ncurses endif ifeq ($(BR2_ENDIAN),"BIG") define LAME_BIGENDIAN_ARCH echo "#define WORDS_BIGENDIAN 1" >>$(@D)/config.h endef endif LAME_POST_CONFIGURE_HOOKS += LAME_BIGENDIAN_ARCH $(eval $(autotools-package))
shibajee/buildroot
package/lame/lame.mk
mk
mit
920
comment "lapack/blas needs a toolchain w/ fortran" depends on !(BR2_powerpc && BR2_TOOLCHAIN_USES_UCLIBC) depends on !BR2_TOOLCHAIN_HAS_FORTRAN config BR2_PACKAGE_LAPACK bool "lapack/blas" depends on BR2_TOOLCHAIN_HAS_FORTRAN # _fpu_control is used on PowerPC, but not available with uClibc depends on !(BR2_powerpc && BR2_TOOLCHAIN_USES_UCLIBC) help LAPACK and BLAS FORTRAN implementation. This package installs two libraries: libblas and liblapack. http://www.netlib.org/lapack/ config BR2_PACKAGE_LAPACK_COMPLEX bool "Complex/Complex16 support" depends on BR2_PACKAGE_LAPACK default y help Builds support for COMPLEX and COMPLEX16 data types.
shibajee/buildroot
package/lapack/Config.in
in
mit
672
# Locally computed: sha256 888a50d787a9d828074db581c80b2d22bdb91435a673b1bf6cd6eb51aa50d1de lapack-3.6.1.tgz
shibajee/buildroot
package/lapack/lapack.hash
hash
mit
111
################################################################################ # # lapack # ################################################################################ LAPACK_VERSION = 3.6.1 LAPACK_SOURCE = lapack-$(LAPACK_VERSION).tgz LAPACK_LICENSE = BSD-3c LAPACK_LICENSE_FILES = LICENSE LAPACK_SITE = http://www.netlib.org/lapack LAPACK_INSTALL_STAGING = YES LAPACK_CONF_OPTS = -DLAPACKE=ON -DCBLAS=ON ifeq ($(BR2_PACKAGE_LAPACK_COMPLEX),y) LAPACK_CONF_OPTS += -DBUILD_COMPLEX=ON -DBUILD_COMPLEX16=ON else LAPACK_CONF_OPTS += -DBUILD_COMPLEX=OFF -DBUILD_COMPLEX16=OFF endif $(eval $(cmake-package))
shibajee/buildroot
package/lapack/lapack.mk
mk
mit
613
Usee $(CC) to enable cross compiling and link to the right ncurses library. Signed-off-by: Qais Yousef <qais.yousef@imgtec.com> --- latencytop-0.5/Makefile.old 2012-04-18 11:59:39.748084334 +0100 +++ latencytop-0.5/Makefile 2012-04-18 12:00:08.659112340 +0100 @@ -4,7 +4,7 @@ DESTDIR = SBINDIR = /usr/sbin XCFLAGS = -W -g `pkg-config --cflags glib-2.0` -D_FORTIFY_SOURCE=2 -Wno-sign-compare -LDF = -Wl,--as-needed `pkg-config --libs glib-2.0` -lncursesw +LDF = -Wl,--as-needed `pkg-config --libs glib-2.0` -lncurses OBJS= latencytop.o text_display.o translate.o fsync.o @@ -26,10 +26,10 @@ # We write explicity this "implicit rule" %.o : %.c - gcc -c $(CFLAGS) $(XCFLAGS) $< -o $@ + $(CC) -c $(CFLAGS) $(XCFLAGS) $< -o $@ latencytop: $(OBJS) latencytop.h Makefile - gcc $(CFLAGS) $(OBJS) $(LDF) -o latencytop + $(CC) $(CFLAGS) $(OBJS) $(LDF) -o latencytop clean: rm -f *~ latencytop DEADJOE *.o
shibajee/buildroot
package/latencytop/0001-makefile.patch
patch
mit
927
config BR2_PACKAGE_LATENCYTOP bool "latencytop" depends on BR2_USE_WCHAR # libglib2 depends on BR2_TOOLCHAIN_HAS_THREADS # libglib2 depends on BR2_USE_MMU # libglib2 select BR2_PACKAGE_NCURSES select BR2_PACKAGE_LIBGLIB2 help There are many types and causes of latency. LatencyTOP focuses on the type of latency that causes skips in audio, stutters in your desktop experience or that overloads your server (while you have plenty of CPU power left). LatencyTOP focuses on the cases where the applications want to run and execute useful code, but there's some resource that's not currently available (and the kernel then blocks the process). This is done both on a system level and on a per process level, so that you can see what's happening to the system, and which process is suffering and/or causing the delays. http://www.latencytop.org comment "latencytop needs a toolchain w/ wchar, threads" depends on BR2_USE_MMU depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS
shibajee/buildroot
package/latencytop/Config.in
in
mit
1,024
# locally computed sha256 9e7f72fbea7bd918e71212a1eabaad8488d2c602205d2e3c95d62cd57e9203ef latencytop-0.5.tar.gz
shibajee/buildroot
package/latencytop/latencytop.hash
hash
mit
115
################################################################################ # # latencytop # ################################################################################ LATENCYTOP_VERSION = 0.5 LATENCYTOP_SITE = http://www.latencytop.org/download LATENCYTOP_DEPENDENCIES = libglib2 ncurses LATENCYTOP_LICENSE = GPLv2 LATENCYTOP_LICENSE_FILES = latencytop.c # NOTE: GTK is heavy weight, we intentionally build the text (ncurses) # version only define LATENCYTOP_BUILD_CMDS $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) HAS_GTK_GUI= endef define LATENCYTOP_INSTALL_TARGET_CMDS $(MAKE) install -C $(@D) DESTDIR=$(TARGET_DIR) HAS_GTK_GUI= endef $(eval $(generic-package))
shibajee/buildroot
package/latencytop/latencytop.mk
mk
mit
680
config BR2_PACKAGE_LBASE64 bool "lbase64" depends on BR2_PACKAGE_HAS_LUAINTERPRETER depends on BR2_PACKAGE_LUA_5_1 || BR2_PACKAGE_LUAJIT help A base64 library for Lua http://luaforge.net/projects/lbase64/ comment "lbase64 needs a Lua 5.1 interpreter" depends on !BR2_PACKAGE_LUA_5_1 depends on !BR2_PACKAGE_LUAJIT
shibajee/buildroot
package/lbase64/Config.in
in
mit
328
# Locally calculated sha256 7326658d48a70382b496eb88220b0c398c19ed712e39863939330fec0533362a lbase64-20120820-1.src.rock
shibajee/buildroot
package/lbase64/lbase64.hash
hash
mit
122
################################################################################ # # lbase64 # ################################################################################ LBASE64_VERSION = 20120820-1 LBASE64_SUBDIR = base64 LBASE64_LICENSE = Public domain LBASE64_LICENSE_FILES = $(LBASE64_SUBDIR)/README $(eval $(luarocks-package))
shibajee/buildroot
package/lbase64/lbase64.mk
mk
mit
340
config BR2_PACKAGE_LBREAKOUT2 bool "LBreakout2" select BR2_PACKAGE_SDL select BR2_PACKAGE_LIBPNG select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE help LBreakout2 is the successor to LBreakout, a breakout-style arcade game in the manner of Arkanoid. Requires SDL, libpng, and optionnally SDL_mixer/SDL_net. A display with minimum 640x480 resolution, a keyboard and a mouse are recommanded. http://lgames.sourceforge.net/index.php?project=LBreakout2 if BR2_PACKAGE_LBREAKOUT2 config BR2_PACKAGE_LBREAKOUT2_AUDIO bool "audio support" default y select BR2_PACKAGE_SDL_MIXER help Activates audio support in LBreakout2. Will add SDL_mixer. config BR2_PACKAGE_LBREAKOUT2_NET bool "network support" default y select BR2_PACKAGE_SDL_NET help Activates network support LBreakout2. Will add SDL_net. endif
shibajee/buildroot
package/lbreakout2/Config.in
in
mit
846
# Locally computed: sha256 0b90716d52e67c27ff41ab7aa5c09dad4f5f19a78076cc57dd4b4d7ed2c1dbd9 lbreakout2-2.6.4.tar.gz
shibajee/buildroot
package/lbreakout2/lbreakout2.hash
hash
mit
118
################################################################################ # # lbreakout2 # ################################################################################ LBREAKOUT2_VERSION_MAJOR = 2.6 LBREAKOUT2_VERSION = $(LBREAKOUT2_VERSION_MAJOR).4 LBREAKOUT2_SITE = http://downloads.sourceforge.net/lgames/lbreakout2/$(LBREAKOUT2_VERSION_MAJOR) LBREAKOUT2_LICENSE = GPLv2+ LBREAKOUT2_LICENSE_FILES = COPYING LBREAKOUT2_DEPENDENCIES = sdl libpng LBREAKOUT2_CONF_ENV = \ SDL_CONFIG="$(STAGING_DIR)/usr/bin/sdl-config" ifeq ($(BR2_NEEDS_GETTEXT_IF_LOCALE),y) LBREAKOUT2_DEPENDENCIES += gettext LBREAKOUT2_CONF_ENV += LIBS=-lintl endif ifeq ($(BR2_PACKAGE_LBREAKOUT2_AUDIO),y) LBREAKOUT2_DEPENDENCIES += sdl_mixer LBREAKOUT2_CONF_OPTS += --enable-audio=yes else LBREAKOUT2_CONF_OPTS += --disable-audio endif ifeq ($(BR2_PACKAGE_LBREAKOUT2_NET),y) LBREAKOUT2_DEPENDENCIES += sdl_net LBREAKOUT2_CONF_OPTS += --enable-network=yes else LBREAKOUT2_CONF_OPTS += --disable-network endif $(eval $(autotools-package))
shibajee/buildroot
package/lbreakout2/lbreakout2.mk
mk
mit
1,026
config BR2_PACKAGE_LCDAPI bool "lcdapi" depends on BR2_INSTALL_LIBSTDCPP depends on BR2_TOOLCHAIN_HAS_THREADS help C++ client API for lcdproc, containing a set of widget classes. https://github.com/spdawson/lcdapi comment "lcdapi needs a toolchain w/ C++, threads" depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS
shibajee/buildroot
package/lcdapi/Config.in
in
mit
342
# Locally computed sha256 fa26b53fd543ebab825d55cafb4c88af6a71ac3dcf86d4e8bcd3592be4212b55 lcdapi-v0.10.tar.gz
shibajee/buildroot
package/lcdapi/lcdapi.hash
hash
mit
111
################################################################################ # # lcdapi # ################################################################################ LCDAPI_VERSION = v0.10 LCDAPI_SITE = $(call github,spdawson,lcdapi,$(LCDAPI_VERSION)) LCDAPI_LICENSE = LGPLv2.1+ LCDAPI_LICENSE_FILES = COPYING LCDAPI_AUTORECONF = YES LCDAPI_INSTALL_STAGING = YES define LCDAPI_CREATE_M4_DIR mkdir -p $(@D)/m4 endef LCDAPI_POST_PATCH_HOOKS += LCDAPI_CREATE_M4_DIR $(eval $(autotools-package))
shibajee/buildroot
package/lcdapi/lcdapi.mk
mk
mit
506
Fix the default LCDd configuration file, so that the DriverPath is set to the correct lcdproc library install path, rather than the dummy/default path. Signed-off-by: Simon Dawson <spdawson at gmail.com> --- --- lcdproc-0.5.3/LCDd.conf.orig 2009-06-20 14:48:34.000000000 +0100 +++ lcdproc-0.5.3/LCDd.conf 2010-05-11 10:02:21.000000000 +0100 @@ -34,7 +34,7 @@ # the driver modules and will thus not be able to # function properly. # NOTE: Always place a slash as last character ! -DriverPath=server/drivers/ +DriverPath=/usr/lib/lcdproc/ # Tells the server to load the given drivers. Multiple lines can be given. # The name of the driver is case sensitive and determines the section
shibajee/buildroot
package/lcdproc/0001-LCDd.conf.patch
patch
mit
721
Fix musl build Partly downloaded from http://lists.omnipotent.net/pipermail/lcdproc/2015-November/014291.html http://lists.omnipotent.net/pipermail/lcdproc/2015-November/014281.html Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> diff -uNr lcdproc-0.5.7.org/clients/lcdproc/machine.h lcdproc-0.5.7/clients/lcdproc/machine.h --- lcdproc-0.5.7.org/clients/lcdproc/machine.h 2012-08-19 16:29:07.000000000 +0200 +++ lcdproc-0.5.7/clients/lcdproc/machine.h 2016-01-30 14:07:33.641802847 +0100 @@ -12,6 +12,7 @@ #ifndef _lcdproc_machine_h_ #define _lcdproc_machine_h_ +#include <time.h> #include "shared/LL.h" #ifndef LOADAVG_NSTATS diff -uNr lcdproc-0.5.7.org/server/drivers/hd44780-pifacecad.c lcdproc-0.5.7/server/drivers/hd44780-pifacecad.c --- lcdproc-0.5.7.org/server/drivers/hd44780-pifacecad.c 2014-03-23 11:22:09.000000000 +0100 +++ lcdproc-0.5.7/server/drivers/hd44780-pifacecad.c 2016-01-30 14:12:03.521279729 +0100 @@ -54,6 +54,7 @@ #include <unistd.h> #include <fcntl.h> #include <sys/ioctl.h> +#include <linux/ioctl.h> #include <stdint.h> #include <linux/spi/spidev.h> diff -uNr lcdproc-0.5.7.org/server/drivers/hd44780-rpi.c lcdproc-0.5.7/server/drivers/hd44780-rpi.c --- lcdproc-0.5.7.org/server/drivers/hd44780-rpi.c 2014-03-23 11:22:09.000000000 +0100 +++ lcdproc-0.5.7/server/drivers/hd44780-rpi.c 2016-01-30 14:04:10.288112853 +0100 @@ -285,7 +285,7 @@ /* Unmap and free memory */ if (gpio_map != NULL) - munmap((caddr_t) gpio_map, GPIO_BLOCK_SIZE); + munmap((void *) gpio_map, GPIO_BLOCK_SIZE); if (p->rpi_gpio != NULL) free(p->rpi_gpio); p->rpi_gpio = NULL; diff -uNr lcdproc-0.5.7.org/server/drivers/hd44780-spi.c lcdproc-0.5.7/server/drivers/hd44780-spi.c --- lcdproc-0.5.7.org/server/drivers/hd44780-spi.c 2014-03-23 11:22:09.000000000 +0100 +++ lcdproc-0.5.7/server/drivers/hd44780-spi.c 2016-01-30 14:11:11.604763500 +0100 @@ -29,6 +29,7 @@ #include <unistd.h> #include <fcntl.h> #include <sys/ioctl.h> +#include <linux/ioctl.h> #include <stdint.h> #include <linux/spi/spidev.h> diff -uNr lcdproc-0.5.7.org/server/drivers/mtc_s16209x.c lcdproc-0.5.7/server/drivers/mtc_s16209x.c --- lcdproc-0.5.7.org/server/drivers/mtc_s16209x.c 2011-08-14 14:29:16.000000000 +0200 +++ lcdproc-0.5.7/server/drivers/mtc_s16209x.c 2016-01-30 14:13:10.691122839 +0100 @@ -49,6 +49,7 @@ #include <fcntl.h> #include <string.h> #include <errno.h> +#include <sys/file.h> #ifdef HAVE_CONFIG_H # include "config.h" diff -uNr lcdproc-0.5.7.org/server/drivers/rawserial.c lcdproc-0.5.7/server/drivers/rawserial.c --- lcdproc-0.5.7.org/server/drivers/rawserial.c 2014-03-23 11:22:10.000000000 +0100 +++ lcdproc-0.5.7/server/drivers/rawserial.c 2016-01-30 14:03:43.465779507 +0100 @@ -60,13 +60,13 @@ /** \name Event loop timing. refresh_time and refresh_delta form the * event loop timing mechanism for configurable update rates. *@{*/ - uint refresh_time; /**< time at the last screen update */ - uint refresh_delta; /**< time step to next screen update */ + unsigned int refresh_time; /**< time at the last screen update */ + unsigned int refresh_delta; /**< time step to next screen update */ /**@}*/ } PrivateData; /* Local prototypes */ -static uint get_millisecond_time(void); +static unsigned int get_millisecond_time(void); /* Vars for the server core */ @@ -303,7 +303,7 @@ PrivateData *p = drvthis->private_data; char out[LCD_MAX_WIDTH * LCD_MAX_HEIGHT]; - uint currentTime = get_millisecond_time(); + unsigned int currentTime = get_millisecond_time(); int t_delta = currentTime - p->refresh_time; /* @@ -415,7 +415,7 @@ * * \return int with current millisecond time. */ -static uint +static unsigned int get_millisecond_time(void) { struct timeval ts;
shibajee/buildroot
package/lcdproc/0002-musl.patch
patch
mit
3,754
comment "lcdproc needs a toolchain w/ dynamic library" depends on BR2_STATIC_LIBS config BR2_PACKAGE_LCDPROC bool "lcdproc" depends on BR2_USE_MMU # fork() depends on !BR2_STATIC_LIBS select BR2_PACKAGE_FREETYPE select BR2_PACKAGE_NCURSES select BR2_PACKAGE_ZLIB help LCD display driver daemon and clients http://lcdproc.org/ if BR2_PACKAGE_LCDPROC config BR2_PACKAGE_LCDPROC_DRIVERS string "List of drivers to build" default "all" help Specify a comma-separated list of lcdproc drivers to be built config BR2_PACKAGE_LCDPROC_MENUS bool "Menu support" help Enable support for lcdproc menus endif
shibajee/buildroot
package/lcdproc/Config.in
in
mit
628
# Locally computed: sha256 843007d377adc856529ed0c7c42c9a7563043f06b1b73add0372bba3a3029804 lcdproc-0.5.7.tar.gz
shibajee/buildroot
package/lcdproc/lcdproc.hash
hash
mit
115
################################################################################ # # lcdproc # ################################################################################ LCDPROC_VERSION = 0.5.7 LCDPROC_SITE = http://downloads.sourceforge.net/project/lcdproc/lcdproc/$(LCDPROC_VERSION) LCDPROC_LICENSE = GPLv2+ LCDPROC_LICENSE_FILES = COPYING LCDPROC_MAKE = $(MAKE1) LCDPROC_CONF_OPTS = --enable-drivers=$(BR2_PACKAGE_LCDPROC_DRIVERS) \ --with-ft-prefix="$(STAGING_DIR)/usr" \ --with-ft-exec-prefix="$(STAGING_DIR)/usr" ifeq ($(BR2_PACKAGE_LCDPROC_MENUS),y) LCDPROC_CONF_OPTS += --enable-lcdproc-menus endif LCDPROC_DEPENDENCIES = freetype ncurses zlib $(eval $(autotools-package))
shibajee/buildroot
package/lcdproc/lcdproc.mk
mk
mit
694
config BR2_PACKAGE_LCMS2 bool "lcms2" help Little Color Management Software (CMS) intends to be an OPEN SOURCE small-footprint color management engine, with special focus on accuracy and performance. It uses the International Color Consortium standard (ICC), which is the modern standard when regarding to color management. http://www.littlecms.com/
shibajee/buildroot
package/lcms2/Config.in
in
mit
371
# From http://sourceforge.net/projects/lcms/files/lcms/2.7/ sha1 625f0d74bad4a0f6f917120fd992437d26f754d2 lcms2-2.7.tar.gz md5 06c1626f625424a811fb4b5eb070839d lcms2-2.7.tar.gz # Locally computed: sha256 4524234ae7de185e6b6da5d31d6875085b2198bc63b1211f7dde6e2d197d6a53 lcms2-2.7.tar.gz
shibajee/buildroot
package/lcms2/lcms2.hash
hash
mit
287
################################################################################ # # lcms2 # ################################################################################ LCMS2_VERSION = 2.7 LCMS2_SITE = http://downloads.sourceforge.net/lcms/lcms LCMS2_LICENSE = MIT LCMS2_LICENSE_FILES = COPYING LCMS2_INSTALL_STAGING = YES LCMS2_CONF_OPTS = \ ifeq ($(BR2_PACKAGE_JPEG),y) LCMS2_CONF_OPTS += --with-jpeg LCMS2_DEPENDENCIES += jpeg else LCMS2_CONF_OPTS += --without-jpeg endif ifeq ($(BR2_PACKAGE_TIFF),y) LCMS2_CONF_OPTS += --with-tiff LCMS2_DEPENDENCIES += tiff else LCMS2_CONF_OPTS += --without-tiff endif ifeq ($(BR2_PACKAGE_ZLIB),y) LCMS2_CONF_OPTS += --with-zlib LCMS2_DEPENDENCIES += zlib else LCMS2_CONF_OPTS += --without-zlib endif $(eval $(autotools-package))
shibajee/buildroot
package/lcms2/lcms2.mk
mk
mit
779
Fix cross-compilation issues - During target package compilation the host version of b_sortnl is needed. - Do not call a 'amiroot' program built for the target when cross-compiling. We're anyway not root, so simply remove the chown/chgrp dance. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Index: b/Makefile.in =================================================================== --- a/Makefile.in +++ b/Makefile.in @@ -1853,7 +1853,7 @@ configparam_data.c: $(srcdir)/config.table b_sortnl$(EXEEXT) genconfigparam_data.awk rm -f config.table.sorted - ./b_sortnl$(EXEEXT) <$(srcdir)/config.table >config.table.sorted + ./b_sortnl_host$(EXEEXT) <$(srcdir)/config.table >config.table.sorted $(AWK) -f $(srcdir)/genconfigparam_data.awk <config.table.sorted >$@ \ || { rm -f $@ ; false ; } @@ -1868,13 +1868,7 @@ install-data-hook: $(INSTALL) -d -m 02770 $(DESTDIR)$(SPOOLDIR) $(INSTALL) -d -m 02770 $(DESTDIR)$(SPOOLDIR)/leaf.node - -./amiroot && chown $(RUNAS_USER) $(DESTDIR)$(SPOOLDIR) - -./amiroot && chown $(RUNAS_USER) $(DESTDIR)$(SPOOLDIR)/leaf.node - -./amiroot && chgrp $(RUNAS_GROUP) $(DESTDIR)$(SPOOLDIR) - -./amiroot && chgrp $(RUNAS_GROUP) $(DESTDIR)$(SPOOLDIR)/leaf.node rm -f $(DESTDIR)$(sbindir)/leafnode-version # now in $(bindir) - ./amiroot && p=$(DESTDIR)$(bindir)/newsq && chown 0 $$p \ - && chgrp $(RUNAS_GROUP) $$p && chmod 2111 $$p ; true @echo @echo "### If upgrading from leafnode before 1.6," @echo "### run: make update"
shibajee/buildroot
package/leafnode2/0001-cross_makefile.patch
patch
mit
1,564
config BR2_PACKAGE_LEAFNODE2 bool "leafnode2" depends on BR2_USE_MMU # fork() select BR2_PACKAGE_PCRE help Leafnode-2 is a store-and-forward NNTP (or Usenet) proxy server designed for small sites with just a few active newsgroups. Leafnode-2 needs inetd, check chapter 14 of the documentation at http://www.dt.e-technik.uni-dortmund.de/~ma/leafnode/beta/leafnode-readme.txt For example, you can add this line to inetd.conf: nntp stream tcp nowait news /usr/sbin/leafnode http://www.dt.e-technik.tu-dortmund.de/~ma/leafnode/beta
shibajee/buildroot
package/leafnode2/Config.in
in
mit
571
# Locally calculated sha256 34eba2cbbb871b724c8d5dd402d1c358aeb21ba426beb5658e155ed0d7461075 leafnode-2.0.0.alpha20140727b.tar.bz2
shibajee/buildroot
package/leafnode2/leafnode2.hash
hash
mit
132
################################################################################ # # leafnode2 # ################################################################################ LEAFNODE2_VERSION = 2.0.0.alpha20140727b LEAFNODE2_SOURCE = leafnode-$(LEAFNODE2_VERSION).tar.bz2 LEAFNODE2_SITE = http://www.dt.e-technik.tu-dortmund.de/~ma/leafnode/beta LEAFNODE2_LICENSE = LGPLv2.1 LEAFNODE2_LICENSE_FILES = COPYING COPYING.LGPL LEAFNODE2_DEPENDENCIES = host-pcre pcre LEAFNODE2_CONF_ENV = \ PCRECONFIG="$(STAGING_DIR)/usr/bin/pcre-config" # --enable-runas-user use 'news' as default but the configure stop # if news doesn't exist on the build host. # Use 'root' while cross-compiling LEAFNODE2_CONF_OPTS = \ --sysconfdir=/etc/leafnode2 \ --enable-spooldir=/var/spool/news \ --enable-runas-user=root # Leafnode2 needs the host version of b_sortnl during # compilation. Instead of creating a seperate host package and # installing b_sortnl to $(HOST_DIR) this binary is compiled # on-the-fly, host-pcre is needed for this define LEAFNODE2_BUILD_SORTNL_TOOL cd $(@D); \ $(HOSTCC) $(HOST_CFLAGS) -o b_sortnl_host \ arc4random.c mergesort.c b_sortnl.c critmem_malloc.c \ critmem_realloc.c -DHAVE_CONFIG_H -I$(HOST_DIR)/usr/include \ -L $(HOST_DIR)/usr/lib -Wl,-rpath,$(HOST_DIR)/usr/lib -lpcre endef LEAFNODE2_PRE_BUILD_HOOKS += LEAFNODE2_BUILD_SORTNL_TOOL define LEAFNODE2_USERS news -1 news -1 * - - - Leafnode2 daemon endef $(eval $(autotools-package))
shibajee/buildroot
package/leafnode2/leafnode2.mk
mk
mit
1,470
config BR2_PACKAGE_LEAFPAD bool "leafpad" depends on BR2_PACKAGE_LIBGTK2 help GTK+ based simple text editor http://savannah.nongnu.org/download/leafpad
shibajee/buildroot
package/leafpad/Config.in
in
mit
162
# Locally calculated after checking pgp signature sha256 959d22ae07f22803bc66ff40d373a854532a6e4732680bf8a96a3fbcb9f80a2c leafpad-0.8.18.1.tar.gz
shibajee/buildroot
package/leafpad/leafpad.hash
hash
mit
146