Remove Makefiles (have been deprecated a while)
This commit is contained in:
parent
30097cd4cb
commit
802d4603b2
|
|
@ -52,17 +52,6 @@ jobs:
|
||||||
- uses: ./.github/actions/install-ubuntu
|
- uses: ./.github/actions/install-ubuntu
|
||||||
- uses: ./.github/actions/build
|
- uses: ./.github/actions/build
|
||||||
|
|
||||||
ubuntu22-make:
|
|
||||||
runs-on: ubuntu-22.04
|
|
||||||
env:
|
|
||||||
CC: gcc
|
|
||||||
CXX: g++
|
|
||||||
CXXFLAGS: -Werror -Wall -pedantic
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
- uses: ./.github/actions/install-ubuntu
|
|
||||||
- run: make -C osmpbf
|
|
||||||
|
|
||||||
macos:
|
macos:
|
||||||
runs-on: macos-latest
|
runs-on: macos-latest
|
||||||
env:
|
env:
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
https://github.com/openstreetmap/OSM-binary
|
https://github.com/openstreetmap/OSM-binary
|
||||||
|
|
||||||
Osmpbf is a Java/C library to read and write OpenStreetMap PBF files.
|
Osmpbf is a Java/C++ library to read and write OpenStreetMap PBF files.
|
||||||
PBF (Protocol buffer Binary Format) is a binary file format for OpenStreetMap
|
PBF (Protocol buffer Binary Format) is a binary file format for OpenStreetMap
|
||||||
data that uses Google Protocol Buffers as low-level storage.
|
data that uses Google Protocol Buffers as low-level storage.
|
||||||
|
|
||||||
|
|
@ -55,9 +55,6 @@ This build is also used for Debian packaging.
|
||||||
|
|
||||||
## C++ Version
|
## C++ Version
|
||||||
|
|
||||||
(Earlier versions used Makefiles for building. Please switch to the CMake-based
|
|
||||||
build, the Makefiles are deprecated and will be removed in a future version.)
|
|
||||||
|
|
||||||
To compile:
|
To compile:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
|
|
|
||||||
|
|
@ -1,44 +0,0 @@
|
||||||
|
|
||||||
# these default settings can be overridden by setting environment variables
|
|
||||||
PREFIX ?= /usr/local
|
|
||||||
LIBDIR ?= $(PREFIX)/lib
|
|
||||||
CXX ?= g++
|
|
||||||
CXXFLAGS ?= -O3
|
|
||||||
AR ?= ar
|
|
||||||
PROTOC ?= protoc
|
|
||||||
SONAME ?= libosmpbf.so.1
|
|
||||||
VERSION ?= 1.5.0
|
|
||||||
|
|
||||||
CXXFLAGS += -Wall -Wextra -pedantic -Wredundant-decls -Wdisabled-optimization -Wctor-dtor-privacy -Wnon-virtual-dtor -Woverloaded-virtual -Wsign-promo -Wno-long-long
|
|
||||||
|
|
||||||
.PHONY: clean install
|
|
||||||
|
|
||||||
all: libosmpbf.a libosmpbf.so ../include/osmpbf/fileformat.pb.h ../include/osmpbf/osmformat.pb.h
|
|
||||||
|
|
||||||
libosmpbf.a: fileformat.pb.o osmformat.pb.o
|
|
||||||
$(AR) -cr $@ fileformat.pb.o osmformat.pb.o
|
|
||||||
|
|
||||||
libosmpbf.so: fileformat.pb.o osmformat.pb.o
|
|
||||||
$(CXX) $(CPPFLAGS) $(LDFLAGS) -shared -Wl,-soname,$(SONAME) -o $@ fileformat.pb.o osmformat.pb.o
|
|
||||||
|
|
||||||
%.pb.o: %.pb.cc
|
|
||||||
$(CXX) $(CPPFLAGS) $(CXXFLAGS) -fPIC -c -o $@ $<
|
|
||||||
|
|
||||||
%.pb.cc ../include/osmpbf/%.pb.h: %.proto
|
|
||||||
$(PROTOC) --proto_path=. --cpp_out=. $<
|
|
||||||
cp -v $(subst .proto,.pb.h,$<) ../include/osmpbf/
|
|
||||||
|
|
||||||
install:
|
|
||||||
install -m 755 -d $(DESTDIR)$(LIBDIR)
|
|
||||||
install -m 644 libosmpbf.a $(DESTDIR)$(LIBDIR)
|
|
||||||
install -m 755 libosmpbf.so $(DESTDIR)$(LIBDIR)/libosmpbf.so.$(VERSION)
|
|
||||||
ln -s libosmpbf.so.$(VERSION) $(DESTDIR)$(LIBDIR)/$(SONAME)
|
|
||||||
ln -s libosmpbf.so.$(VERSION) $(DESTDIR)$(LIBDIR)/libosmpbf.so
|
|
||||||
install -m 755 -d $(DESTDIR)$(PREFIX)/include/osmpbf
|
|
||||||
install -m 644 ../include/osmpbf/osmpbf.h $(DESTDIR)$(PREFIX)/include/osmpbf
|
|
||||||
install -m 644 ../include/osmpbf/fileformat.pb.h $(DESTDIR)$(PREFIX)/include/osmpbf
|
|
||||||
install -m 644 ../include/osmpbf/osmformat.pb.h $(DESTDIR)$(PREFIX)/include/osmpbf
|
|
||||||
|
|
||||||
clean:
|
|
||||||
rm -f *.pb.h *.pb.cc *.pb.o libosmpbf.a
|
|
||||||
|
|
||||||
|
|
@ -1,23 +0,0 @@
|
||||||
|
|
||||||
# these default settings can be overridden by setting environment variables
|
|
||||||
PREFIX ?= /usr/local
|
|
||||||
CXX ?= g++
|
|
||||||
CXXFLAGS ?= -g
|
|
||||||
|
|
||||||
CXXFLAGS += -I../include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Wall -Wextra -pedantic -Wredundant-decls -Wdisabled-optimization -Wctor-dtor-privacy -Wnon-virtual-dtor -Woverloaded-virtual -Wsign-promo -Wno-long-long
|
|
||||||
LDFLAGS += -L../osmpbf -pthread -lz -lprotobuf -losmpbf
|
|
||||||
|
|
||||||
.PHONY: clean install
|
|
||||||
|
|
||||||
all: osmpbf-outline
|
|
||||||
|
|
||||||
osmpbf-outline: osmpbf-outline.cpp
|
|
||||||
$(CXX) $(CPPFLAGS) $(CXXFLAGS) -o $@ $< $(LDFLAGS)
|
|
||||||
|
|
||||||
install:
|
|
||||||
install -m 755 -d $(DESTDIR)$(PREFIX)/bin
|
|
||||||
install -m 755 -s osmpbf-outline $(DESTDIR)$(PREFIX)/bin
|
|
||||||
|
|
||||||
clean:
|
|
||||||
rm -f osmpbf-outline
|
|
||||||
|
|
||||||
Loading…
Reference in New Issue