summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChí-Thanh Christopher Nguyễn <chithanh@gentoo.org>2012-06-11 21:28:15 +0000
committerChí-Thanh Christopher Nguyễn <chithanh@gentoo.org>2012-06-11 21:28:15 +0000
commit138cc48d4437b9f712ce2159ffc9cfab2e32ea4f (patch)
treef75c6d481ea0b7c2da2a665332c5f0ddb298f792 /www-plugins/lightspark
parentbump to 0.1.10 (diff)
downloadhistorical-138cc48d4437b9f712ce2159ffc9cfab2e32ea4f.tar.gz
historical-138cc48d4437b9f712ce2159ffc9cfab2e32ea4f.tar.bz2
historical-138cc48d4437b9f712ce2159ffc9cfab2e32ea4f.zip
Version bump.
Package-Manager: portage-2.2.0_alpha109/cvs/Linux x86_64
Diffstat (limited to 'www-plugins/lightspark')
-rw-r--r--www-plugins/lightspark/ChangeLog15
-rw-r--r--www-plugins/lightspark/Manifest13
-rw-r--r--www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0000.patch28
-rw-r--r--www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0001.patch38
-rw-r--r--www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0002.patch57
-rw-r--r--www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0003.patch42
-rw-r--r--www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0004.patch60
-rw-r--r--www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0005.patch32
-rw-r--r--www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0006.patch25
-rw-r--r--www-plugins/lightspark/lightspark-0.6.0.1.ebuild109
-rw-r--r--www-plugins/lightspark/metadata.xml1
11 files changed, 417 insertions, 3 deletions
diff --git a/www-plugins/lightspark/ChangeLog b/www-plugins/lightspark/ChangeLog
index 5a6cbd2a9bf5..8cb60f189910 100644
--- a/www-plugins/lightspark/ChangeLog
+++ b/www-plugins/lightspark/ChangeLog
@@ -1,6 +1,19 @@
# ChangeLog for www-plugins/lightspark
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/www-plugins/lightspark/ChangeLog,v 1.43 2012/06/03 13:31:33 chithanh Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-plugins/lightspark/ChangeLog,v 1.44 2012/06/11 21:28:15 chithanh Exp $
+
+*lightspark-0.6.0.1 (11 Jun 2012)
+
+ 11 Jun 2012; Chí-Thanh Christopher Nguyễn <chithanh@gentoo.org>
+ +files/lightspark-0.6.0.1-gcc-4.5_0000.patch,
+ +files/lightspark-0.6.0.1-gcc-4.5_0001.patch,
+ +files/lightspark-0.6.0.1-gcc-4.5_0002.patch,
+ +files/lightspark-0.6.0.1-gcc-4.5_0003.patch,
+ +files/lightspark-0.6.0.1-gcc-4.5_0004.patch,
+ +files/lightspark-0.6.0.1-gcc-4.5_0005.patch,
+ +files/lightspark-0.6.0.1-gcc-4.5_0006.patch, +lightspark-0.6.0.1.ebuild,
+ metadata.xml:
+ Version bump.
03 Jun 2012; Chí-Thanh Christopher Nguyễn <chithanh@gentoo.org>
+files/lightspark-0.5.7-llvm-3.1_0000.patch,
diff --git a/www-plugins/lightspark/Manifest b/www-plugins/lightspark/Manifest
index 7821077b3ec5..d95f3affc07d 100644
--- a/www-plugins/lightspark/Manifest
+++ b/www-plugins/lightspark/Manifest
@@ -1,7 +1,16 @@
AUX lightspark-0.5.7-llvm-3.1_0000.patch 2547 RMD160 cf0d988cd9ff990b80e493bd73b6b458dcfdcf07 SHA1 fb1c70a04f29566c040a7fb3745918347ceecd98 SHA256 a6d85fdf33d94502131e1627f933649a60c5177ba84d69a687a4c349a9cc3ec1
AUX lightspark-0.5.7-llvm-3.1_0001.patch 825 RMD160 7aefc6a2402913cfdf797d38fe68aa6c4a247501 SHA1 48251eb1dccfbcc96f3cf818de907815ae445af5 SHA256 3c543fe44ed530cd83087af5b9bf4198f8d7c9b127efabf6057ea7782398ba0c
AUX lightspark-0.5.7-llvm-3.1_0002.patch 781 RMD160 86e59c7f12c3c74ba5240409b585d014d2f807bb SHA1 01da62b7b75c1584fcc984bbcca704f5c5f491cd SHA256 d13a4e16e760e20c546f62ef44d5466ab90edaefb1f8fb8eb936c0931917b868
+AUX lightspark-0.6.0.1-gcc-4.5_0000.patch 702 RMD160 f6c33218da844600046cb13ab33e22003ad9cead SHA1 78bc5939aebb5732289268b2f615b68dade4ed3b SHA256 641287d79e3fec0c73b6a0dafdd197b795b8b884af5712738378df291d8f80c9
+AUX lightspark-0.6.0.1-gcc-4.5_0001.patch 1055 RMD160 2e6c482923b4025b44f4675ace290ab0513af5aa SHA1 e2bb3e8aa277b0a578cc81d5cd83dae93fa61ff9 SHA256 936ffa129899ba14ea01ecb833f745c5a565779d5d740f7b418b284bfc2670e5
+AUX lightspark-0.6.0.1-gcc-4.5_0002.patch 1790 RMD160 68491eaadfc8656790d24f69f1c7c00d272baa03 SHA1 30eba9ede18b69e7b6602abec8525b200c2b0430 SHA256 0b90da4f01c69af767d43a39908a1c4d8fb36aea54328771a2f516692dc24b69
+AUX lightspark-0.6.0.1-gcc-4.5_0003.patch 1305 RMD160 af2810c3c7edf3b9bdf5e7c7873e6117846aead7 SHA1 04ad63663d9ce0f28a0eeb5f18f60233ee8007f6 SHA256 cbe192db459165e3fc9dc2e317290ed97a32c09006a8ecfbd484714a3aa6e9e8
+AUX lightspark-0.6.0.1-gcc-4.5_0004.patch 1290 RMD160 8be4a41a8b147333433c39dbb3b40f61e6499bd2 SHA1 70774f26413c13e2997d41ee00127853a10f6f89 SHA256 7fa43d388d476e8df395f794618ac5d04dec11b73446dc1ab7b366b23884bbb4
+AUX lightspark-0.6.0.1-gcc-4.5_0005.patch 857 RMD160 54521bda59c4219af93f5727fd8175926f189f50 SHA1 121bf498f728bf79d0d80f891f56dcf874e746a4 SHA256 f5fb126000fe8367ee258cdd58b0ebd5a411ef53ff7fcb09debca5fbae00cf15
+AUX lightspark-0.6.0.1-gcc-4.5_0006.patch 917 RMD160 ba471232e31927a4d7c9e07e4a69d82406c3405c SHA1 dde777da00b49e3092dbec11c444f2ee8df890e2 SHA256 c9bdf1e5d48307eade32bfda3f6474b572b2caa6f52974c1479a1cc8923bfd04
DIST lightspark-0.5.7.tar.gz 855252 RMD160 2df254c3ae20862aba06d92a894e14f2176c5089 SHA1 87296ca620939ee8a38bfea9ca1ab2a35e29d283 SHA256 2f8fe72029a8a7ed1f50b308b43668423ce933fe203459e2220ac68611184980
+DIST lightspark-0.6.0.1.tar.gz 862495 RMD160 f4edb3d551e31cb9420e71ad50f38e30041d7e5c SHA1 a9c2ae8298b32141325ebc394849ba88f7fce983 SHA256 b9d638a45bb274da046e6fd7f7300547ba81c2480ce626158af2fd62312c5b86
EBUILD lightspark-0.5.7.ebuild 2520 RMD160 ea360436487a92c446d3c2226519f4c86c7da5c9 SHA1 3bcc1b564c2f2b9d594569b61e8748a141163842 SHA256 9645e88b09476f9728883016fca0e2cdfe3f274db97e48548f175e5dadd6f302
-MISC ChangeLog 9444 RMD160 76bde6eadfc7fcb2ba0a2ff521024fdfeeaf9e52 SHA1 9dec5cde457b7515ede5131304a3a9e1301ea230 SHA256 2a1a2318482c74e5f4c0baa7657ec4532d1aaea9b3e59c18a339af725e089bca
-MISC metadata.xml 345 RMD160 d881ee7c91c1b5fb26438e4fb116dab12efda0d3 SHA1 efc86456282cc22cb741ead371a6744e5dd0f367 SHA256 0056b39f2ac72046cc102978cf054e18f76ae6158725e38ddaa3164ab43b091e
+EBUILD lightspark-0.6.0.1.ebuild 2928 RMD160 36f2d05a215c69e29c87df6a1c2b08513e1a593c SHA1 c26f1642abcc912a5e47d24afec993c638e038b4 SHA256 e7d0a89df483e9c10c5aa70582fcc354191a4163b5233b44f6ee3392ca1f7b47
+MISC ChangeLog 9945 RMD160 0c68035d52d674062e745b1d2cc958d943532fd8 SHA1 f1edc57ed0bec10d0e01d8452f47f36116a1548c SHA256 a192a2a540879cee67308601cefcbe8e4ea723fc48e1289741b3f7bcf6a8d1b1
+MISC metadata.xml 416 RMD160 479590d9fdea51643d39ffd947ea2881510d9623 SHA1 a288225dc7b37ba096aec234962f26fbaf06f37d SHA256 1a4739e3ed47fd391141b1df084195435ad9cc1ac50650eb3b45d1fccb2f87e9
diff --git a/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0000.patch b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0000.patch
new file mode 100644
index 000000000000..be2e1ae813b3
--- /dev/null
+++ b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0000.patch
@@ -0,0 +1,28 @@
+From ef5b6b87f200a3cdf1cd9fd936724677e70c568d Mon Sep 17 00:00:00 2001
+From: Alessandro Pignotti <a.pignotti@sssup.it>
+Date: Sun, 10 Jun 2012 18:57:48 +0200
+Subject: [PATCH] [Build] Avoid new for each syntax to keep GCC 4.5
+ compatibility
+
+---
+ src/swf.cpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/swf.cpp b/src/swf.cpp
+index b735081..8501407 100644
+--- a/src/swf.cpp
++++ b/src/swf.cpp
+@@ -83,8 +83,8 @@ ParseThread* lightspark::getParseThread()
+
+ RootMovieClip::~RootMovieClip()
+ {
+- for(DictionaryTag* it: dictionary)
+- delete it;
++ for(auto it=dictionary.begin();it!=dictionary.end();++it)
++ delete *it;
+ }
+
+ void RootMovieClip::parsingFailed()
+--
+1.7.10
+
diff --git a/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0001.patch b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0001.patch
new file mode 100644
index 000000000000..7d409b5bfe6f
--- /dev/null
+++ b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0001.patch
@@ -0,0 +1,38 @@
+From 83f57ba569eab78581b3a682edca70592b2b2577 Mon Sep 17 00:00:00 2001
+From: Alessandro Pignotti <a.pignotti@sssup.it>
+Date: Sun, 10 Jun 2012 19:32:22 +0200
+Subject: [PATCH] Restore NullRef instead of std::nullptr_t
+
+std::nullptr is ambiguos since it's acceptable also as Ref constructor
+
+This reverts commit 3d243ec18be069b27774b5cef10305b48156fc1c.
+---
+ src/smartrefs.h | 7 +++----
+ 1 file changed, 3 insertions(+), 4 deletions(-)
+
+diff --git a/src/smartrefs.h b/src/smartrefs.h
+index d7f51bd..5087b2f 100644
+--- a/src/smartrefs.h
++++ b/src/smartrefs.h
+@@ -119,15 +119,14 @@ class Ref
+ return Ref<T>(a);
+ }
+
+-#if defined(__GNUC__) && (__GNUC__ == 4 && __GNUC_MINOR__ < 6)
++//#if defined(__GNUC__) && (__GNUC__ == 4 && __GNUC_MINOR__ < 6)
+ /* Fallback for gcc < 4.6 not supporting nullptr */
+ class NullRef_t {};
+ extern NullRef_t NullRef;
+-#else
+-/* This is needed for MSVC and can be used on gcc >= 4.6 */
++/*#else
+ typedef std::nullptr_t NullRef_t;
+ #define NullRef (nullptr)
+-#endif
++#endif*/
+
+ template<class T>
+ class NullableRef
+--
+1.7.10
+
diff --git a/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0002.patch b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0002.patch
new file mode 100644
index 000000000000..dc7d165161f6
--- /dev/null
+++ b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0002.patch
@@ -0,0 +1,57 @@
+From ea52ebb26e6b3923c6ac9b7492e67cfcc9039d4b Mon Sep 17 00:00:00 2001
+From: Alessandro Pignotti <a.pignotti@sssup.it>
+Date: Sun, 10 Jun 2012 19:35:49 +0200
+Subject: [PATCH] Restore NullRef instead of std::nullptr_t
+
+std::nullptr is ambiguos since it's acceptable also as Ref constructor
+
+This reverts commit 95fc48d50e8ae28a43585d9aa4d275ec84e4a4cf.
+---
+ src/scripting/abc.cpp | 2 +-
+ src/smartrefs.h | 9 +--------
+ 2 files changed, 2 insertions(+), 9 deletions(-)
+
+diff --git a/src/scripting/abc.cpp b/src/scripting/abc.cpp
+index 0bad425..8110666 100644
+--- a/src/scripting/abc.cpp
++++ b/src/scripting/abc.cpp
+@@ -170,7 +170,7 @@ void ScriptLimitsTag::execute(RootMovieClip* root) const
+
+ void ABCVm::registerClasses()
+ {
+- Global* builtin=Class<Global>::getInstanceS((ABCContext*)0, 0);
++ Global* builtin=Class<Global>::getInstanceS(nullptr, 0);
+ //Register predefined types, ASObject are enough for not implemented classes
+ builtin->registerBuiltin("Object","",Class<ASObject>::getRef());
+ builtin->registerBuiltin("Class","",Class_object::getRef());
+diff --git a/src/smartrefs.h b/src/smartrefs.h
+index 5087b2f..09ce760 100644
+--- a/src/smartrefs.h
++++ b/src/smartrefs.h
+@@ -119,14 +119,7 @@ class Ref
+ return Ref<T>(a);
+ }
+
+-//#if defined(__GNUC__) && (__GNUC__ == 4 && __GNUC_MINOR__ < 6)
+-/* Fallback for gcc < 4.6 not supporting nullptr */
+-class NullRef_t {};
+-extern NullRef_t NullRef;
+-/*#else
+-typedef std::nullptr_t NullRef_t;
+ #define NullRef (nullptr)
+-#endif*/
+
+ template<class T>
+ class NullableRef
+@@ -136,7 +129,7 @@ class NullableRef
+ public:
+ NullableRef(): m(NULL) {}
+ explicit NullableRef(T* o):m(o){}
+- NullableRef(NullRef_t):m(NULL){}
++ NullableRef(std::nullptr_t):m(NULL){}
+ NullableRef(const NullableRef& r):m(r.m)
+ {
+ if(m)
+--
+1.7.10
+
diff --git a/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0003.patch b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0003.patch
new file mode 100644
index 000000000000..9b3087e91284
--- /dev/null
+++ b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0003.patch
@@ -0,0 +1,42 @@
+From bc81ca2f4330d2a287289317837b7ad8058cb591 Mon Sep 17 00:00:00 2001
+From: Alessandro Pignotti <a.pignotti@sssup.it>
+Date: Sun, 10 Jun 2012 19:54:54 +0200
+Subject: [PATCH] [BitmapContainer] Add ::reset
+
+---
+ src/scripting/flash/display/BitmapContainer.cpp | 9 +++++++++
+ src/scripting/flash/display/BitmapContainer.h | 1 +
+ 2 files changed, 10 insertions(+)
+
+diff --git a/src/scripting/flash/display/BitmapContainer.cpp b/src/scripting/flash/display/BitmapContainer.cpp
+index fa480a0..e057db2 100644
+--- a/src/scripting/flash/display/BitmapContainer.cpp
++++ b/src/scripting/flash/display/BitmapContainer.cpp
+@@ -80,3 +80,12 @@ bool BitmapContainer::fromPNG(std::istream &s)
+ return fromRGB(rgb, (int32_t)w, (int32_t)h, false);
+ }
+
++void BitmapContainer::reset()
++{
++ data.clear();
++ data.shrink_to_fit();
++ stride=0;
++ dataSize=0;
++ width=0;
++ height=0;
++}
+diff --git a/src/scripting/flash/display/BitmapContainer.h b/src/scripting/flash/display/BitmapContainer.h
+index fb0912d..69a363d 100644
+--- a/src/scripting/flash/display/BitmapContainer.h
++++ b/src/scripting/flash/display/BitmapContainer.h
+@@ -45,6 +45,7 @@ class BitmapContainer
+ bool fromPNG(std::istream& s);
+ int getWidth() const { return width; }
+ int getHeight() const { return height; }
++ void reset();
+ };
+
+ };
+--
+1.7.10
+
diff --git a/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0004.patch b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0004.patch
new file mode 100644
index 000000000000..65d21d3ad934
--- /dev/null
+++ b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0004.patch
@@ -0,0 +1,60 @@
+From eded7abeb7d70a5d8dd7454c64812c49721a96d6 Mon Sep 17 00:00:00 2001
+From: Alessandro Pignotti <a.pignotti@sssup.it>
+Date: Sun, 10 Jun 2012 19:55:17 +0200
+Subject: [PATCH] Reintroduce NullRef and add comparison operators against it
+
+---
+ src/smartrefs.h | 16 ++++++++++++++--
+ 1 file changed, 14 insertions(+), 2 deletions(-)
+
+diff --git a/src/smartrefs.h b/src/smartrefs.h
+index 09ce760..85b7e06 100644
+--- a/src/smartrefs.h
++++ b/src/smartrefs.h
+@@ -119,7 +119,11 @@ class Ref
+ return Ref<T>(a);
+ }
+
+-#define NullRef (nullptr)
++class NullRef_t
++{
++};
++
++extern NullRef_t NullRef;
+
+ template<class T>
+ class NullableRef
+@@ -129,7 +133,7 @@ class NullableRef
+ public:
+ NullableRef(): m(NULL) {}
+ explicit NullableRef(T* o):m(o){}
+- NullableRef(std::nullptr_t):m(NULL){}
++ NullableRef(NullRef_t):m(NULL){}
+ NullableRef(const NullableRef& r):m(r.m)
+ {
+ if(m)
+@@ -187,6 +191,10 @@ class NullableRef
+ {
+ return m==r;
+ }
++ bool operator==(NullRef_t) const
++ {
++ return m==NULL;
++ }
+ template<class D> bool operator!=(const NullableRef<D>& r) const
+ {
+ return m!=r.getPtr();
+@@ -199,6 +207,10 @@ class NullableRef
+ {
+ return m!=r;
+ }
++ bool operator!=(NullRef_t) const
++ {
++ return m!=NULL;
++ }
+ /*explicit*/ operator bool() const
+ {
+ return m != NULL;
+--
+1.7.10
+
diff --git a/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0005.patch b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0005.patch
new file mode 100644
index 000000000000..4dcbf51baa4d
--- /dev/null
+++ b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0005.patch
@@ -0,0 +1,32 @@
+From 631cb37ae66c0150a148a29df7a3c3e26dc03fb4 Mon Sep 17 00:00:00 2001
+From: Alessandro Pignotti <a.pignotti@sssup.it>
+Date: Sun, 10 Jun 2012 19:55:40 +0200
+Subject: [PATCH] Fix a couple of stale reference assignment
+
+---
+ src/swftypes.cpp | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/swftypes.cpp b/src/swftypes.cpp
+index 69de488..a2d05e9 100644
+--- a/src/swftypes.cpp
++++ b/src/swftypes.cpp
+@@ -761,13 +761,13 @@ inline RGBA medianColor(const RGBA& a, const RGBA& b, float factor)
+ {
+ //Thrown if the bitmapId does not exists in dictionary
+ LOG(LOG_ERROR,"Exception in FillStyle parsing: " << e.what());
+- v.bitmap=NullRef;
++ v.bitmap.reset();
+ }
+ }
+ else
+ {
+ //The bitmap might be invalid, the style should not be used
+- v.bitmap=NullRef;
++ v.bitmap.reset();
+ }
+ }
+ else
+--
+1.7.10
+
diff --git a/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0006.patch b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0006.patch
new file mode 100644
index 000000000000..47ee6fb7f5d8
--- /dev/null
+++ b/www-plugins/lightspark/files/lightspark-0.6.0.1-gcc-4.5_0006.patch
@@ -0,0 +1,25 @@
+From 2f54ea1ee730c8bb250d360949badb500d4e1687 Mon Sep 17 00:00:00 2001
+From: Alessandro Pignotti <a.pignotti@sssup.it>
+Date: Sun, 10 Jun 2012 20:20:01 +0200
+Subject: [PATCH] Do not use nullptr for compatibility with GCC 4.5
+
+---
+ src/scripting/abc.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/scripting/abc.cpp b/src/scripting/abc.cpp
+index 8110666..8c71a07 100644
+--- a/src/scripting/abc.cpp
++++ b/src/scripting/abc.cpp
+@@ -170,7 +170,7 @@ void ScriptLimitsTag::execute(RootMovieClip* root) const
+
+ void ABCVm::registerClasses()
+ {
+- Global* builtin=Class<Global>::getInstanceS(nullptr, 0);
++ Global* builtin=Class<Global>::getInstanceS((ABCContext*)NULL, 0);
+ //Register predefined types, ASObject are enough for not implemented classes
+ builtin->registerBuiltin("Object","",Class<ASObject>::getRef());
+ builtin->registerBuiltin("Class","",Class_object::getRef());
+--
+1.7.10
+
diff --git a/www-plugins/lightspark/lightspark-0.6.0.1.ebuild b/www-plugins/lightspark/lightspark-0.6.0.1.ebuild
new file mode 100644
index 000000000000..9c93dda057fc
--- /dev/null
+++ b/www-plugins/lightspark/lightspark-0.6.0.1.ebuild
@@ -0,0 +1,109 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/www-plugins/lightspark/lightspark-0.6.0.1.ebuild,v 1.1 2012/06/11 21:28:15 chithanh Exp $
+
+EAPI=4
+inherit cmake-utils nsplugins multilib
+
+DESCRIPTION="High performance flash player"
+HOMEPAGE="http://lightspark.sourceforge.net/"
+SRC_URI="http://launchpad.net/${PN}/trunk/${P}/+download/${P}.tar.gz"
+
+LICENSE="LGPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="curl ffmpeg gles nsplugin profile pulseaudio rtmp sdl"
+
+RDEPEND=">=dev-cpp/libxmlpp-2.33.1:2.6
+ >=dev-libs/boost-1.42
+ dev-libs/libpcre[cxx]
+ media-fonts/liberation-fonts
+ media-libs/libsdl
+ >=sys-devel/gcc-4.4
+ || (
+ >=sys-devel/llvm-3
+ =sys-devel/llvm-2.8*
+ )
+ x11-libs/cairo
+ x11-libs/gtk+:2
+ x11-libs/libX11
+ x11-libs/pango
+ curl? (
+ net-misc/curl
+ )
+ ffmpeg? (
+ virtual/ffmpeg
+ )
+ !gles? (
+ >=media-libs/glew-1.5.3
+ virtual/opengl
+ )
+ gles? (
+ media-libs/mesa[gles2]
+ )
+ pulseaudio? (
+ media-sound/pulseaudio
+ )
+ rtmp? (
+ media-video/rtmpdump
+ )"
+DEPEND="${RDEPEND}
+ amd64? ( dev-lang/nasm )
+ x86? ( dev-lang/nasm )
+ virtual/pkgconfig"
+
+S=${WORKDIR}/${P/_rc*/}
+
+PATCHES=(
+ "${FILESDIR}"/${P}-gcc-4.5_0000.patch
+ "${FILESDIR}"/${P}-gcc-4.5_0001.patch
+ "${FILESDIR}"/${P}-gcc-4.5_0002.patch
+ "${FILESDIR}"/${P}-gcc-4.5_0003.patch
+ "${FILESDIR}"/${P}-gcc-4.5_0004.patch
+ "${FILESDIR}"/${P}-gcc-4.5_0005.patch
+ "${FILESDIR}"/${P}-gcc-4.5_0006.patch
+)
+
+src_configure() {
+ local audiobackends
+ use pulseaudio && audiobackends+="pulse"
+ use sdl && audiobackends+="sdl"
+
+ local mycmakeargs=(
+ $(cmake-utils_use curl ENABLE_CURL)
+ $(cmake-utils_use gles ENABLE_GLES2)
+ $(cmake-utils_use ffmpeg ENABLE_LIBAVCODEC)
+ $(cmake-utils_use nsplugin COMPILE_PLUGIN)
+ $(cmake-utils_use profile ENABLE_MEMORY_USAGE_PROFILING)
+ $(cmake-utils_use profile ENABLE_PROFILING)
+ $(cmake-utils_use rtmp ENABLE_RTMP)
+ -DAUDIO_BACKEND="${audiobackends}"
+ -DPLUGIN_DIRECTORY="${EPREFIX}"/usr/$(get_libdir)/${PN}/plugins
+ )
+
+ cmake-utils_src_configure
+}
+
+src_install() {
+ cmake-utils_src_install
+
+ use nsplugin && inst_plugin /usr/$(get_libdir)/${PN}/plugins/liblightsparkplugin.so
+
+ # default to sdl audio if pulseaudio plugin is not built, bug #406197
+ if use sdl && ! use pulseaudio; then
+ sed -i 's/backend = pulseaudio/backend = sdl/' "${ED}/etc/xdg/${PN}.conf" || die
+ fi
+}
+
+pkg_postinst() {
+ if use nsplugin && ! has_version www-plugins/gnash; then
+ elog "Lightspark now supports gnash fallback for its browser plugin."
+ elog "Install www-plugins/gnash to take advantage of it."
+ fi
+ if use nsplugin && has_version www-plugins/gnash[nsplugin]; then
+ elog "Having two plugins installed for the same MIME type may confuse"
+ elog "Mozilla based browsers. It is recommended to disable the nsplugin"
+ elog "USE flag for either gnash or lightspark. For details, see"
+ elog "https://bugzilla.mozilla.org/show_bug.cgi?id=581848"
+ fi
+}
diff --git a/www-plugins/lightspark/metadata.xml b/www-plugins/lightspark/metadata.xml
index fe1d55fe14e2..28a2c322df9f 100644
--- a/www-plugins/lightspark/metadata.xml
+++ b/www-plugins/lightspark/metadata.xml
@@ -6,6 +6,7 @@
<name>Chí-Thanh Christopher Nguyễn</name>
</maintainer>
<use>
+ <flag name='gles'>Replace default OpenGL renderer with GLESv2</flag>
<flag name='rtmp'>Enable Real Time Messaging Protocol using librtmp</flag>
</use>
</pkgmetadata>