<p></p>
<h2 dir="auto">What version of osm2pgsql are you using?</h2>
<pre class="notranslate"><code class="notranslate">osm2pgsql version 1.6.0
Build: None
Compiled using the following library versions:
Libosmium 2.17.3
Proj [API 6] 8.2.1
Lua 5.3.6
</code></pre>
<h2 dir="auto">What operating system and PostgreSQL/PostGIS version are you using?</h2>
<p dir="auto">Ubuntu Jammy (22.04) Docker Image.</p>
<h2 dir="auto">Tell us something about your system</h2>
<p dir="auto">16GB 8core Docker Desktop on MAcOSX.</p>
<h2 dir="auto">What did you do exactly?</h2>
<p dir="auto">osm2pgsql with custom projection EPSG:28992 via <code class="notranslate">--proj=28992</code>.</p>
<h2 dir="auto">What did you expect to happen?</h2>
<p dir="auto">Data in PostGIS in EPSG:28992.</p>
<h2 dir="auto">What did happen instead?</h2>
<p dir="auto">Data in PostGIS ok with EPSG:28992 but coordinates are completely wrong, look like still in EPSG:3857, Web Merc.</p>
<h2 dir="auto">What did you do to try analyzing the problem?</h2>
<p dir="auto">Spent quite some time. Bashed into Docker Container, installed <code class="notranslate">proj-bin</code> since I suspect something wrong there.</p>
<pre class="notranslate"><code class="notranslate">$ projinfo EPSG:28992
PROJ.4 string:
+proj=sterea +lat_0=52.1561605555556 +lon_0=5.38763888888889 +k=0.9999079 +x_0=155000 +y_0=463000 +ellps=bessel +units=m +no_defs +type=crs

</code></pre>
<p dir="auto">This seems wrong, it is missing the <code class="notranslate">towgs84</code> parm. Hard to analyze as there is no <code class="notranslate">epsg</code> file anymore.<br>
The right proj string as I use in e.g. Mapnik,  should be:<br>
<code class="notranslate"><!ENTITY srs28992 "+proj=sterea +lat_0=52.15616055555555 +lon_0=5.38763888888889 +k=0.9999079 +x_0=155000 +y_0=463000 +ellps=bessel +towgs84=565.417,50.3319,465.552,-0.398957,0.343988,-1.8774,4.0725 +units=m +no_defs"> </code><br>
Maybe a proj issue after all, or is there something I can patch?</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />Reply to this email directly, <a href="https://github.com/openstreetmap/osm2pgsql/issues/1672">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AA6353RLBTKWQ4GUGOEGNNTVHO4PTANCNFSM5UVRB2BQ">unsubscribe</a>.<br />You are receiving this because you are subscribed to this thread.<img src="https://github.com/notifications/beacon/AA6353TCOAOLKTI2OKMQTJDVHO4PTA5CNFSM5UVRB2B2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4SF7HSIA.gif" height="1" width="1" alt="" /><span style="color: transparent; font-size: 0; display: none; visibility: hidden; overflow: hidden; opacity: 0; width: 0; height: 0; max-width: 0; max-height: 0; mso-hide: all">Message ID: <span><openstreetmap/osm2pgsql/issues/1672</span><span>@</span><span>github</span><span>.</span><span>com></span></span></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/osm2pgsql/issues/1672",
"url": "https://github.com/openstreetmap/osm2pgsql/issues/1672",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>