[Midnightbsd-cvs] mports [24191] U trunk/benchmarks/raidtest/files/raidtest.c: fix build

laffer1 at midnightbsd.org laffer1 at midnightbsd.org
Tue Sep 4 09:52:05 EDT 2018


Revision: 24191
          http://svnweb.midnightbsd.org/mports/?rev=24191
Author:   laffer1
Date:     2018-09-04 09:52:04 -0400 (Tue, 04 Sep 2018)
Log Message:
-----------
fix build

Modified Paths:
--------------
    trunk/benchmarks/raidtest/Makefile
    trunk/benchmarks/raidtest/files/Makefile
    trunk/benchmarks/raidtest/files/raidtest.c

Property Changed:
----------------
    trunk/benchmarks/raidtest/files/Makefile
    trunk/benchmarks/raidtest/files/raidtest.c

Modified: trunk/benchmarks/raidtest/Makefile
===================================================================
--- trunk/benchmarks/raidtest/Makefile	2018-09-04 13:49:10 UTC (rev 24190)
+++ trunk/benchmarks/raidtest/Makefile	2018-09-04 13:52:04 UTC (rev 24191)
@@ -1,7 +1,7 @@
 # $MidnightBSD$
 
 PORTNAME=	raidtest
-PORTVERSION=	1.2
+PORTVERSION=	1.3
 CATEGORIES=	benchmarks
 MASTER_SITES=	# none
 DISTFILES=	# none
@@ -13,13 +13,12 @@
 
 FAKE_OPTS=	trueprefix
 
-NO_WRKSUBDIR=	yes
 PLIST_FILES=	bin/raidtest
 
 do-fetch:
 
 do-extract:
-	${MKDIR} ${WRKDIR}
-	${LN} -sf ${FILESDIR}/${PORTNAME}.c ${FILESDIR}/Makefile ${WRKDIR}
+	${MKDIR} ${WRKSRC}
+	${LN} -sf ${FILESDIR}/${PORTNAME}.c ${FILESDIR}/Makefile ${WRKSRC}
 
 .include <bsd.port.mk>

Modified: trunk/benchmarks/raidtest/files/Makefile
===================================================================
--- trunk/benchmarks/raidtest/files/Makefile	2018-09-04 13:49:10 UTC (rev 24190)
+++ trunk/benchmarks/raidtest/files/Makefile	2018-09-04 13:52:04 UTC (rev 24191)
@@ -1,4 +1,4 @@
-# $MidnightBSD$
+# $FreeBSD: head/benchmarks/raidtest/files/Makefile 340722 2014-01-22 17:00:46Z mat $
 
 PROG=	raidtest
 NO_MAN=	true


Property changes on: trunk/benchmarks/raidtest/files/Makefile
___________________________________________________________________
Deleted: cvs2svn:cvs-rev
## -1 +0,0 ##
-1.2
\ No newline at end of property
Modified: trunk/benchmarks/raidtest/files/raidtest.c
===================================================================
--- trunk/benchmarks/raidtest/files/raidtest.c	2018-09-04 13:49:10 UTC (rev 24190)
+++ trunk/benchmarks/raidtest/files/raidtest.c	2018-09-04 13:52:04 UTC (rev 24191)
@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__MBSDID("$MidnightBSD$");
+__FBSDID("$FreeBSD: head/benchmarks/raidtest/files/raidtest.c 346787 2014-03-02 18:19:48Z mav $");
 
 #include <sys/param.h>
 #include <sys/types.h>
@@ -113,8 +113,8 @@
 static void
 raidtest_genfile(int argc, char *argv[])
 {
-	uintmax_t i, nreqs, mediasize, nsectors, nbytes, nrreqs, nwreqs;
-	unsigned secsize, maxsec;
+	uintmax_t i, nreqs, mediasize, nsectors, nbytes, nrreqs, nwreqs, maxsec;
+	unsigned secsize;
 	const char *file = NULL;
 	struct ioreq iorq;
 	int ch, fd, flags, rdonly, wronly;
@@ -189,7 +189,8 @@
 		iorq.iorq_length = gen_size(secsize);
 		/* Generate I/O request offset. */
 		maxsec = nsectors - (iorq.iorq_length / secsize);
-		iorq.iorq_offset = (arc4random() % maxsec) * secsize;
+		iorq.iorq_offset = ((((uintmax_t)arc4random() << 32) |
+		    arc4random()) % maxsec) * secsize;
 		/* Generate I/O request type. */
 		if (rdonly)
 			iorq.iorq_type = IO_TYPE_READ;


Property changes on: trunk/benchmarks/raidtest/files/raidtest.c
___________________________________________________________________
Deleted: cvs2svn:cvs-rev
## -1 +0,0 ##
-1.2
\ No newline at end of property


More information about the Midnightbsd-cvs mailing list