Skip to content

Small improvements + PKGBUILD for archlinux #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@ OBJFILES = wsdd2.o wsd.o llmnr.o
HEADERS = wsdd.h wsd.h

INSTALLPREFIX ?= $(PREFIX)/usr
SBININSTALLDIR = $(INSTALLPREFIX)/sbin
SBININSTALLDIR = $(INSTALLPREFIX)/bin
MANINSTALLDIR = $(INSTALLPREFIX)/share/man
LIBINSTALLDIR = $(INSTALLPREFIX)/lib

all: wsdd2

Expand All @@ -23,8 +24,8 @@ install: wsdd2
install wsdd2 $(DESTDIR)/$(SBININSTALLDIR)
install -d $(DESTDIR)/$(MANINSTALLDIR)/man8
install wsdd2.8 $(DESTDIR)/$(MANINSTALLDIR)/man8/wsdd2.8
install -d $(DESTDIR)/lib/systemd/system
install -m 0644 wsdd2.service $(DESTDIR)/lib/systemd/system
install -d $(DESTDIR)/$(LIBINSTALLDIR)/systemd/system
install -m 0644 wsdd2.service $(DESTDIR)/$(LIBINSTALLDIR)/systemd/system

clean:
rm -f wsdd2 $(OBJFILES)
25 changes: 25 additions & 0 deletions PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
pkgname=wsdd2
pkgver=1.8
pkgrel=2
url=""
pkgdesc="WSDD and LLMNR daemon"
arch=('x86_64' 'armv7h')
license=('GPL3')
sources=('wsd.c'
'wsdd2.8'
'wsdd.h'
'llmnr.c'
'Makefile'
'wsdd2.c'
'wsdd2.service'
'wsd.h')

build() {
cd ..
make
}

package() {
cd ..
make DESTDIR="$pkgdir/" install
}
7 changes: 6 additions & 1 deletion wsdd2.service
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
[Unit]
Description=WSD/LLMNR Discovery/Name Service Daemon
PartOf=smbd.service
PartOf=smb.service

[Service]
DynamicUser=true
PrivateTmp=true
PrivateDevices=true
ProtectSystem=strict
ProtectHome=true
ExecStart=/usr/sbin/wsdd2
ExecReload=/bin/kill -HUP $MAINPID
Restart=on-failure