18 #include <grass/gis.h>
19 #include <grass/glocale.h>
23 char buff[1024], answer[50];
30 if (
NULL == (Tmp_fd = fopen(Tmp_file,
"w"))) {
33 fprintf(Tmp_fd,
"sphere\n");
35 fprintf(Tmp_fd,
"%s\n", sph);
42 fprintf(stderr, _(
"\nPlease specify ellipsoid name\n"));
44 _(
"Enter 'list' for the list of available ellipsoids\n"));
45 fprintf(stderr, _(
"Hit RETURN to cancel request\n"));
49 if (strlen(answer) == 0)
51 if (strcmp(answer,
"list") == 0) {
54 pager =
getenv(
"GRASS_PAGER");
55 if (!pager || strlen(pager) == 0)
59 sprintf(buff,
"%s \"%s\" 1>&2", pager,
64 if (strcmp(answer,
"sphere") == 0)
67 fprintf(stderr, _(
"\ninvalid ellipsoid\n"));
73 sprintf(spheroid,
"%s", answer);
75 if (strcmp(spheroid,
"sphere") == 0) {