summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorSandy Carter2016-11-01 19:44:23 -0400
committerSandy Carter2016-11-01 19:44:23 -0400
commit3ddd5b8bee2177ca8d670d2173db3bd776f8252d (patch)
treeb00b711a42eab74dbe1c24b2b649d5c2a80c1eb8
parentad2945f5bdda0ab67c3257b1e4243395c40b3247 (diff)
downloadaur-3ddd5b8bee2177ca8d670d2173db3bd776f8252d.tar.gz
Update to 0.99
-rw-r--r--.SRCINFO16
-rw-r--r--0001-Fix-building-with-Boost-1.58.patch53
-rw-r--r--0002-Fix-ambiguity-between-boost-and-std-make_shared.patch84
-rw-r--r--0003-Replace-deprecated-FFmpeg-API-for-compatibility-with.patch95
-rw-r--r--0004-Hopefully-proper-fix-for-ffmpeg-on-MSVS.patch47
-rw-r--r--PKGBUILD25
6 files changed, 8 insertions, 312 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 6a726e650da4..b9b02cc55434 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = vcmi
pkgdesc = Open-source engine for Heroes of Might and Magic III
- pkgver = 0.98
- pkgrel = 5
+ pkgver = 0.99
+ pkgrel = 1
url = http://vcmi.eu
install = vcmi.install
arch = i686
@@ -22,16 +22,8 @@ pkgbase = vcmi
optdepends = innoextract: required by vcmibuilder
optdepends = unshield: required by vcmibuilder
optdepends = unzip: required by vcmibuilder
- source = https://github.com/vcmi/vcmi/archive/0.98.tar.gz
- source = 0001-Fix-building-with-Boost-1.58.patch
- source = 0002-Fix-ambiguity-between-boost-and-std-make_shared.patch
- source = 0003-Replace-deprecated-FFmpeg-API-for-compatibility-with.patch
- source = 0004-Hopefully-proper-fix-for-ffmpeg-on-MSVS.patch
- md5sums = 6a69e52a3380358220eba67332b097c6
- md5sums = 1dbb6a91a35d141a2d266ad235a790e1
- md5sums = c43e0e8900d23d24909482ec618c76ca
- md5sums = 61f892c0b3e8a3415b957a6d54276b89
- md5sums = 14e71b2f92af89a10f0477c988e777c7
+ source = https://github.com/vcmi/vcmi/archive/0.99.tar.gz
+ sha256sums = b7f2459d7e054c8bdcf419cbb80040e751d3dbb06dc1113ac28f7365930f902e
pkgname = vcmi
diff --git a/0001-Fix-building-with-Boost-1.58.patch b/0001-Fix-building-with-Boost-1.58.patch
deleted file mode 100644
index 966e016b6226..000000000000
--- a/0001-Fix-building-with-Boost-1.58.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From aa00fdbd0e99b2beec382c7677a64d962b748dcb Mon Sep 17 00:00:00 2001
-From: Rohit Nirmal <rohitnirmal9@gmail.com>
-Date: Wed, 6 May 2015 19:16:51 -0500
-Subject: [PATCH] Fix building with Boost 1.58.
-
----
- CCallback.cpp | 2 +-
- lib/CArtHandler.cpp | 2 +-
- lib/CGameInfoCallback.cpp | 2 +-
- 3 files changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/CCallback.cpp b/CCallback.cpp
-index 8009bc7..da280db 100644
---- a/CCallback.cpp
-+++ b/CCallback.cpp
-@@ -80,7 +80,7 @@ void CCallback::recruitCreatures(const CGDwelling *obj, const CArmedInstance * d
-
- bool CCallback::dismissCreature(const CArmedInstance *obj, SlotID stackPos)
- {
-- if(((player>=0) && obj->tempOwner != player) || (obj->stacksCount()<2 && obj->needsLastStack()))
-+ if((player && obj->tempOwner != player) || (obj->stacksCount()<2 && obj->needsLastStack()))
- return false;
-
- DisbandCreature pack(stackPos,obj->id);
-diff --git a/lib/CArtHandler.cpp b/lib/CArtHandler.cpp
-index 2d9dd01..0026a66 100644
---- a/lib/CArtHandler.cpp
-+++ b/lib/CArtHandler.cpp
-@@ -671,7 +671,7 @@ boost::optional<std::vector<CArtifact*>&> CArtHandler::listFromClass( CArtifact:
- case CArtifact::ART_RELIC:
- return relics;
- default: //special artifacts should not be erased
-- return nullptr;
-+ return boost::optional<std::vector<CArtifact*>&>();
- }
- }
-
-diff --git a/lib/CGameInfoCallback.cpp b/lib/CGameInfoCallback.cpp
-index 051bb9c..2a59b96 100644
---- a/lib/CGameInfoCallback.cpp
-+++ b/lib/CGameInfoCallback.cpp
-@@ -403,7 +403,7 @@ std::vector <const CGObjectInstance * > CGameInfoCallback::getVisitableObjs(int3
-
- for(const CGObjectInstance * obj : t->visitableObjects)
- {
-- if(player < nullptr || obj->ID != Obj::EVENT) //hide events from players
-+ if(player || obj->ID != Obj::EVENT) //hide events from players
- ret.push_back(obj);
- }
-
---
-2.4.2
-
diff --git a/0002-Fix-ambiguity-between-boost-and-std-make_shared.patch b/0002-Fix-ambiguity-between-boost-and-std-make_shared.patch
deleted file mode 100644
index c859cd887509..000000000000
--- a/0002-Fix-ambiguity-between-boost-and-std-make_shared.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From 814708ac7f122f7a7b07f817a164fc7423d0ce6d Mon Sep 17 00:00:00 2001
-From: Sandy Carter <bwrsandman@gmail.com>
-Date: Sat, 24 Sep 2016 09:39:55 -0400
-Subject: [PATCH] Fix ambiguity between boost and std make_shared
-
----
- client/Client.cpp | 12 ++++++------
- lib/Connection.cpp | 2 +-
- 2 files changed, 7 insertions(+), 7 deletions(-)
-
-diff --git a/client/Client.cpp b/client/Client.cpp
-index f01ff0e..22ab71b 100644
---- a/client/Client.cpp
-+++ b/client/Client.cpp
-@@ -451,7 +451,7 @@ void CClient::newGame( CConnection *con, StartInfo *si )
- }
- else
- {
-- installNewPlayerInterface(make_shared<CPlayerInterface>(color), color);
-+ installNewPlayerInterface(std::make_shared<CPlayerInterface>(color), color);
- humanPlayers++;
- }
- }
-@@ -467,7 +467,7 @@ void CClient::newGame( CConnection *con, StartInfo *si )
- if(!gNoGUI)
- {
- boost::unique_lock<boost::recursive_mutex> un(*LOCPLINT->pim);
-- auto p = make_shared<CPlayerInterface>(PlayerColor::NEUTRAL);
-+ auto p = std::make_shared<CPlayerInterface>(PlayerColor::NEUTRAL);
- p->observerInDuelMode = true;
- installNewPlayerInterface(p, boost::none);
- GH.curInt = p.get();
-@@ -550,7 +550,7 @@ void CClient::serialize(CISer & h, const int version)
- else
- {
- assert(isHuman);
-- nInt = make_shared<CPlayerInterface>(pid);
-+ nInt = std::make_shared<CPlayerInterface>(pid);
- }
-
- nInt->dllName = dllname;
-@@ -620,7 +620,7 @@ void CClient::serialize(CISer & h, const int version, const std::set<PlayerColor
- else
- {
- assert(isHuman);
-- nInt = make_shared<CPlayerInterface>(pid);
-+ nInt = std::make_shared<CPlayerInterface>(pid);
- }
-
- nInt->dllName = dllname;
-@@ -866,7 +866,7 @@ void CClient::installNewPlayerInterface(shared_ptr<CGameInterface> gameInterface
- playerint[colorUsed] = gameInterface;
-
- logGlobal->traceStream() << boost::format("\tInitializing the interface for player %s") % colorUsed;
-- auto cb = make_shared<CCallback>(gs, color, this);
-+ auto cb = std::make_shared<CCallback>(gs, color, this);
- callbacks[colorUsed] = cb;
- battleCallbacks[colorUsed] = cb;
- gameInterface->init(cb);
-@@ -887,7 +887,7 @@ void CClient::installNewBattleInterface(shared_ptr<CBattleGameInterface> battleI
- if(needCallback)
- {
- logGlobal->traceStream() << boost::format("\tInitializing the battle interface for player %s") % *color;
-- auto cbc = make_shared<CBattleCallback>(gs, color, this);
-+ auto cbc = std::make_shared<CBattleCallback>(gs, color, this);
- battleCallbacks[colorUsed] = cbc;
- battleInterface->init(cbc);
- }
-diff --git a/lib/Connection.cpp b/lib/Connection.cpp
-index 0f6ca2e..9be8f79 100644
---- a/lib/Connection.cpp
-+++ b/lib/Connection.cpp
-@@ -440,7 +440,7 @@ CTypeList::TypeInfoPtr CTypeList::registerType( const std::type_info *type )
- return typeDescr; //type found, return ptr to structure
-
- //type not found - add it to the list and return given ID
-- auto newType = make_shared<TypeDescriptor>();
-+ auto newType = std::make_shared<TypeDescriptor>();
- newType->typeID = typeInfos.size() + 1;
- newType->name = type->name();
- typeInfos[type] = newType;
---
-2.9.3
-
diff --git a/0003-Replace-deprecated-FFmpeg-API-for-compatibility-with.patch b/0003-Replace-deprecated-FFmpeg-API-for-compatibility-with.patch
deleted file mode 100644
index 36341f3246ac..000000000000
--- a/0003-Replace-deprecated-FFmpeg-API-for-compatibility-with.patch
+++ /dev/null
@@ -1,95 +0,0 @@
-From f80c1410b31d758adc2b3ec3ada3e27133eb41a4 Mon Sep 17 00:00:00 2001
-From: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
-Date: Thu, 5 Nov 2015 10:53:44 +0100
-Subject: [PATCH] Replace deprecated FFmpeg API for compatibility with ffmpeg
- 2.9
-
----
- client/CVideoHandler.cpp | 31 ++++++++++++++++++++++++++++++-
- 1 file changed, 30 insertions(+), 1 deletion(-)
-
-diff --git a/client/CVideoHandler.cpp b/client/CVideoHandler.cpp
-index c334725..1218fc0 100644
---- a/client/CVideoHandler.cpp
-+++ b/client/CVideoHandler.cpp
-@@ -151,7 +151,11 @@ bool CVideoPlayer::open(std::string fname, bool loop, bool useOverlay, bool scal
- }
-
- // Allocate video frame
-+#if LIBAVUTIL_VERSION_MAJOR > 52
-+ frame = av_alloc_frame();
-+#else
- frame = avcodec_alloc_frame();
-+#endif
-
- //setup scaling
-
-@@ -185,21 +189,36 @@ bool CVideoPlayer::open(std::string fname, bool loop, bool useOverlay, bool scal
- if (texture)
- { // Convert the image into YUV format that SDL uses
- sws = sws_getContext(codecContext->width, codecContext->height, codecContext->pix_fmt,
-- pos.w, pos.h, PIX_FMT_YUV420P,
-+ pos.w, pos.h,
-+#if LIBAVUTIL_VERSION_MAJOR > 51
-+ AV_PIX_FMT_YUV420P,
-+#else
-+ PIX_FMT_YUV420P,
-+#endif
- SWS_BICUBIC, nullptr, nullptr, nullptr);
- }
- else
- {
-
-+#if LIBAVUTIL_VERSION_MAJOR > 51
-+ AVPixelFormat screenFormat = AV_PIX_FMT_NONE;
-+#else
- PixelFormat screenFormat = PIX_FMT_NONE;
-+#endif
- if (screen->format->Bshift > screen->format->Rshift)
- {
- // this a BGR surface
- switch (screen->format->BytesPerPixel)
- {
-+#if LIBAVUTIL_VERSION_MAJOR > 51
-+ case 2: screenFormat = AV_PIX_FMT_BGR565; break;
-+ case 3: screenFormat = AV_PIX_FMT_BGR24; break;
-+ case 4: screenFormat = AV_PIX_FMT_BGR32; break;
-+#else
- case 2: screenFormat = PIX_FMT_BGR565; break;
- case 3: screenFormat = PIX_FMT_BGR24; break;
- case 4: screenFormat = PIX_FMT_BGR32; break;
-+#endif
- default: return false;
- }
- }
-@@ -208,9 +227,15 @@ bool CVideoPlayer::open(std::string fname, bool loop, bool useOverlay, bool scal
- // this a RGB surface
- switch (screen->format->BytesPerPixel)
- {
-+#if LIBAVUTIL_VERSION_MAJOR > 51
-+ case 2: screenFormat = AV_PIX_FMT_RGB565; break;
-+ case 3: screenFormat = AV_PIX_FMT_RGB24; break;
-+ case 4: screenFormat = AV_PIX_FMT_RGB32; break;
-+#else
- case 2: screenFormat = PIX_FMT_RGB565; break;
- case 3: screenFormat = PIX_FMT_RGB24; break;
- case 4: screenFormat = PIX_FMT_RGB32; break;
-+#endif
- default: return false;
- }
- }
-@@ -367,7 +392,11 @@ void CVideoPlayer::close()
-
- if (frame)
- {
-+#if LIBAVUTIL_VERSION_MAJOR > 52
-+ av_frame_free(frame);
-+#else
- av_free(frame);
-+#endif
- frame = nullptr;
- }
-
---
-2.9.3
-
diff --git a/0004-Hopefully-proper-fix-for-ffmpeg-on-MSVS.patch b/0004-Hopefully-proper-fix-for-ffmpeg-on-MSVS.patch
deleted file mode 100644
index 087c6bb1ccec..000000000000
--- a/0004-Hopefully-proper-fix-for-ffmpeg-on-MSVS.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From c53c53642b40c82e40fd87905f4d8edb67b617cc Mon Sep 17 00:00:00 2001
-From: AlexVinS <alexvins@users.noreply.github.com>
-Date: Wed, 11 Nov 2015 12:41:28 +0300
-Subject: [PATCH] Hopefully proper fix for ffmpeg on MSVS
-
----
- client/CVideoHandler.cpp | 11 ++++++-----
- 1 file changed, 6 insertions(+), 5 deletions(-)
-
-diff --git a/client/CVideoHandler.cpp b/client/CVideoHandler.cpp
-index 4ccaf0e..a7770e7 100644
---- a/client/CVideoHandler.cpp
-+++ b/client/CVideoHandler.cpp
-@@ -155,11 +155,12 @@ bool CVideoPlayer::open(std::string fname, bool loop, bool useOverlay, bool scal
- }
-
- // Allocate video frame
--#if LIBAVUTIL_VERSION_MAJOR > 52
-- frame = av_alloc_frame();
-+#if LIBAVUTIL_VERSION_MAJOR > 51
-+ frame = av_frame_alloc();
- #else
- frame = avcodec_alloc_frame();
- #endif
-+
-
- //setup scaling
-
-@@ -436,12 +437,12 @@ void CVideoPlayer::close()
-
- if (frame)
- {
--#if LIBAVUTIL_VERSION_MAJOR > 52
-- av_frame_free(frame);
-+#if LIBAVUTIL_VERSION_MAJOR > 51
-+ av_frame_free(&frame);//will be set to null
- #else
- av_free(frame);
-+ frame = nullptr;
- #endif
-- frame = nullptr;
- }
-
- if (codec)
---
-2.9.3
-
diff --git a/PKGBUILD b/PKGBUILD
index ee2f76e4bd4c..193766953890 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,8 +2,8 @@
# Contributor: Raziel23 <venom23 at runbox dot com>
pkgname=vcmi
-pkgver=0.98
-pkgrel=5
+pkgver=0.99
+pkgrel=1
pkgdesc="Open-source engine for Heroes of Might and Magic III"
arch=('i686' 'x86_64')
url="http://vcmi.eu"
@@ -15,25 +15,8 @@ optdepends=('innoextract: required by vcmibuilder'
'unshield: required by vcmibuilder'
'unzip: required by vcmibuilder')
install="${pkgname}.install"
-source=(https://github.com/vcmi/${pkgname}/archive/${pkgver}.tar.gz
- '0001-Fix-building-with-Boost-1.58.patch'
- '0002-Fix-ambiguity-between-boost-and-std-make_shared.patch'
- '0003-Replace-deprecated-FFmpeg-API-for-compatibility-with.patch'
- '0004-Hopefully-proper-fix-for-ffmpeg-on-MSVS.patch')
-md5sums=('6a69e52a3380358220eba67332b097c6'
- '1dbb6a91a35d141a2d266ad235a790e1'
- 'c43e0e8900d23d24909482ec618c76ca'
- '61f892c0b3e8a3415b957a6d54276b89'
- '14e71b2f92af89a10f0477c988e777c7')
-
-prepare() {
- cd "${srcdir}/${pkgname}-${pkgver}"
- # Backport fix building with Boost 1.58.
- patch -Np1 -i ${srcdir}/0001-Fix-building-with-Boost-1.58.patch
- patch -Np1 -i ${srcdir}/0002-Fix-ambiguity-between-boost-and-std-make_shared.patch
- patch -Np1 -i ${srcdir}/0003-Replace-deprecated-FFmpeg-API-for-compatibility-with.patch
- patch -Np1 -i ${srcdir}/0004-Hopefully-proper-fix-for-ffmpeg-on-MSVS.patch
-}
+source=(https://github.com/vcmi/${pkgname}/archive/${pkgver}.tar.gz)
+sha256sums=('b7f2459d7e054c8bdcf419cbb80040e751d3dbb06dc1113ac28f7365930f902e')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"