[r-cran-maps] 19/64: Import Upstream version 2.0-38
Andreas Tille
tille at debian.org
Thu Sep 7 07:32:30 UTC 2017
This is an automated email from the git hooks/post-receive script.
tille pushed a commit to branch master
in repository r-cran-maps.
commit fb9f59f08bc853f142f32949e3ff31e279a0e774
Author: Andreas Tille <tille at debian.org>
Date: Thu Sep 7 09:26:00 2017 +0200
Import Upstream version 2.0-38
---
DESCRIPTION | 6 +++---
src/Gmake.c | 45 +++++++++++++++++++++++----------------------
src/Lmake.c | 44 +++++++++++++++++++++++---------------------
src/Makefile | 2 ++
4 files changed, 51 insertions(+), 46 deletions(-)
diff --git a/DESCRIPTION b/DESCRIPTION
index 7fa7954..2dd9910 100644
--- a/DESCRIPTION
+++ b/DESCRIPTION
@@ -1,7 +1,7 @@
Package: maps
Title: Draw Geographical Maps
-Version: 2.0-37
-Date: 2007-06-14
+Version: 2.0-38
+Date: 2007-09-12
Author: Original S code by Richard A. Becker and Allan R. Wilks.
R version by Ray Brownrigg <Ray.Brownrigg at mcs.vuw.ac.nz>
Enhancements by Thomas P Minka <surname at stat.cmu.edu>
@@ -11,4 +11,4 @@ Depends: R (>= 1.7.0)
Suggests: mapproj
License: GPL2
Maintainer: Ray Brownrigg <Ray.Brownrigg at mcs.vuw.ac.nz>
-Packaged: Thu Jun 14 14:21:13 2007; ray
+Packaged: Wed Sep 12 14:18:10 2007; ray
diff --git a/src/Gmake.c b/src/Gmake.c
index 5cbea5f..1473c71 100644
--- a/src/Gmake.c
+++ b/src/Gmake.c
@@ -108,9 +108,9 @@ Polyline r;
seek = sizeof(int) + sizeof(Polyline) + (r-1)*sizeof(struct line_h);
if(Seek(Lin, seek) == -1)
- fatal("Cannot seek to header in %s", (int)Linefile);
+ fatal("Cannot seek to header in %s", (int)Linefile, 0);
if(Read(Lin, &lh, 1) != 1)
- fatal("Cannot read header in %s", (int)Linefile);
+ fatal("Cannot read header in %s", (int)Linefile, 0);
return(&lh);
}
@@ -126,24 +126,25 @@ FILE *in, *out;
int column, k;
if(Read(in, &n, 1) != 1)
- fatal("Cannot read size");
+ fatal("Cannot read size", 0, 0);
Alloc(rh, n, struct region_h);
if(rh == NULL)
- fatal("No memory for headers");
+ fatal("No memory for headers", 0, 0);
if(Read(in, rh, n) != n)
- fatal("Cannot read headers");
+ fatal("Cannot read headers", 0, 0);
for(i = 0; i < n; i++)
N = Max(N, rh[i].nline);
Alloc(r, N, Polyline);
if(r == NULL)
- fatal("No memory for data");
+ fatal("No memory for data", 0, 0);
for(i = 0; i < n; i++) {
if((m = rh[i].nline) <= 0)
- fatal("Negative line count at header %d", (int)i);
+ fatal("Negative line count at header %d", (int)i,
+ 0);
if(Seek(in, rh[i].offset) < 0)
- fatal("Cannot seek to record %d", (int)i);
+ fatal("Cannot seek to record %d", (int)i, 0);
if(Read(in, r, m) != m)
- fatal("Cannot read record %d", (int)i);
+ fatal("Cannot read record %d", (int)i, 0);
column = 0;
for(j = 0; j < m; j++) {
sprintf(buf, " %d", (int)r[j]);
@@ -170,11 +171,11 @@ FILE *in, *out;
Polyline *r;
if(Seek(out, sizeof(Region) + np*sizeof(struct region_h)) < 0)
- fatal("Cannot seek in input file");
+ fatal("Cannot seek in input file", 0, 0);
Alloc(rh, np, struct region_h);
Alloc(r, maxl+1, Polyline);
if(rh == NULL || r == NULL)
- fatal("No memory");
+ fatal("No memory", 0, 0);
for(i = 0; i < np; i++) {
m = 0;
while((t = getpoly(in, &r[m++])) > 0)
@@ -186,14 +187,14 @@ FILE *in, *out;
rh[i].nline = m;
set_range(rh+i, r);
if(Write(out, r, m) != m)
- fatal("Cannot write record %d", (int)i);
+ fatal("Cannot write record %d", (int)i, 0);
}
if(Seek(out, 0) < 0)
- fatal("Cannot seek to beginning of output file");
+ fatal("Cannot seek to beginning of output file", 0, 0);
if(Write(out, &n, 1) != 1)
- fatal("Cannot write size to output file");
+ fatal("Cannot write size to output file", 0, 0);
if(Write(out, rh, np) != np)
- fatal("Cannot write headers to output file");
+ fatal("Cannot write headers to output file", 0, 0);
}
int
@@ -207,23 +208,23 @@ char *av[];
Me = av[0];
if(ac < 5)
- fatal(Usage, (int)Me);
+ fatal(Usage, (int)Me, 0);
ascii = *av[1] == 'a';
if(ac != (ascii ? 5 : 6))
- fatal(Usage, (int)Me);
+ fatal(Usage, (int)Me, 0);
Infile = av[2];
if((in = fopen(av[2], "rb")) == NULL)
- fatal("Cannot open %s for reading", (int)av[2]);
+ fatal("Cannot open %s for reading", (int)av[2], 0);
if((in2 = fopen(av[3], "rb")) == NULL)
- fatal("Cannot open %s for reading", (int)av[3]);
+ fatal("Cannot open %s for reading", (int)av[3], 0);
if(fscanf(in2, "%d%d", &np, &maxl) != 2)
- fatal("Cannot read stats data file %s", (int)av[3]);
+ fatal("Cannot read stats data file %s", (int)av[3], 0);
n = np; /* won't read directly */
if((out = fopen(av[4], "wb")) == NULL)
- fatal("Cannot open %s for writing", (int)av[4]);
+ fatal("Cannot open %s for writing", (int)av[4], 0);
Linefile = av[5];
if(!ascii && (Lin = fopen(av[5], "rb")) == NULL)
- fatal("Cannot open %s for reading", (int)av[5]);
+ fatal("Cannot open %s for reading", (int)av[5], 0);
ascii ? to_ascii(in, out) : to_binary(in, out);
exit(0);
}
diff --git a/src/Lmake.c b/src/Lmake.c
index 350497a..c27fc13 100644
--- a/src/Lmake.c
+++ b/src/Lmake.c
@@ -117,30 +117,31 @@ FILE *in, *out;
int column, k;
if(Seek(in, sizeof(Coordtype)))
- fatal("Cannot seek past coordtype");
+ fatal("Cannot seek past coordtype", 0, 0);
if(Read(in, &n, 1) != 1)
- fatal("Cannot read size");
+ fatal("Cannot read size", 0, 0);
Alloc(lh, n, struct line_h);
if(lh == NULL)
- fatal("No memory for headers");
+ fatal("No memory for headers", 0, 0);
if(Read(in, lh, n) != n)
- fatal("Cannot read headers");
+ fatal("Cannot read headers", 0, 0);
for(i = 0; i < n; i++)
N = Max(N, lh[i].npair);
Alloc(xy, N, struct pair);
if(xy == NULL)
- fatal("No memory for data");
+ fatal("No memory for data", 0, 0);
for(i = 0; i < n; i++) {
if((m = lh[i].npair) <= 0)
- fatal("Negative pair count at header %d", (int)i);
+ fatal("Negative pair count at header %d", (int)i,
+ 0);
if(Seek(in, lh[i].offset) < 0)
- fatal("Cannot seek to record %d", (int)i);
+ fatal("Cannot seek to record %d", (int)i, 0);
/*
* Simple read; change this to use other means of
* storing the polyline data.
*/
if(Read(in, xy, m) != m)
- fatal("Cannot read record %d", (int)i);
+ fatal("Cannot read record %d", (int)i, 0);
fprintf(out, "%d %d\n", (int)lh[i].left, (int)lh[i].right);
column = 0;
for(j = 0; j < m; j++) {
@@ -169,14 +170,15 @@ FILE *in, *out;
struct pair *xy;
if(Seek(out, sizeof(Coordtype) + sizeof(Polyline) + nl*sizeof(struct line_h)) < 0)
- fatal("Cannot seek in input file");
+ fatal("Cannot seek in input file", 0, 0);
Alloc(lh, nl, struct line_h);
Alloc(xy, maxp+1, struct pair);
if(lh == NULL || xy == NULL)
- fatal("No memory");
+ fatal("No memory", 0, 0);
for(i = 0; i < nl; i++) {
if(fscanf(in, "%d%d", &l, &r) != 2)
- fatal("Cannot read left and right at line %d", (int)i+1);
+ fatal("Cannot read left and right at line %d", (int)i+1,
+ 0);
lh[i].left = l;
lh[i].right = r;
m = 0;
@@ -196,16 +198,16 @@ FILE *in, *out;
* storing the polyline data.
*/
if(Write(out, xy, m) != m)
- fatal("Cannot write record %d", (int)i);
+ fatal("Cannot write record %d", (int)i, 0);
}
if(Seek(out, 0) < 0)
- fatal("Cannot seek to beginning of output file");
+ fatal("Cannot seek to beginning of output file", 0, 0);
if(Write(out, &Coordtype, 1) != 1)
- fatal("Cannot write coordtype to output file");
+ fatal("Cannot write coordtype to output file", 0, 0);
if(Write(out, &n, 1) != 1)
- fatal("Cannot write size to output file");
+ fatal("Cannot write size to output file", 0, 0);
if(Write(out, lh, nl) != nl)
- fatal("Cannot write headers to output file");
+ fatal("Cannot write headers to output file", 0, 0);
}
int
@@ -218,19 +220,19 @@ char *av[];
Me = av[0];
if(ac != 7)
- fatal(Usage, (int)Me);
+ fatal(Usage, (int)Me, 0);
Precision = atoi(av[1]);
Coordtype = av[2][0] == 's' ? SPHERE : PLANE;
Infile = av[4];
if((in = fopen(av[4], "rb")) == NULL)
- fatal("Cannot open %s for reading", (int)av[4]);
+ fatal("Cannot open %s for reading", (int)av[4], 0);
if((in2 = fopen(av[5], "rb")) == NULL)
- fatal("Cannot open %s for reading", (int)av[5]);
+ fatal("Cannot open %s for reading", (int)av[5], 0);
if(fscanf(in2, "%d%d", &nl, &maxp) != 2)
- fatal("Cannot read stats data file %s", (int)av[3]);
+ fatal("Cannot read stats data file %s", (int)av[3], 0);
n = nl;
if((out = fopen(av[6], "wb")) == NULL)
- fatal("Cannot open %s for writing", (int)av[6]);
+ fatal("Cannot open %s for writing", (int)av[6], 0);
av[3][0] == 'a' ? (void) to_ascii(in, out) : (void) to_binary(in, out);
exit(0);
}
diff --git a/src/Makefile b/src/Makefile
index 02b5493..e778b39 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -6,6 +6,8 @@ CP = cp
ECHO = echo
RM = rm
+CFLAGS = -g -Wall -pedantic -O6
+
OBJS = mapget.o \
smooth.o \
thin.o
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/r-cran-maps.git
More information about the debian-science-commits
mailing list