[mupen64plus-video-glide64mk2] 22/60: Replace patented S3TC algorithm with compatible txc_dxtn
Sven Eckelmann
ecsv-guest at moszumanska.debian.org
Thu Nov 26 06:16:11 UTC 2015
This is an automated email from the git hooks/post-receive script.
ecsv-guest pushed a commit to branch armhf_test
in repository mupen64plus-video-glide64mk2.
commit d404963848b55ce7950547b9a80baff173be850e
Author: Sven Eckelmann <sven at narfation.org>
Date: Wed Jul 10 20:18:22 2013 +0200
Replace patented S3TC algorithm with compatible txc_dxtn
---
debian/changelog | 6 +
debian/control | 1 +
debian/patches/s3tc_removal.patch | 460 ++++++++++++++++++++++++++++++++++++++
debian/patches/series | 1 +
debian/rules | 2 +-
5 files changed, 469 insertions(+), 1 deletion(-)
diff --git a/debian/changelog b/debian/changelog
index 9561e21..ab7ca3b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -4,7 +4,13 @@ mupen64plus-video-glide64mk2 (2.0-2) UNRELEASED; urgency=low
- Add quantization_channel_order.patch, Enable ARGB and YUV input to fix
channel order in compressed textures
- Add mesa_fxt1.patch, Fix colors in compressed FXT1 textures
+ - Add s3tc_removal.patch, Allow to replace patented S3TC algorithm with
+ compatible txc_dxtn
- Add init_quit.patch, Call VidExt_Quit when video output stopped
+ * debian/control:
+ - Depend on libtxc-dxtn0 for the S2TC/S3TC implementation
+ * debian/rules:
+ - Force build against libtxc-dxtn as compatible S3TC replacement
-- Sven Eckelmann <sven at narfation.org> Mon, 08 Jul 2013 22:55:53 +0200
diff --git a/debian/control b/debian/control
index cd7d37b..d58be4b 100644
--- a/debian/control
+++ b/debian/control
@@ -27,6 +27,7 @@ Pre-Depends:
Depends:
${misc:Depends},
${shlibs:Depends},
+ libtxc-dxtn0,
mupen64plus-config-abi-2.2,
mupen64plus-gfx-abi-2.2,
mupen64plus-vidext-abi-3,
diff --git a/debian/patches/s3tc_removal.patch b/debian/patches/s3tc_removal.patch
new file mode 100644
index 0000000..7da62d6
--- /dev/null
+++ b/debian/patches/s3tc_removal.patch
@@ -0,0 +1,460 @@
+Description: Allow to replace patented S3TC algorithm with compatible txc_dxtn
+Author: Sven Eckelmann <sven at narfation.org>
+
+---
+diff --git a/projects/unix/Makefile b/projects/unix/Makefile
+index fe15b081981349b73427fe860e824a82fc912470..59840c13d50d15ae18a6f61b0ac3f13abaf1e38d 100644
+--- a/projects/unix/Makefile
++++ b/projects/unix/Makefile
+@@ -219,7 +219,6 @@ endif
+ CFLAGS += $(LIBPNG_CFLAGS)
+ LDLIBS += $(LIBPNG_LDLIBS)
+
+-
+ # search for OpenGL libraries
+ ifeq ($(OS), OSX)
+ GL_LDLIBS = -framework OpenGL
+@@ -370,12 +369,17 @@ SOURCE += \
+ $(SRCDIR)/GlideHQ/TxReSample.cpp \
+ $(SRCDIR)/GlideHQ/TxDbg.cpp \
+ $(SRCDIR)/GlideHQ/tc-1.1+/fxt1.c \
+- $(SRCDIR)/GlideHQ/tc-1.1+/dxtn.c \
+ $(SRCDIR)/GlideHQ/tc-1.1+/wrapper.c \
+ $(SRCDIR)/GlideHQ/tc-1.1+/texstore.c
+
+ CPPFLAGS += -DTEXTURE_FILTER # -DDUMP_CACHE
+ LDLIBS += -lboost_filesystem$(BOOST_SUFFIX) -lboost_system$(BOOST_SUFFIX)
++
++ ifeq ($(TXCDXTN), 1)
++ CPPFLAGS += -DTXCDXTN_EXTERNAL
++ else
++ SOURCE += $(SRCDIR)/GlideHQ/tc-1.1+/dxtn.c
++ endif
+ endif
+
+ ifeq ($(OS),MINGW)
+@@ -412,6 +416,7 @@ targets:
+ @echo " PIC=(1|0) == Force enable/disable of position independent code"
+ @echo " POSTFIX=name == String added to the name of the the build (default: '')"
+ @echo " HIRES=(1|0) == Enables/Disables support for hires textures and texture filters (default: 1)"
++ @echo " TXCDXTN=(1|0) == Enable/Disable external txc_dxtn library (default: 0)"
+ @echo " Install Options:"
+ @echo " PREFIX=path == install/uninstall prefix (default: /usr/local)"
+ @echo " SHAREDIR=path == path to install shared data files (default: PREFIX/share/mupen64plus)"
+diff --git a/src/Glide64/m64p.h b/src/Glide64/m64p.h
+index 3f47cf6a10c82ebaa9b0e4f2b30d2deecfb36735..dd6e89170dad08249e176fd66c176f30c767e35c 100755
+--- a/src/Glide64/m64p.h
++++ b/src/Glide64/m64p.h
+@@ -38,7 +38,13 @@
+ #define CONFIG_API_VERSION 0x020000
+ #define VIDEXT_API_VERSION 0x030000
+
++#ifdef __cplusplus
++extern "C" {
++#endif
+ void WriteLog(m64p_msg_level level, const char *msg, ...);
++#ifdef __cplusplus
++}
++#endif
+
+ //The Glide API originally used an integer to pick an enumerated resolution.
+ //To accomodate arbitrary resolutions, pack it into a 32-bit struct
+diff --git a/src/Glide64/osal_dynamiclib.h b/src/Glide64/osal_dynamiclib.h
+index c24377b178e0cebd91b181a408dde34b2d6339f7..7be0cab272df0715eb578fc14a3b994474a59bfc 100755
+--- a/src/Glide64/osal_dynamiclib.h
++++ b/src/Glide64/osal_dynamiclib.h
+@@ -1,5 +1,5 @@
+ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
+- * Mupen64plus-core - osal/dynamiclib.h *
++ * Mupen64plus-video-glide64mk2 - osal_dynamiclib.h *
+ * Mupen64Plus homepage: http://code.google.com/p/mupen64plus/ *
+ * Copyright (C) 2009 Richard Goedeken *
+ * *
+@@ -22,14 +22,18 @@
+ #if !defined(OSAL_DYNAMICLIB_H)
+ #define OSAL_DYNAMICLIB_H
+
++#include "m64p_types.h"
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+
+-#include "m64p_types.h"
++m64p_error osal_dynlib_open(m64p_dynlib_handle *pLibHandle, const char *pccLibraryPath);
+
+ void * osal_dynlib_getproc(m64p_dynlib_handle LibHandle, const char *pccProcedureName);
+
++m64p_error osal_dynlib_close(m64p_dynlib_handle LibHandle);
++
+ #ifdef __cplusplus
+ }
+ #endif
+diff --git a/src/Glide64/osal_dynamiclib_unix.c b/src/Glide64/osal_dynamiclib_unix.c
+index b3b7ba52dc690d42dbc06204afe1232c465e388f..25562c47923e1ade77c199bd57144cb52b40228b 100755
+--- a/src/Glide64/osal_dynamiclib_unix.c
++++ b/src/Glide64/osal_dynamiclib_unix.c
+@@ -1,5 +1,5 @@
+ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
+- * Mupen64plus-core - osal/dynamiclib_unix.c *
++ * Mupen64plus-video-glide64mk2 - osal_dynamiclib_unix.c *
+ * Mupen64Plus homepage: http://code.google.com/p/mupen64plus/ *
+ * Copyright (C) 2009 Richard Goedeken *
+ * *
+@@ -20,12 +20,33 @@
+ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
+
+ #include <stdlib.h>
++#include <string.h>
+ #include <stdio.h>
+ #include <dlfcn.h>
+
+ #include "m64p_types.h"
++#include "m64p.h"
+ #include "osal_dynamiclib.h"
+
++m64p_error osal_dynlib_open(m64p_dynlib_handle *pLibHandle, const char *pccLibraryPath)
++{
++ if (pLibHandle == NULL || pccLibraryPath == NULL)
++ return M64ERR_INPUT_ASSERT;
++
++ *pLibHandle = dlopen(pccLibraryPath, RTLD_NOW);
++
++ if (*pLibHandle == NULL)
++ {
++ /* only print an error message if there is a directory separator (/) in the pathname */
++ /* this prevents us from throwing an error for the use case where Mupen64Plus is not installed */
++ if (strchr(pccLibraryPath, '/') != NULL)
++ WriteLog(M64MSG_ERROR, "dlopen('%s') failed: %s", pccLibraryPath, dlerror());
++ return M64ERR_INPUT_NOT_FOUND;
++ }
++
++ return M64ERR_SUCCESS;
++}
++
+ void * osal_dynlib_getproc(m64p_dynlib_handle LibHandle, const char *pccProcedureName)
+ {
+ if (pccProcedureName == NULL)
+@@ -34,4 +55,17 @@ void * osal_dynlib_getproc(m64p_dynlib_handle LibHandle, const char *pccProcedur
+ return dlsym(LibHandle, pccProcedureName);
+ }
+
++m64p_error osal_dynlib_close(m64p_dynlib_handle LibHandle)
++{
++ int rval = dlclose(LibHandle);
++
++ if (rval != 0)
++ {
++ WriteLog(M64MSG_ERROR, "dlclose() failed: %s", dlerror());
++ return M64ERR_INTERNAL;
++ }
++
++ return M64ERR_SUCCESS;
++}
++
+
+diff --git a/src/Glide64/osal_dynamiclib_win32.c b/src/Glide64/osal_dynamiclib_win32.c
+index 685d717c9936055cdf5b20e3af6368f5bd1fb48c..a75c238c48141c9b69a9e8f77f2a14cc028ff78b 100755
+--- a/src/Glide64/osal_dynamiclib_win32.c
++++ b/src/Glide64/osal_dynamiclib_win32.c
+@@ -1,5 +1,5 @@
+ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
+- * Mupen64plus-ui-console - osal_dynamiclib_win32.c *
++ * Mupen64plus-video-glide64mk2 - osal_dynamiclib_win32.c *
+ * Mupen64Plus homepage: http://code.google.com/p/mupen64plus/ *
+ * Copyright (C) 2009 Richard Goedeken *
+ * *
+@@ -24,6 +24,7 @@
+ #include <stdio.h>
+
+ #include "m64p_types.h"
++#include "m64p.h"
+ #include "osal_dynamiclib.h"
+
+ m64p_error osal_dynlib_open(m64p_dynlib_handle *pLibHandle, const char *pccLibraryPath)
+@@ -39,7 +40,7 @@ m64p_error osal_dynlib_open(m64p_dynlib_handle *pLibHandle, const char *pccLibra
+ DWORD dwErr = GetLastError();
+ FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM, NULL, dwErr,
+ MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPTSTR) &pchErrMsg, 0, NULL);
+- fprintf(stderr, "LoadLibrary('%s') error: %s\n", pccLibraryPath, pchErrMsg);
++ WriteLog(M64MSG_ERROR, "LoadLibrary('%s') error: %s", pccLibraryPath, pchErrMsg);
+ LocalFree(pchErrMsg);
+ return M64ERR_INPUT_NOT_FOUND;
+ }
+@@ -65,7 +66,7 @@ m64p_error osal_dynlib_close(m64p_dynlib_handle LibHandle)
+ DWORD dwErr = GetLastError();
+ FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM, NULL, dwErr,
+ MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPTSTR) &pchErrMsg, 0, NULL);
+- fprintf(stderr, "FreeLibrary() error: %s\n", pchErrMsg);
++ WriteLog(M64MSG_ERROR, "FreeLibrary() error: %s", pchErrMsg);
+ LocalFree(pchErrMsg);
+ return M64ERR_INTERNAL;
+ }
+diff --git a/src/GlideHQ/TxQuantize.cpp b/src/GlideHQ/TxQuantize.cpp
+index b21db71ac95a27e7c18a2329c312f5dbeeb3bb12..02483cb581992841c2d913adcc981a034e9a68f2 100644
+--- a/src/GlideHQ/TxQuantize.cpp
++++ b/src/GlideHQ/TxQuantize.cpp
+@@ -41,7 +41,7 @@ TxQuantize::TxQuantize()
+
+ /* get dxtn extensions */
+ _tx_compress_fxt1 = TxLoadLib::getInstance()->getfxtCompressTexFuncExt();
+- _tx_compress_dxtn = TxLoadLib::getInstance()->getdxtCompressTexFuncExt();
++ _tx_compress_dxtn_rgba = TxLoadLib::getInstance()->getdxtCompressTexFuncExt();
+ }
+
+
+@@ -1990,7 +1990,7 @@ TxQuantize::DXTn(uint8 *src, uint8 *dest,
+
+ boolean bRet = 0;
+
+- if (_tx_compress_dxtn &&
++ if (_tx_compress_dxtn_rgba &&
+ srcwidth >= 4 && srcheight >= 4) {
+ /* compress to dxtn
+ * width and height must be larger than 4
+@@ -2038,7 +2038,7 @@ TxQuantize::DXTn(uint8 *src, uint8 *dest,
+ unsigned int srcStride = (srcwidth * blkheight) << 2;
+ unsigned int destStride = dstRowStride * blkrow;
+ for (i = 0; i < numcore - 1; i++) {
+- thrd[i] = new std::thread(std::bind(_tx_compress_dxtn,
++ thrd[i] = new std::thread(std::bind(_tx_compress_dxtn_rgba,
+ 4,
+ srcwidth,
+ blkheight,
+@@ -2049,7 +2049,7 @@ TxQuantize::DXTn(uint8 *src, uint8 *dest,
+ src += srcStride;
+ dest += destStride;
+ }
+- thrd[i] = new std::thread(std::bind(_tx_compress_dxtn,
++ thrd[i] = new std::thread(std::bind(_tx_compress_dxtn_rgba,
+ 4,
+ srcwidth,
+ srcheight - blkheight * i,
+@@ -2062,7 +2062,7 @@ TxQuantize::DXTn(uint8 *src, uint8 *dest,
+ delete thrd[i];
+ }
+ } else {
+- (*_tx_compress_dxtn)(4, /* comps: ARGB8888=4, RGB888=3 */
++ (*_tx_compress_dxtn_rgba)(4, /* comps: ARGB8888=4, RGB888=3 */
+ srcwidth, /* width */
+ srcheight, /* height */
+ src, /* source */
+@@ -2072,7 +2072,7 @@ TxQuantize::DXTn(uint8 *src, uint8 *dest,
+ * others = 16 bytes per 4x4 texel */
+ }
+ #else
+- (*_tx_compress_dxtn)(4, /* comps: ARGB8888=4, RGB888=3 */
++ (*_tx_compress_dxtn_rgba)(4, /* comps: ARGB8888=4, RGB888=3 */
+ srcwidth, /* width */
+ srcheight, /* height */
+ src, /* source */
+diff --git a/src/GlideHQ/TxQuantize.h b/src/GlideHQ/TxQuantize.h
+index d3c6ae6dc6da7c266c4baad5e6a490a4c8ed2a68..e14990f4150f22c86dd43cf5c8a520829ad082a7 100644
+--- a/src/GlideHQ/TxQuantize.h
++++ b/src/GlideHQ/TxQuantize.h
+@@ -38,7 +38,7 @@ private:
+ int _numcore;
+
+ fxtCompressTexFuncExt _tx_compress_fxt1;
+- dxtCompressTexFuncExt _tx_compress_dxtn;
++ dxtCompressTexFuncExt _tx_compress_dxtn_rgba;
+
+ /* fast optimized... well, sort of. */
+ void ARGB1555_ARGB8888(uint32* src, uint32* dst, int width, int height);
+diff --git a/src/GlideHQ/TxUtil.cpp b/src/GlideHQ/TxUtil.cpp
+index 9ad7e448b01b58422bf35a40d64e3b0891f80199..411a25efb15951be9932b98937a2d63710f86e66 100644
+--- a/src/GlideHQ/TxUtil.cpp
++++ b/src/GlideHQ/TxUtil.cpp
+@@ -42,14 +42,14 @@ TxLoadLib::TxLoadLib()
+ _dxtnlib = LoadLibrary("dxtn");
+
+ if (_dxtnlib) {
+- if (!_tx_compress_dxtn)
+- _tx_compress_dxtn = (dxtCompressTexFuncExt)DLSYM(_dxtnlib, "tx_compress_dxtn");
++ if (!_tx_compress_dxtn_rgba)
++ _tx_compress_dxtn_rgba = (dxtCompressTexFuncExt)DLSYM(_dxtnlib, "tx_compress_dxtn_rgba");
+
+ if (!_tx_compress_fxt1)
+ _tx_compress_fxt1 = (fxtCompressTexFuncExt)DLSYM(_dxtnlib, "fxt1_encode");
+ }
+ #else
+- _tx_compress_dxtn = tx_compress_dxtn;
++ _tx_compress_dxtn_rgba = tx_compress_dxtn_rgba;
+ _tx_compress_fxt1 = fxt1_encode;
+
+ #endif
+@@ -74,7 +74,7 @@ TxLoadLib::getfxtCompressTexFuncExt()
+ dxtCompressTexFuncExt
+ TxLoadLib::getdxtCompressTexFuncExt()
+ {
+- return _tx_compress_dxtn;
++ return _tx_compress_dxtn_rgba;
+ }
+
+
+diff --git a/src/GlideHQ/TxUtil.h b/src/GlideHQ/TxUtil.h
+index b89f660dfb86a34b16d3ef44221af9d95b9fa4df..7f9c5f4fdd7c08f8d5a8b472b7b5594e4ec8d655 100644
+--- a/src/GlideHQ/TxUtil.h
++++ b/src/GlideHQ/TxUtil.h
+@@ -34,7 +34,7 @@
+ #ifdef __cplusplus
+ extern "C"{
+ #endif
+-void tx_compress_dxtn(int srccomps, int width, int height,
++void tx_compress_dxtn_rgba(int srccomps, int width, int height,
+ const void *source, int destformat, void *dest,
+ int destRowStride);
+
+@@ -62,7 +62,7 @@ private:
+ HMODULE _dxtnlib;
+ #endif
+ fxtCompressTexFuncExt _tx_compress_fxt1;
+- dxtCompressTexFuncExt _tx_compress_dxtn;
++ dxtCompressTexFuncExt _tx_compress_dxtn_rgba;
+ TxLoadLib();
+ public:
+ static TxLoadLib* getInstance() {
+diff --git a/src/GlideHQ/tc-1.1+/texstore.c b/src/GlideHQ/tc-1.1+/texstore.c
+index 5dead259147eaeffce28076e92fb2a981ea451ec..69a6b39bc3a951421799a0b7115f325c7ed55723 100644
+--- a/src/GlideHQ/tc-1.1+/texstore.c
++++ b/src/GlideHQ/tc-1.1+/texstore.c
+@@ -33,7 +33,6 @@
+ #include "types.h"
+ #include "internal.h"
+
+-
+ void
+ _mesa_upscale_teximage2d (unsigned int inWidth, unsigned int inHeight,
+ unsigned int outWidth, unsigned int outHeight,
+diff --git a/src/GlideHQ/tc-1.1+/wrapper.c b/src/GlideHQ/tc-1.1+/wrapper.c
+index 0a171ee4fabcc4a26aa64b35f659b2cdb4898011..c51611c35b9b3fd00410a5f801376819d586bf0f 100644
+--- a/src/GlideHQ/tc-1.1+/wrapper.c
++++ b/src/GlideHQ/tc-1.1+/wrapper.c
+@@ -21,18 +21,59 @@
+
+
+ #include <assert.h>
++#include <stdlib.h>
+
+ #include "types.h"
+ #include "internal.h"
+-#include "dxtn.h"
++#include "../../Glide64/m64p.h"
+
++typedef void (*dxtCompressTexFuncExt)(int srccomps, int width,
++ int height, const byte *srcPixData,
++ int destformat, byte *dest,
++ int dstRowStride);
++static dxtCompressTexFuncExt _tx_compress_dxtn = NULL;
++
++#ifdef TXCDXTN_EXTERNAL
++
++#include "../../Glide64/osal_dynamiclib.h"
++
++#if defined(_WIN32) || defined(WIN32)
++#define DXTN_LIBNAME "dxtn.dll"
++#elif defined(__DJGPP__)
++#define DXTN_LIBNAME "dxtn.dxe"
++#else
++#define DXTN_LIBNAME "libtxc_dxtn.so"
++#endif
++
++static m64p_dynlib_handle dxtn_lib_handle;
++
++static void tx_compress_dxtn_init()
++{
++ m64p_error rval;
++
++ rval = osal_dynlib_open(&dxtn_lib_handle, DXTN_LIBNAME);
++ if (rval != M64ERR_SUCCESS) {
++ WriteLog(M64MSG_WARNING, "Failed to open %s", DXTN_LIBNAME);
++ return;
++ }
++
++ _tx_compress_dxtn = osal_dynlib_getproc(dxtn_lib_handle, "tx_compress_dxtn");
++ if (!_tx_compress_dxtn) {
++ WriteLog(M64MSG_WARNING, "Shared library '%s' invalid; no PluginGetVersion() function found.", DXTN_LIBNAME, "tx_compress_dxtn");
++ osal_dynlib_close(dxtn_lib_handle);
++ return;
++ }
++}
++
++#else
++
++#include "dxtn.h"
+
+ #define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0
+ #define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1
+ #define GL_COMPRESSED_RGBA_S3TC_DXT3_EXT 0x83F2
+ #define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT 0x83F3
+
+-
+ TAPI void TAPIENTRY
+ fetch_2d_texel_rgb_dxt1 (int texImage_RowStride,
+ const byte *texImage_Data,
+@@ -73,7 +114,7 @@ fetch_2d_texel_rgba_dxt5 (int texImage_RowStride,
+ }
+
+
+-TAPI void TAPIENTRY
++static
+ tx_compress_dxtn (int srccomps, int width, int height,
+ const byte *source, int destformat, byte *dest,
+ int destRowStride)
+@@ -105,3 +146,38 @@ tx_compress_dxtn (int srccomps, int width, int height,
+ assert(0);
+ }
+ }
++
++static void tx_compress_dxtn_init()
++{
++ _tx_compress_dxtn = tx_compress_dxtn;
++}
++
++#endif
++
++
++TAPI void TAPIENTRY
++tx_compress_dxtn_rgba(int srccomps, int width, int height,
++ const byte *source, int destformat, byte *dest,
++ int destRowStride)
++{
++ int srcRowStride = width * srccomps;
++ void *newSource = NULL;
++
++ tx_compress_dxtn_init();
++ if (!_tx_compress_dxtn) {
++ WriteLog(M64MSG_ERROR, "Failed to initialize S3TC compressor");
++ return;
++ }
++
++ assert(srccomps == 3 || srccomps == 4);
++
++ if (srccomps == 3)
++ newSource = reorder_source_3_alloc(source, width, height, srcRowStride);
++ if (srccomps == 4)
++ newSource = reorder_source_4_alloc(source, width, height, srcRowStride);
++
++ _tx_compress_dxtn(srccomps, width, height, newSource, destformat, dest,
++ destRowStride);
++
++ free(newSource);
++}
+diff --git a/src/Glitch64/main.h b/src/Glitch64/main.h
+index 5b203ed22058e9c95b816b95c30778909cc39373..361c597f746d7603e529b36734727aaf7dd6f22c 100644
+--- a/src/Glitch64/main.h
++++ b/src/Glitch64/main.h
+@@ -24,7 +24,13 @@
+ #include <m64p_types.h>
+
+ #define LOG(...) WriteLog(M64MSG_VERBOSE, __VA_ARGS__)
++#ifdef __cplusplus
++extern "C" {
++#endif
+ void WriteLog(m64p_msg_level level, const char *msg, ...);
++#ifdef __cplusplus
++}
++#endif
+
+
+ #ifndef _WIN32
diff --git a/debian/patches/series b/debian/patches/series
index 75097f1..6597398 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
quantization_channel_order.patch
mesa_fxt1.patch
init_quit.patch
+s3tc_removal.patch
diff --git a/debian/rules b/debian/rules
index 36f0776..e63398d 100755
--- a/debian/rules
+++ b/debian/rules
@@ -8,7 +8,7 @@ export DEB_LDFLAGS_MAINT_APPEND=-Wl,--as-needed
DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
DEB_HOST_GNU_CPU ?= $(shell dpkg-architecture -qDEB_HOST_GNU_CPU)
DEB_HOST_ARCH_OS ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_OS)
-MAKEOPTIONS = V=1 UNAME='$(DEB_HOST_ARCH_OS)' HOST_CPU='$(DEB_HOST_GNU_CPU)' APIDIR=/usr/include/mupen64plus/ DEBUG=1 PREFIX=/usr/ LIBDIR="/usr/lib/$(DEB_HOST_MULTIARCH)" PIC=1 OPTFLAGS="-DNDEBUG" SHAREDIR="/usr/share/games/mupen64plus/" SDL_CONFIG=sdl2-config
+MAKEOPTIONS = V=1 UNAME='$(DEB_HOST_ARCH_OS)' HOST_CPU='$(DEB_HOST_GNU_CPU)' APIDIR=/usr/include/mupen64plus/ DEBUG=1 PREFIX=/usr/ LIBDIR="/usr/lib/$(DEB_HOST_MULTIARCH)" PIC=1 OPTFLAGS="-DNDEBUG" SHAREDIR="/usr/share/games/mupen64plus/" SDL_CONFIG=sdl2-config TXCDXTN=1
DBG_PACKAGE=$(shell dpkg-parsechangelog|grep '^Source: '|sed 's/^Source:\s*//')-dbg
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/mupen64plus-video-glide64mk2.git
More information about the Pkg-games-commits
mailing list