public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: x11-misc/fracplanet/, x11-misc/fracplanet/files/
@ 2017-02-28 19:11 David Seifert
  0 siblings, 0 replies; 2+ messages in thread
From: David Seifert @ 2017-02-28 19:11 UTC (permalink / raw
  To: gentoo-commits

commit:     63864fecd34ba9106b6b8269368430af66b75c2a
Author:     Harri Nieminen <moikkis <AT> gmail <DOT> com>
AuthorDate: Sun Feb 26 16:19:39 2017 +0000
Commit:     David Seifert <soap <AT> gentoo <DOT> org>
CommitDate: Tue Feb 28 19:10:47 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=63864fec

x11-misc/fracplanet: EAPI bump, fix build with gcc6 (Bug #602414)

Gentoo-Bug: https://bugs.gentoo.org/602414

Package-Manager: Portage-2.3.3, Repoman-2.3.1
Closes: https://github.com/gentoo/gentoo/pull/4085

 .../fracplanet/files/fracplanet-0.4.0-gcc6.patch   | 44 ++++++++++++++++++++++
 .../fracplanet/files/fracplanet-0.4.0-gold.patch   |  8 ++--
 ...net-0.4.0.ebuild => fracplanet-0.4.0-r1.ebuild} | 34 +++++++++++------
 3 files changed, 70 insertions(+), 16 deletions(-)

diff --git a/x11-misc/fracplanet/files/fracplanet-0.4.0-gcc6.patch b/x11-misc/fracplanet/files/fracplanet-0.4.0-gcc6.patch
new file mode 100644
index 0000000000..4d760d672f
--- /dev/null
+++ b/x11-misc/fracplanet/files/fracplanet-0.4.0-gcc6.patch
@@ -0,0 +1,44 @@
+Description: Fix compilation with gcc-6
+Author: Gert Wollny <gw.fossdev@gmail.com>
+Last-Updated: 2016-07-09
+Forwarded: No
+Bug-Debian: https://bugs.debian.org/811642
+
+--- fracplanet-0.4.0.orig/image.cpp
++++ fracplanet-0.4.0/image.cpp
+@@ -85,7 +85,7 @@ template <> bool Raster<uchar>::write_pg
+       out.write(reinterpret_cast<const char*>(&(*(row->begin()))),row->size());
+     }
+   out.close();
+-  return out;
++  return out.good();
+ }
+ 
+ template <> bool Raster<ushort>::write_pgmfile(const std::string& filename,Progress* target) const
+@@ -101,7 +101,7 @@ template <> bool Raster<ushort>::write_p
+       progress.step();
+       for (const ushort* it=row->begin();it!=row->end();++it)
+ 	{
+-	  const uchar p[2]={((*it)>>8),(*it)};
++	  const uchar p[2]={static_cast<uchar>((*it)>>8),static_cast<uchar>((*it) & 0x00FF)};
+ 	  if (m>=256)
+ 	    {
+ 	      // PGM spec is most significant byte first
+@@ -115,7 +115,7 @@ template <> bool Raster<ushort>::write_p
+ 	}
+     }
+   out.close();
+-  return out;
++  return out.good();
+ }
+ 
+ template <> bool Raster<ByteRGBA>::write_ppmfile(const std::string& filename,Progress* target) const
+@@ -132,7 +132,7 @@ template <> bool Raster<ByteRGBA>::write
+ 	out.write(reinterpret_cast<const char*>(&((*it).r)),3);
+     }
+   out.close();
+-  return out;
++  return out.good();
+ }
+ 
+ 

diff --git a/x11-misc/fracplanet/files/fracplanet-0.4.0-gold.patch b/x11-misc/fracplanet/files/fracplanet-0.4.0-gold.patch
index c980dfdd6b..4a52d1c44a 100644
--- a/x11-misc/fracplanet/files/fracplanet-0.4.0-gold.patch
+++ b/x11-misc/fracplanet/files/fracplanet-0.4.0-gold.patch
@@ -1,5 +1,5 @@
---- triangle_mesh_viewer.h
-+++ triangle_mesh_viewer.h
+--- a/triangle_mesh_viewer.h
++++ b/triangle_mesh_viewer.h
 @@ -24,6 +24,7 @@
  #ifndef _triangle_mesh_viewer_h_
  #define _triangle_mesh_viewer_h_
@@ -9,8 +9,8 @@
  #include "random.h"
  #include "triangle_mesh.h"
 
---- fracplanet.pro
-+++ fracplanet.pro
+--- a/fracplanet.pro
++++ b/fracplanet.pro
 @@ -8,7 +8,7 @@
  
  HEADERS += $$system(ls *.h)

diff --git a/x11-misc/fracplanet/fracplanet-0.4.0.ebuild b/x11-misc/fracplanet/fracplanet-0.4.0-r1.ebuild
similarity index 67%
rename from x11-misc/fracplanet/fracplanet-0.4.0.ebuild
rename to x11-misc/fracplanet/fracplanet-0.4.0-r1.ebuild
index 518fa738b3..254e38f2f6 100644
--- a/x11-misc/fracplanet/fracplanet-0.4.0.ebuild
+++ b/x11-misc/fracplanet/fracplanet-0.4.0-r1.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2013 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
-EAPI=4
-inherit qt4-r2
+EAPI=6
+inherit qmake-utils
 
 DESCRIPTION="Fractal planet and terrain generator"
 HOMEPAGE="https://sourceforge.net/projects/fracplanet/"
@@ -14,28 +14,38 @@ SLOT="0"
 KEYWORDS="~amd64 ~x86"
 IUSE=""
 
-RDEPEND="dev-libs/boost
-	virtual/glu
-	virtual/opengl
+RDEPEND="
+	dev-libs/boost:=
 	dev-qt/qtcore:4
 	dev-qt/qtgui:4
-	dev-qt/qtopengl:4"
+	dev-qt/qtopengl:4
+	virtual/glu
+	virtual/opengl
+"
 DEPEND="${RDEPEND}
 	dev-libs/libxslt"
 
 S=${WORKDIR}/${PN}
 
-PATCHES=( "${FILESDIR}/${P}-gold.patch" )
+PATCHES=(
+	"${FILESDIR}/${P}-gold.patch"
+	"${FILESDIR}/${P}-gcc6.patch"
+)
+
+HTML_DOCS=( fracplanet.{htm,css} )
+
+src_configure() {
+	eqmake4 fracplanet.pro
+}
 
 src_compile() {
 	xsltproc -stringparam version ${PV} -html htm_to_qml.xsl fracplanet.htm \
-		| sed 's/"/\\"/g' | sed 's/^/"/g' | sed 's/$/\\n"/g'> usage_text.h
-	qt4-r2_src_compile
+		| sed 's/"/\\"/g' | sed 's/^/"/g' | sed 's/$/\\n"/g'> usage_text.h || die
+	default
 }
 
 src_install() {
 	dobin ${PN}
 	doman man/man1/${PN}.1
-	dodoc BUGS NEWS README THANKS TODO
-	dohtml *.{css,htm}
+	einstalldocs
 }


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: x11-misc/fracplanet/, x11-misc/fracplanet/files/
@ 2023-08-21 15:49 Marek Szuba
  0 siblings, 0 replies; 2+ messages in thread
From: Marek Szuba @ 2023-08-21 15:49 UTC (permalink / raw
  To: gentoo-commits

commit:     e15137c43be58fab48f6aa455b7f3b84429dca74
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Mon Aug 21 15:35:38 2023 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Mon Aug 21 15:49:27 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e15137c4

x11-misc/fracplanet: fix building against musl

__STRING() is a glibc idiom. Fortunately, it is trivial to emulate.

While at it, update EAPI 7 -> 8.

Closes: https://bugs.gentoo.org/833106
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 x11-misc/fracplanet/files/fracplanet-0.5.1-musl.patch | 12 ++++++++++++
 x11-misc/fracplanet/fracplanet-0.5.1.ebuild           |  8 ++++++--
 2 files changed, 18 insertions(+), 2 deletions(-)

diff --git a/x11-misc/fracplanet/files/fracplanet-0.5.1-musl.patch b/x11-misc/fracplanet/files/fracplanet-0.5.1-musl.patch
new file mode 100644
index 000000000000..ddd64f4a386d
--- /dev/null
+++ b/x11-misc/fracplanet/files/fracplanet-0.5.1-musl.patch
@@ -0,0 +1,12 @@
+--- a/common.h
++++ b/common.h
+@@ -44,6 +44,9 @@
+ #include <boost/scoped_array.hpp>
+ #include <boost/scoped_ptr.hpp>
+ 
++#ifndef __STRING
++#define __STRING(x) #x
++#endif
+ #define stringify(S) __STRING(S)
+ 
+ typedef unsigned int uint;

diff --git a/x11-misc/fracplanet/fracplanet-0.5.1.ebuild b/x11-misc/fracplanet/fracplanet-0.5.1.ebuild
index 5f89bd2b1b43..6d08682f6cf4 100644
--- a/x11-misc/fracplanet/fracplanet-0.5.1.ebuild
+++ b/x11-misc/fracplanet/fracplanet-0.5.1.ebuild
@@ -1,7 +1,7 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2023 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=7
+EAPI=8
 
 inherit qmake-utils
 
@@ -25,6 +25,10 @@ RDEPEND="
 "
 DEPEND="${RDEPEND}"
 
+PATCHES=(
+	"${FILESDIR}"/${PN}-0.5.1-musl.patch
+)
+
 HTML_DOCS=( fracplanet.{htm,css} )
 
 src_configure() {


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-08-21 15:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-02-28 19:11 [gentoo-commits] repo/gentoo:master commit in: x11-misc/fracplanet/, x11-misc/fracplanet/files/ David Seifert
  -- strict thread matches above, loose matches on Subject: below --
2023-08-21 15:49 Marek Szuba

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox