From 9a14a1fb001e17fc8d843a1c6e41869d0ddb1212 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Carlos=20=C3=81lvaro?= Date: Thu, 6 Jul 2023 21:04:40 +0200 Subject: [PATCH] feat: Add support for Apple Silicon --- Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 401b8cf..df5c0da 100644 --- a/Makefile +++ b/Makefile @@ -1,13 +1,14 @@ VERSION = 2 LIBRARY_NAME = pam_watchid.so DESTINATION = /usr/local/lib/pam -TARGET = x86_64-apple-macosx10.15 +TARGET = $(shell clang -dumpmachine) all: - swiftc watchid-pam-extension.swift -o $(LIBRARY_NAME) -target $(TARGET) -emit-library + swiftc watchid-pam-extension.swift -O -Ounchecked -gnone -o $(LIBRARY_NAME) -target $(TARGET) -emit-library install: all mkdir -p $(DESTINATION) cp $(LIBRARY_NAME) $(DESTINATION)/$(LIBRARY_NAME).$(VERSION) chmod 444 $(DESTINATION)/$(LIBRARY_NAME).$(VERSION) chown root:wheel $(DESTINATION)/$(LIBRARY_NAME).$(VERSION) +