Closed deevroman closed 2 months ago
Same problem here. Build is running through without problems. But executing the binary is causing the error above.
I haven't yet been able to reproduce this (macOS 14.1, Mac mini M2). Would welcome any reports that might indicate a possible cause.
Well, for starters, here are the build logs
From the curious I see:
c++ -O3 -Wall -Wno-unknown-pragmas -Wno-sign-compare -std=c++14 -pthread -fPIE -DTM_VERSION=v3.0.0 -o tilemaker src/attribute_store.o src/coordinates_geom.o src/coordinates.o src/external/streamvbyte_decode.o src/external/streamvbyte_encode.o src/external/streamvbyte_zigzag.o src/geojson_processor.o src/geom.o src/helpers.o src/mbtiles.o src/mmap_allocator.o src/node_stores.o src/options_parser.o src/osm_lua_processing.o src/osm_mem_tiles.o src/osm_store.o src/output_object.o src/pbf_processor.o src/pbf_reader.o src/pmtiles.o src/pooled_string.o src/relation_roles.o src/sharded_node_store.o src/sharded_way_store.o src/shared_data.o src/shp_mem_tiles.o src/shp_processor.o src/significant_tags.o src/sorted_node_store.o src/sorted_way_store.o src/tag_map.o src/tile_coordinates_set.o src/tile_data.o src/tilemaker.o src/tile_worker.o src/way_stores.o -I/opt/homebrew/include -isystem ./include -I./src -I/opt/homebrew/include/luajit-2.1 -DLUAJIT -L/opt/homebrew/lib -lz -lluajit-5.1 -lboost_program_options -lsqlite3 -lboost_filesystem -lboost_system -lboost_iostreams -lshp -pthread -pagezero_size 10000 -image_base 100000000
ld: warning: Linking with PIE, -image_base will be ignored
c++ -O3 -Wall -Wno-unknown-pragmas -Wno-sign-compare -std=c++14 -pthread -fPIE -DTM_VERSION=v3.0.0 -o server/server.o -c server/server.cpp -I/opt/homebrew/include -isystem ./include -I./src -I/opt/homebrew/include/luajit-2.1 -DLUAJIT
c++ -O3 -Wall -Wno-unknown-pragmas -Wno-sign-compare -std=c++14 -pthread -fPIE -DTM_VERSION=v3.0.0 -o tilemaker-server server/server.o -I/opt/homebrew/include -isystem ./include -I./src -I/opt/homebrew/include/luajit-2.1 -DLUAJIT -L/opt/homebrew/lib -lz -lluajit-5.1 -lboost_program_options -lsqlite3 -lboost_filesystem -lboost_system -lboost_iostreams -lshp -pthread -pagezero_size 10000 -image_base 100000000
ld: warning: Linking with PIE, -image_base will be ignored
Ah, interesting. It appears to be a LuaJIT thing. If I build with plain Lua it's fine. If I build with LuaJIT then it's killed.
Try uninstalling LuaJIT and installing plain Lua and see if that works for you.
Yes, deleting it helped brew uninstall --ignore-dependencies luajit
Is it possible to pass a build parameter that disables LuaJIT without deleting it?
I think the fix will be altering the LDFLAGS in the Makefile. I'll take a look at that.
I updated the source code, installed luajit again and the problem is no longer there. Thanks!
That's great!
(For background: LuaJIT used to require a particular linking option on MacOS. With 2.1 it no longer does, so I've added a version check.)
Installed using this guide: https://github.com/systemed/tilemaker/blob/master/docs/INSTALL.md#macos
macOS: 14.4 Apple M1 Pro RAM: 16GB