Skip to content

Commit

Permalink
install.rst: improve instructions regarding proj-data (fixes #3539)
Browse files Browse the repository at this point in the history
  • Loading branch information
a0x8o committed Aug 13, 2024
1 parent 1b6b21b commit 0402d1c
Show file tree
Hide file tree
Showing 5 changed files with 106 additions and 0 deletions.
5 changes: 5 additions & 0 deletions docs/source/install.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1453,6 +1453,7 @@ can be modified to suit the users needs. See :ref:`projsync` for more options.
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -2058,6 +2059,10 @@ can be modified to suit the users needs. See :ref:`projsync` for more options.
package can be downloaded and added to the :envvar:`PROJ_DATA` directory
(called ``PROJ_LIB`` before PROJ 9.1)
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
package can be downloaded and its content decompressed into one of the
directories where PROJ looks for :ref:`resources <resource_files>`
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))

Starting with PROJ 9.2, a ``uninstall`` target is available to remove files
installed by the ``install`` target::
Expand Down
68 changes: 68 additions & 0 deletions src/geodesic.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ static void Init(void) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -676,6 +677,9 @@ static void Init(void) {
=======
tolb = tol0 * tol2;
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
tolb = tol0;
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
xthresh = 1000 * tol2;
degree = pi/hd;
NaN = nan("0");
Expand Down Expand Up @@ -752,6 +756,7 @@ static double sumx(double u, double v, double* t) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -1308,6 +1313,9 @@ static double polyval(int N, const double p[], double x) {
=======
static double polyval(int N, const double p[], double x) {
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
static double polyvalx(int N, const double p[], double x) {
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
double y = N < 0 ? 0 : *p++;
while (--N >= 0) y = y * x + *p++;
return y;
Expand Down Expand Up @@ -2118,6 +2126,7 @@ static double geod_geninverse_int(const struct geod_geodesic* g,
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -2674,6 +2683,9 @@ static double geod_geninverse_int(const struct geod_geodesic* g,
=======
for (; numit < maxit2; ++numit) {
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
for (;; ++numit) {
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
/* the WGS84 test set: mean = 1.47, sd = 1.25, max = 16
* WGS84 and random input: mean = 2.85, sd = 0.60 */
double dv = 0,
Expand Down Expand Up @@ -2724,6 +2736,7 @@ static double geod_geninverse_int(const struct geod_geodesic* g,
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -2954,6 +2967,8 @@ static double geod_geninverse_int(const struct geod_geodesic* g,
>>>>>>> b1527fbb85 (install.rst: improve instructions regarding proj-data (fixes #3539))
=======
>>>>>>> da73f22a17 (install.rst: improve instructions regarding proj-data (fixes #3539))
=======
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
if (tripb ||
/* Reversed test to allow escape with NaNs */
!(fabs(v) >= (tripn ? 8 : 1) * tol0) ||
Expand Down Expand Up @@ -2990,6 +3005,7 @@ static double geod_geninverse_int(const struct geod_geodesic* g,
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
>>>>>>> c98204a06c (install.rst: improve instructions regarding proj-data (fixes #3539))
=======
Expand Down Expand Up @@ -3478,6 +3494,8 @@ static double geod_geninverse_int(const struct geod_geodesic* g,
/* Reversed test to allow escape with NaNs */
if (tripb || !(fabs(v) >= (tripn ? 8 : 1) * tol0)) break;
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
/* Update bracketing values */
if (v > 0 && (numit > maxit1 || calp1/salp1 > calp1b/salp1b))
{ salp1b = salp1; calp1b = calp1; }
Expand Down Expand Up @@ -3529,6 +3547,7 @@ static double geod_geninverse_int(const struct geod_geodesic* g,
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -3759,6 +3778,8 @@ static double geod_geninverse_int(const struct geod_geodesic* g,
>>>>>>> b1527fbb85 (install.rst: improve instructions regarding proj-data (fixes #3539))
=======
>>>>>>> da73f22a17 (install.rst: improve instructions regarding proj-data (fixes #3539))
=======
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
if (fabs(dalp1) < pi) {
double
sdalp1 = sin(dalp1), cdalp1 = cos(dalp1),
Expand Down Expand Up @@ -3803,6 +3824,7 @@ static double geod_geninverse_int(const struct geod_geodesic* g,
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
<<<<<<< HEAD
>>>>>>> 8d733d2079 (install.rst: improve instructions regarding proj-data (fixes #3539))
Expand Down Expand Up @@ -4431,6 +4453,8 @@ static double geod_geninverse_int(const struct geod_geodesic* g,
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
=======
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
}
}
/* Either dv was not positive or updated value was outside legal
Expand Down Expand Up @@ -5045,6 +5069,7 @@ double A3f(const struct geod_geodesic* g, double eps) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -5601,6 +5626,9 @@ double A3f(const struct geod_geodesic* g, double eps) {
=======
return polyval(nA3 - 1, g->A3x, eps);
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
return polyvalx(nA3 - 1, g->A3x, eps);
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
}

void C3f(const struct geod_geodesic* g, double eps, double c[]) {
Expand Down Expand Up @@ -5654,6 +5682,7 @@ void C3f(const struct geod_geodesic* g, double eps, double c[]) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -6210,6 +6239,9 @@ void C3f(const struct geod_geodesic* g, double eps, double c[]) {
=======
c[l] = mult * polyval(m, g->C3x + o, eps);
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
c[l] = mult * polyvalx(m, g->C3x + o, eps);
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
o += m + 1;
}
}
Expand Down Expand Up @@ -6264,6 +6296,7 @@ void C4f(const struct geod_geodesic* g, double eps, double c[]) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -6820,6 +6853,9 @@ void C4f(const struct geod_geodesic* g, double eps, double c[]) {
=======
c[l] = mult * polyval(m, g->C4x + o, eps);
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
c[l] = mult * polyvalx(m, g->C4x + o, eps);
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
o += m + 1;
mult *= eps;
}
Expand Down Expand Up @@ -6875,6 +6911,7 @@ double A1m1f(double eps) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -7431,6 +7468,9 @@ double A1m1f(double eps) {
=======
double t = polyval(m, coeff, sq(eps)) / coeff[m + 1];
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
double t = polyvalx(m, coeff, sq(eps)) / coeff[m + 1];
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
return (t + eps) / (1 - eps);
}

Expand Down Expand Up @@ -7499,6 +7539,7 @@ void C1f(double eps, double c[]) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -8055,6 +8096,9 @@ void C1f(double eps, double c[]) {
=======
c[l] = d * polyval(m, coeff + o, eps2) / coeff[o + m + 1];
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
c[l] = d * polyvalx(m, coeff + o, eps2) / coeff[o + m + 1];
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
o += m + 2;
d *= eps;
}
Expand Down Expand Up @@ -8125,6 +8169,7 @@ void C1pf(double eps, double c[]) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -8681,6 +8726,9 @@ void C1pf(double eps, double c[]) {
=======
c[l] = d * polyval(m, coeff + o, eps2) / coeff[o + m + 1];
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
c[l] = d * polyvalx(m, coeff + o, eps2) / coeff[o + m + 1];
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
o += m + 2;
d *= eps;
}
Expand Down Expand Up @@ -8736,6 +8784,7 @@ double A2m1f(double eps) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -9292,6 +9341,9 @@ double A2m1f(double eps) {
=======
double t = polyval(m, coeff, sq(eps)) / coeff[m + 1];
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
double t = polyvalx(m, coeff, sq(eps)) / coeff[m + 1];
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
return (t - eps) / (1 + eps);
}

Expand Down Expand Up @@ -9360,6 +9412,7 @@ void C2f(double eps, double c[]) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -9916,6 +9969,9 @@ void C2f(double eps, double c[]) {
=======
c[l] = d * polyval(m, coeff + o, eps2) / coeff[o + m + 1];
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
c[l] = d * polyvalx(m, coeff + o, eps2) / coeff[o + m + 1];
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
o += m + 2;
d *= eps;
}
Expand Down Expand Up @@ -9983,6 +10039,7 @@ void A3coeff(struct geod_geodesic* g) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -10539,6 +10596,9 @@ void A3coeff(struct geod_geodesic* g) {
=======
g->A3x[k++] = polyval(m, coeff + o, g->n) / coeff[o + m + 1];
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
g->A3x[k++] = polyvalx(m, coeff + o, g->n) / coeff[o + m + 1];
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
o += m + 2;
}
}
Expand Down Expand Up @@ -10624,6 +10684,7 @@ void C3coeff(struct geod_geodesic* g) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -11180,6 +11241,9 @@ void C3coeff(struct geod_geodesic* g) {
=======
g->C3x[k++] = polyval(m, coeff + o, g->n) / coeff[o + m + 1];
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
g->C3x[k++] = polyvalx(m, coeff + o, g->n) / coeff[o + m + 1];
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
o += m + 2;
}
}
Expand Down Expand Up @@ -11278,6 +11342,7 @@ void C4coeff(struct geod_geodesic* g) {
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -11834,6 +11899,9 @@ void C4coeff(struct geod_geodesic* g) {
=======
g->C4x[k++] = polyval(m, coeff + o, g->n) / coeff[o + m + 1];
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
g->C4x[k++] = polyvalx(m, coeff + o, g->n) / coeff[o + m + 1];
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
o += m + 2;
}
}
Expand Down
4 changes: 4 additions & 0 deletions src/geodesic.h
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -630,6 +631,9 @@
=======
#define GEODESIC_VERSION_MINOR 0
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
#define GEODESIC_VERSION_MINOR 1
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))
/**
* The patch level of the geodesic library. (This tracks the version of
* GeographicLib.)
Expand Down
4 changes: 4 additions & 0 deletions src/init.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -815,6 +815,7 @@ pj_init_ctx_with_allow_init_epsg(PJ_CONTEXT *ctx, int argc, char **argv, int all
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> 885e4882b8 (Merge pull request #3524 from cffk/merid-update-fix)
Expand Down Expand Up @@ -1371,6 +1372,9 @@ pj_init_ctx_with_allow_init_epsg(PJ_CONTEXT *ctx, int argc, char **argv, int all
=======
geod_init(PIN->geod, PIN->a, PIN->es / (1 + sqrt (PIN->one_es)));
>>>>>>> 0a2f6458d1 (Merge pull request #3524 from cffk/merid-update-fix)
=======
geod_init(PIN->geod, PIN->a, PIN->f);
>>>>>>> 9a55b4f828 (install.rst: improve instructions regarding proj-data (fixes #3539))

/* Projection specific initialization */
err = proj_errno_reset (PIN);
Expand Down
Loading

0 comments on commit 0402d1c

Please sign in to comment.