diff --git a/Makefile b/Makefile index 02e5e8c9f..39bca50d4 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,9 @@ -PREFIX ?= $(DESTDIR)/usr -BINDIR ?= $(PREFIX)/bin -LIBDIR ?= $(PREFIX)/lib/x86_64-linux-gnu +LBITS := $(shell getconf LONG_BIT) +ifeq ($(LBITS),64) +LIBDIR ?= libs/x86_64 +else +LIBDIR ?= libs/x86 +endif CFLAGS ?= -g -Wall -Werror -Wshadow -O2 -pipe -std=gnu11 LDLIBS=$(LIBDIR)/libsepol.a diff --git a/libs/libsepol-x86_64.a b/libs/libsepol-x86_64.a deleted file mode 100644 index 621b6ba40..000000000 Binary files a/libs/libsepol-x86_64.a and /dev/null differ diff --git a/libs/libsepol-x86.a b/libs/x86/libsepol.a similarity index 100% rename from libs/libsepol-x86.a rename to libs/x86/libsepol.a diff --git a/libs/x86_64/libsepol.a b/libs/x86_64/libsepol.a new file mode 100644 index 000000000..0c2e87468 Binary files /dev/null and b/libs/x86_64/libsepol.a differ