Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 14 Jan 2015 08:51:31 +0000 (UTC)
From:      Alexey Dokuchaev <danfe@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r377001 - in head/astro: stellarium stellarium-qt4
Message-ID:  <201501140851.t0E8pVqP060902@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: danfe
Date: Wed Jan 14 08:51:31 2015
New Revision: 377001
URL: https://svnweb.freebsd.org/changeset/ports/377001
QAT: https://qat.redports.org/buildarchive/r377001/

Log:
  Improve the way we use optional high-resolution textures:
  - Forget about Milky Way texture for now as it causes rendering artifacts;
  - While most of those textures are indeed better than the ones provided by
    default (e.g., Jupiter and Ganymede), some of those are actually worse
    (e.g. Venus).  Use simple file size-based logic to decide if a texture
    is worth a replacement.

Modified:
  head/astro/stellarium-qt4/Makefile
  head/astro/stellarium-qt4/distinfo
  head/astro/stellarium/Makefile
  head/astro/stellarium/distinfo

Modified: head/astro/stellarium-qt4/Makefile
==============================================================================
--- head/astro/stellarium-qt4/Makefile	Wed Jan 14 08:39:42 2015	(r377000)
+++ head/astro/stellarium-qt4/Makefile	Wed Jan 14 08:51:31 2015	(r377001)
@@ -45,7 +45,7 @@ PLIST_SUB+=	MORE_STARS="@comment "
 
 .if ${PORT_OPTIONS:MHR_TEXTURES}
 MASTER_SITES+=	SF/${PORTNAME}/textures:gfx
-DISTFILES+=	textures-1K.zip:gfx milkyway.zip:gfx	# yes, in this order
+DISTFILES+=	textures-1K.zip:gfx
 PLIST_SUB+=	TEXTURES=""
 .else
 PLIST_SUB+=	TEXTURES="@comment "
@@ -79,7 +79,18 @@ post-install:
 		${STAGEDIR}${DATADIR}/stars/default
 .endif
 .if ${PORT_OPTIONS:MHR_TEXTURES}
-	${INSTALL_DATA} ${WRKDIR}/*.png ${STAGEDIR}${DATADIR}/textures
+	(cd ${WRKDIR} && for f in *.png; do \
+		new=`${STAT} -f '%z' $$f` ; \
+		existing=`${STAT} -qf '%z' \
+			${STAGEDIR}${DATADIR}/textures/$$f || \
+			${ECHO_CMD} 0` ; \
+		${TEST} $$new -gt $$existing && \
+			${ECHO_CMD} "-- Replacing texture: $$f\
+			(has larger file size or missing)" ; \
+		${INSTALL_DATA} $$f ${STAGEDIR}${DATADIR}/textures ; \
+	done)
+	@${REINPLACE_CMD} -e '1410s|nomap|vesta|' \
+		${STAGEDIR}${DATADIR}/data/ssystem.ini
 .endif
 	@${MKDIR} ${STAGEDIR}${DOCSDIR}
 	${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${STAGEDIR}${DOCSDIR}

Modified: head/astro/stellarium-qt4/distinfo
==============================================================================
--- head/astro/stellarium-qt4/distinfo	Wed Jan 14 08:39:42 2015	(r377000)
+++ head/astro/stellarium-qt4/distinfo	Wed Jan 14 08:51:31 2015	(r377001)
@@ -12,5 +12,3 @@ SHA256 (stars_8_2v0_1.cat) = f1c0b3f2573
 SIZE (stars_8_2v0_1.cat) = 559068934
 SHA256 (textures-1K.zip) = 3622b73e9cfb65ba537072b0ed3b5ef92951e70878ace7557931d841c5bb3bec
 SIZE (textures-1K.zip) = 20216182
-SHA256 (milkyway.zip) = cffc11d22a1e0596e8d01800f54627a67a3ebcc745e5d138819e40d247aaa0d1
-SIZE (milkyway.zip) = 6389431

Modified: head/astro/stellarium/Makefile
==============================================================================
--- head/astro/stellarium/Makefile	Wed Jan 14 08:39:42 2015	(r377000)
+++ head/astro/stellarium/Makefile	Wed Jan 14 08:51:31 2015	(r377001)
@@ -42,7 +42,7 @@ PLIST_SUB+=	MORE_STARS="@comment "
 
 .if ${PORT_OPTIONS:MHR_TEXTURES}
 MASTER_SITES+=	SF/${PORTNAME}/textures:gfx
-DISTFILES+=	textures-1K.zip:gfx milkyway.zip:gfx	# yes, in this order
+DISTFILES+=	textures-1K.zip:gfx
 .endif
 
 .if ${PORT_OPTIONS:MMULTIMEDIA}
@@ -60,7 +60,15 @@ post-install:
 		${STAGEDIR}${DATADIR}/stars/default
 .endif
 .if ${PORT_OPTIONS:MHR_TEXTURES}
-	${INSTALL_DATA} ${WRKDIR}/*.png ${STAGEDIR}${DATADIR}/textures
+	(cd ${WRKDIR} && for f in *.png; do \
+		new=`${STAT} -f '%z' $$f` ; \
+		existing=`${STAT} -f '%z' \
+			${STAGEDIR}${DATADIR}/textures/$$f` ; \
+		${TEST} $$new -gt $$existing && \
+			${ECHO_CMD} "-- Replacing texture: $$f\
+			(has larger file size)" ; \
+		${INSTALL_DATA} $$f ${STAGEDIR}${DATADIR}/textures ; \
+	done)
 .endif
 	@${MKDIR} ${STAGEDIR}${DOCSDIR}
 	${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${STAGEDIR}${DOCSDIR}

Modified: head/astro/stellarium/distinfo
==============================================================================
--- head/astro/stellarium/distinfo	Wed Jan 14 08:39:42 2015	(r377000)
+++ head/astro/stellarium/distinfo	Wed Jan 14 08:51:31 2015	(r377001)
@@ -12,5 +12,3 @@ SHA256 (stars_8_2v0_1.cat) = f1c0b3f2573
 SIZE (stars_8_2v0_1.cat) = 559068934
 SHA256 (textures-1K.zip) = 3622b73e9cfb65ba537072b0ed3b5ef92951e70878ace7557931d841c5bb3bec
 SIZE (textures-1K.zip) = 20216182
-SHA256 (milkyway.zip) = cffc11d22a1e0596e8d01800f54627a67a3ebcc745e5d138819e40d247aaa0d1
-SIZE (milkyway.zip) = 6389431



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201501140851.t0E8pVqP060902>