{"id":388,"date":"2019-07-09T12:32:21","date_gmt":"2019-07-09T11:32:21","guid":{"rendered":"https:\/\/www.weeklywhinge.com\/?p=388"},"modified":"2019-07-09T12:32:22","modified_gmt":"2019-07-09T11:32:22","slug":"undefined-reference-to-gzopen64","status":"publish","type":"post","link":"https:\/\/www.weeklywhinge.com\/?p=388","title":{"rendered":"undefined reference to gzopen64"},"content":{"rendered":"\n<p>So building postgres v11 on an old legacy centos server produced this error:<\/p>\n\n\n\n<p><code>pg_basebackup.o(.text+0xed0):postgres-11.4-build\/..\/postgresql-11.4\/src\/bin\/pg_basebackup\/pg_basebackup.c:1019: undefined reference to `gzopen64<\/code>&#8216;<\/p>\n\n\n\n<p>Turned out a new version of zlib had been manually installed in \/usr\/local and the included zlib.h pointed to the new version (which used gzopen64), while the old version in \/usr\/lib (and which had no gzopen64 symbol) was being linked. Adding <code style=\"white-space: nowrap;\">LDFLAGS=-L\/usr\/local\/lib<\/code> to the configure line was enough to make it build successfully.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>So building postgres v11 on an old legacy centos server produced this error: pg_basebackup.o(.text+0xed0):postgres-11.4-build\/..\/postgresql-11.4\/src\/bin\/pg_basebackup\/pg_basebackup.c:1019: undefined reference to `gzopen64&#8216; Turned out a new version of zlib had been manually installed in \/usr\/local and the included zlib.h pointed to the new version (which used gzopen64), while the old version in \/usr\/lib (and which had no gzopen64 symbol) [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-388","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/www.weeklywhinge.com\/index.php?rest_route=\/wp\/v2\/posts\/388","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.weeklywhinge.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.weeklywhinge.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.weeklywhinge.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.weeklywhinge.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=388"}],"version-history":[{"count":6,"href":"https:\/\/www.weeklywhinge.com\/index.php?rest_route=\/wp\/v2\/posts\/388\/revisions"}],"predecessor-version":[{"id":394,"href":"https:\/\/www.weeklywhinge.com\/index.php?rest_route=\/wp\/v2\/posts\/388\/revisions\/394"}],"wp:attachment":[{"href":"https:\/\/www.weeklywhinge.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=388"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.weeklywhinge.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=388"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.weeklywhinge.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=388"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}