graphics/rayshade: Unbreak with llvm15

- Pet portclippy
- Adopt port
This commit is contained in:
Muhammad Moinur Rahman 2023-05-17 20:39:47 +02:00
parent 3f4e9f1a3a
commit e3ec54e790
15 changed files with 75 additions and 78 deletions

View file

@ -9,7 +9,7 @@ DISTFILES= ${PORTNAME}.${PORTVERSION}.tar.Z
DIST_SUBDIR= rayshade
EXTRACT_ONLY= ${PORTNAME}.${PORTVERSION}.tar.Z
MAINTAINER= ports@FreeBSD.org
MAINTAINER= bofh@FreeBSD.org
COMMENT= Extensible system for creating ray-traced images
WWW= http://www-graphics.stanford.edu/~cek/rayshade/
@ -20,17 +20,19 @@ LICENSE_PERMS= dist-mirror no-dist-sell pkg-mirror no-pkg-sell auto-accept
BUILD_DEPENDS= ${LOCALBASE}/lib/librle.a:graphics/urt
WRKSRC= ${WRKDIR}/${PORTNAME}.${PORTVERSION:R}
HAS_CONFIGURE= yes
CONFIGURE_SCRIPT= Configure
ALL_TARGET= # empty
WRKSRC= ${WRKDIR}/${PORTNAME}.${PORTVERSION:R}
PLIST_FILES= bin/rayshade
PORTDOCS= *
PORTEXAMPLES= *
PLIST_FILES= bin/rayshade
OPTIONS_DEFINE= DOCS EXAMPLES
DOCS_DISTFILES= guide.ps.Z
.include <bsd.port.options.mk>
@ -39,6 +41,12 @@ DOCS_DISTFILES= guide.ps.Z
CONFIGURE_ARGS= < ${WRKDIR}/config.ans
.endif
.include <bsd.port.pre.mk>
.if ${OPSYS} == FreeBSD && ( ${OSVERSION} >= 1400079 || ( ${OSVERSION} >= 1302505 && ${OSVERSION} < 1400000 ))
CFLAGS+= -Wno-error=int-conversion
.endif
pre-configure:
@${SED} -e \
"s,@CFLAGS@,${CFLAGS},g ; \
@ -60,4 +68,4 @@ do-install-EXAMPLES-on:
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
${INSTALL_DATA} ${WRKSRC}/Examples/* ${STAGEDIR}${EXAMPLESDIR}
.include <bsd.port.mk>
.include <bsd.port.post.mk>

View file

@ -1,6 +1,6 @@
--- Configure.orig Mon Feb 10 12:04:23 1992
+++ Configure Tue Jul 29 14:18:04 2003
@@ -28,10 +28,11 @@
--- Configure.orig 1992-02-10 03:04:23 UTC
+++ Configure
@@ -28,10 +28,11 @@ PATH=$PATH:'/sys5.3/bin:/sys5.3/usr/bin /bsd4.3/bin /b
PATH=$PATH:'/bsd4.3/usr/bin:/usr/bsd'
export PATH || (echo "OOPS, this isn't sh. Desperation time. I will feed myself to sh."; sh $0; kill $$)
@ -16,7 +16,7 @@
(alias) >/dev/null 2>&1 && \
echo "(I see you are using the Korn shell. Some ksh's blow up on Configure," && \
@@ -660,6 +661,7 @@
@@ -660,6 +661,7 @@ case "$libs" in
;;
esac
set /usr/ccs/lib/libc.so
@ -24,7 +24,7 @@
test -f $1 || set /usr/lib/libc.so
test -f $1 || set /usr/lib/libc.so.[0-9]*
eval set \$$#
@@ -872,7 +874,7 @@
@@ -872,7 +874,7 @@ $eunicefix filexp
: determine where manual pages are on this system
echo " "
case "$sysman" in
@ -33,7 +33,7 @@
;;
esac
if test -d "$sysman"; then
@@ -1418,14 +1420,8 @@
@@ -1418,14 +1420,8 @@ if $contains '^index$' libc.list >/dev/null 2>&1 ; the
if $contains '^strchr$' libc.list >/dev/null 2>&1 ; then
if $contains strchr "$strings" >/dev/null 2>&1 ; then
if $contains index "$strings" >/dev/null 2>&1 ; then

View file

@ -1,5 +1,5 @@
--- etc/rsconvert/lex.l.orig 1992-02-10 12:03:54.000000000 +0900
+++ etc/rsconvert/lex.l 2013-05-28 22:55:24.000000000 +0900
--- etc/rsconvert/lex.l.orig 1992-02-10 03:03:54 UTC
+++ etc/rsconvert/lex.l
@@ -22,6 +22,7 @@
#include "libcommon/common.h"
#include "y.tab.h"
@ -8,7 +8,7 @@
alpha [a-zA-Z]
special [\.\_-]
digit [0-9]
@@ -113,7 +114,7 @@
@@ -113,7 +114,7 @@ skipcomments()
if ((c = input()) == '/') {
WriteChar(c);
WriteNewline();

View file

@ -1,4 +1,4 @@
--- etc/rsconvert/yacc.y.orig
--- etc/rsconvert/yacc.y.orig 1992-02-10 03:04:17 UTC
+++ etc/rsconvert/yacc.y
@@ -14,6 +14,7 @@
/* $Id: yacc.y,v 4.0.1.3 92/02/07 11:05:21 cek Exp Locker: cek $ */

View file

@ -1,10 +0,0 @@
--- libray/libsurf/fog.c.orig Mon Feb 10 04:03:33 1992
+++ libray/libsurf/fog.c Wed Feb 7 18:36:49 2007
@@ -28,7 +28,6 @@
Color *color, *trans;
{
Fog *fog;
- static void ComputeFog();
fog = (Fog *)Malloc(sizeof(Fog));

View file

@ -1,10 +0,0 @@
--- libray/libsurf/fogdeck.c.orig Mon Feb 10 04:03:45 1992
+++ libray/libsurf/fogdeck.c Wed Feb 7 18:37:51 2007
@@ -31,7 +31,6 @@
Color *color, *trans;
{
Fogdeck *fogdeck;
- static void ComputeFogdeck();
fogdeck = (Fogdeck *)Malloc(sizeof(Fogdeck));

View file

@ -2,9 +2,9 @@ On really fast machines some of the .o files aren't being added to
libray.a because they are generated so fast that make(1) thinks the
library is up-to-date. Marvel at the horrific hack below.
--- libray/Makefile.orig Sat Feb 26 16:41:28 2000
+++ libray/Makefile Sat Feb 26 16:42:36 2000
@@ -12,6 +12,8 @@
--- libray/Makefile.orig 1992-02-10 03:03:05 UTC
+++ libray/Makefile
@@ -12,6 +12,8 @@ default:
for i in $(STUFF); do \
(cd $$i && $(MAKE)); \
done

View file

@ -1,6 +1,6 @@
--- libray/libtext/texture.c.orig 1992-02-10 12:04:02.000000000 +0900
+++ libray/libtext/texture.c 2013-05-28 22:41:59.000000000 +0900
@@ -162,7 +162,7 @@
--- libray/libtext/texture.c.orig 1992-02-10 03:04:02 UTC
+++ libray/libtext/texture.c
@@ -162,7 +162,7 @@ Float *u, *v;
*u = ptmp.x;
*v = ptmp.y;
if (dpdu == (Vector *)NULL || dpdv == (Vector *)NULL)

View file

@ -1,6 +1,6 @@
--- libray/liblight/extended.c.orig Mon Feb 10 04:03:43 1992
+++ libray/liblight/extended.c Wed Feb 7 18:34:20 2007
@@ -54,7 +54,7 @@
--- libray/liblight/extended.c.orig 1992-02-10 03:03:43 UTC
+++ libray/liblight/extended.c
@@ -54,7 +54,7 @@ ExtendedMethods()
/*
* Compute intensity ('color') of extended light source 'lp' from 'pos'.
*/

View file

@ -1,6 +1,6 @@
--- libray/libobj/hf.c.orig Mon Feb 10 04:04:18 1992
+++ libray/libobj/hf.c Wed Feb 7 18:27:10 2007
@@ -42,7 +42,7 @@
--- libray/libobj/hf.c.orig 1992-02-10 03:04:18 UTC
+++ libray/libobj/hf.c
@@ -42,7 +42,7 @@ typedef struct {
Vector cp, pDX, pDY;
} Trav2D;

View file

@ -0,0 +1,10 @@
--- libray/libsurf/fog.c.orig 1992-02-10 03:03:33 UTC
+++ libray/libsurf/fog.c
@@ -28,7 +28,6 @@ FogCreate(color, trans)
Color *color, *trans;
{
Fog *fog;
- static void ComputeFog();
fog = (Fog *)Malloc(sizeof(Fog));

View file

@ -0,0 +1,10 @@
--- libray/libsurf/fogdeck.c.orig 1992-02-10 03:03:45 UTC
+++ libray/libsurf/fogdeck.c
@@ -31,7 +31,6 @@ int octaves;
Color *color, *trans;
{
Fogdeck *fogdeck;
- static void ComputeFogdeck();
fogdeck = (Fogdeck *)Malloc(sizeof(Fogdeck));

View file

@ -1,5 +1,5 @@
--- libshade/lex.l.orig 1992-02-10 12:04:02.000000000 +0900
+++ libshade/lex.l 2013-05-28 22:45:54.000000000 +0900
--- libshade/lex.l.orig 1992-02-10 03:04:02 UTC
+++ libshade/lex.l
@@ -29,6 +29,7 @@
#include "y.tab.h"
extern char *strsave();
@ -8,7 +8,7 @@
alpha [a-zA-Z]
special [\.\_-]
digit [0-9]
@@ -171,7 +172,7 @@
@@ -171,7 +172,7 @@ skipcomments()
while (input() != '*')
;
if ((c = input()) == '/')

View file

@ -1,4 +1,4 @@
--- libshade/yacc.y.orig
--- libshade/yacc.y.orig 1992-02-10 03:04:21 UTC
+++ libshade/yacc.y
@@ -13,6 +13,8 @@
/* for any purpose. It is provided solely "as is". */

View file

@ -1,27 +1,16 @@
*** raypaint/Makefile.SH.orig Sat Mar 28 20:31:28 1998
--- raypaint/Makefile.SH Sat Mar 28 20:31:55 1998
***************
*** 55,65 ****
#
# If using X11, use:
! #GRAPHICSLIB = -lX11
#
# If you are using GL, use:
! GRAPHICSLIB = -lgl_s
LIBRAY = $(LIBRAYDIR)/libray.a
LIBSHADE = $(LIBSHADEDIR)/libshade.a
--- 55,65 ----
#
# If using X11, use:
! GRAPHICSLIB = -lX11
#
# If you are using GL, use:
! #GRAPHICSLIB = -lgl_s
LIBRAY = $(LIBRAYDIR)/libray.a
LIBSHADE = $(LIBSHADEDIR)/libshade.a
--- raypaint/Makefile.SH.orig 1992-02-10 03:03:47 UTC
+++ raypaint/Makefile.SH
@@ -55,11 +55,11 @@ YFLAGS = -d
#
# If using X11, use:
-#GRAPHICSLIB = -lX11
+GRAPHICSLIB = -lX11
#
# If you are using GL, use:
-GRAPHICSLIB = -lgl_s
+#GRAPHICSLIB = -lgl_s
LIBRAY = $(LIBRAYDIR)/libray.a
LIBSHADE = $(LIBSHADEDIR)/libshade.a