Skip to content

Commit

Permalink
add freebsd support
Browse files Browse the repository at this point in the history
  • Loading branch information
jovanlanik committed May 6, 2023
1 parent 0019637 commit aeb50df
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
12 changes: 9 additions & 3 deletions makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ MINOR_VERSION := 0
MICRO_VERSION := 1

PREFIX = /usr/local
SYSCONFDIR = $(PREFIX)/etc

ifeq '$(shell uname)' 'Linux'
SYSCONFDIR = /etc
endif

INSTALL = install

LIBS := wayland-client gtk+-wayland-3.0 gtk-layer-shell-0 gmodule-export-2.0
Expand Down Expand Up @@ -54,16 +60,16 @@ install-bin:
$(INSTALL) $(NAME) $(DESTDIR)$(PREFIX)/bin/$(NAME)

install-data:
$(INSTALL) -d $(DESTDIR)/etc/pam.d
$(INSTALL) -m644 pam/$(NAME) $(DESTDIR)/etc/pam.d/$(NAME)
$(INSTALL) -d $(DESTDIR)$(SYSCONFDIR)/pam.d
$(INSTALL) -m644 pam/$(NAME) $(DESTDIR)$(SYSCONFDIR)/pam.d/$(NAME)
$(INSTALL) -d $(DESTDIR)$(PREFIX)/share/man/man1
$(INSTALL) -m644 $(NAME).1 $(DESTDIR)$(PREFIX)/share/man/man1/$(NAME).1

install: install-bin install-data

uninstall:
rm -f $(DESTDIR)$(PREFIX)/bin/$(NAME)
rm -f $(DESTDIR)/etc/pam.d/$(NAME)
rm -f $(DESTDIR)$(SYSCONFDIR)/pam.d/$(NAME)
rm -r $(DESTDIR)$(PREFIX)/share/man/man1/$(NAME).1

$(NAME): $(OBJ)
Expand Down
2 changes: 1 addition & 1 deletion src/source.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// gtklock
// Copyright (c) 2022 Kenny Levinsen, Jovan Lanik

#define _POSIX_C_SOURCE
#define _POSIX_C_SOURCE 200809L

#include <assert.h>
#include <signal.h>
Expand Down

0 comments on commit aeb50df

Please sign in to comment.