Skip to content

Commit

Permalink
update lldpd
Browse files Browse the repository at this point in the history
- update lldpd to v1.0.18
- remove obsolete privilege and PLIST file
- enable all built in protocols
- build binaries into bin folder (instead of sbin)
- use quadratic shape for logo
- use group synocommunity (for DSM 7 compatibility)
- user SERVICE_USER = auto (other values are not supported)
  • Loading branch information
hgy59 committed Nov 25, 2024
1 parent bfc19fa commit cde9e9f
Show file tree
Hide file tree
Showing 8 changed files with 35 additions and 61 deletions.
20 changes: 15 additions & 5 deletions cross/lldpd/Makefile
Original file line number Diff line number Diff line change
@@ -1,16 +1,26 @@
PKG_NAME = lldpd
PKG_VERS = 1.0.10
PKG_VERS = 1.0.18
PKG_EXT = tar.gz
PKG_DIST_NAME = $(PKG_NAME)-$(PKG_VERS).$(PKG_EXT)
PKG_DIST_SITE = https://media.luffy.cx/files/lldpd
PKG_DIST_SITE = https://github.com/lldpd/lldpd/releases/download/$(PKG_VERS)
PKG_DIR = $(PKG_NAME)-$(PKG_VERS)

DEPENDS =
DEPENDS = cross/libcap cross/libxml2 cross/readline

HOMEPAGE = https://lldpd.github.io
COMMENT = lldpd is a 802.1AB implementation (LLDP) to help you locate neighbors of all your equipments
COMMENT = lldpd is a 802.1AB implementation (LLDP) to help you locate neighbors of all your equipments.
LICENSE = ISC

GNU_CONFIGURE = 1
CONFIGURE_ARGS = --enable-privsep --disable-cdp --disable-fdp --disable-edp --disable-sonmp --with-privsep-user=sc-lldpd --with-privsep-group=lldpd
CONFIGURE_ARGS = --disable-static
CONFIGURE_ARGS += --disable-doxygen-doc --disable-doxygen-html --disable-doxygen-pdf
CONFIGURE_ARGS += --with-readline
# build service and cli tools into bin instead of sbin folder
CONFIGURE_ARGS += --sbindir=$(INSTALL_PREFIX)/bin
# Enable Privilege separation and specify user:group as sc-lldpd:synocommunity
CONFIGURE_ARGS += --enable-privsep --with-privsep-user=sc-lldpd --with-privsep-group=synocommunity
CONFIGURE_ARGS += --runstatedir=$(INSTALL_PREFIX_VAR)

ADDITIONAL_CFLAGS = -O2

include ../../mk/spksrc.cross-cc.mk
9 changes: 5 additions & 4 deletions cross/lldpd/PLIST
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
bin:bin/lldpcli
lnk:bin/lldpctl
bin:bin/lldpd
lnk:lib/liblldpctl.so
lnk:lib/liblldpctl.so.4
lib:lib/liblldpctl.so.4.9.0
bin:sbin/lldpcli
bin:sbin/lldpctl
bin:sbin/lldpd
lib:lib/liblldpctl.so.4.9.1
6 changes: 3 additions & 3 deletions cross/lldpd/digests
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
lldpd-1.0.10.tar.gz SHA1 feb556445811c61df81d3dfe8818cda59a371247
lldpd-1.0.10.tar.gz SHA256 445b2d76037ef3ebd03d40e1fc1f29ef08102faa3a09fe846b952797c8bc7722
lldpd-1.0.10.tar.gz MD5 233e9a2e12d319bc362cba2ed74076b4
lldpd-1.0.18.tar.gz SHA1 49d21ad64809d146930977d7327d3c4ada4d0549
lldpd-1.0.18.tar.gz SHA256 38cd319aa02ab61d9a2ad130e22f906795ccca9ac73a0a0d9dac19ca99a8a870
lldpd-1.0.18.tar.gz MD5 53e8db980c97197547fd3fe9ed2e6d50
22 changes: 7 additions & 15 deletions spk/lldpd/Makefile
Original file line number Diff line number Diff line change
@@ -1,31 +1,23 @@
SPK_NAME = lldpd
SPK_VERS = 1.0.10
SPK_VERS = 1.0.18
SPK_REV = 1
SPK_ICON = src/lldpd.png

DEPENDS = cross/$(SPK_NAME)
DEPENDS = cross/lldpd

MAINTAINER = SynoCommunity
DESCRIPTION = LLDP (Link Layer Discovery Protocol) is an industry standard protocol designed to supplant proprietary Link-Layer protocols such as Extreme's EDP (Extreme Discovery Protocol) and CDP (Cisco Discovery Protocol). The goal of LLDP is to provide an inter-vendor compatible mechanism to deliver Link-Layer notifications to adjacent network devices.
DESCRIPTION = LLDP \(Link Layer Discovery Protocol\) is an industry standard protocol designed to supplant proprietary Link-Layer protocols such as Extreme's EDP \(Extreme Discovery Protocol\) and CDP \(Cisco Discovery Protocol\). The goal of LLDP is to provide an inter-vendor compatible mechanism to deliver Link-Layer notifications to adjacent network devices.
DISPLAY_NAME = lldpd
CHANGELOG = "Initial release"
CHANGELOG = "Initial package release."

HOMEPAGE = https://lldpd.github.io
LICENSE = ISC

CONF_DIR = src/conf
SERVICE_USER = sc-lldpd
STARTABLE = yes

POST_STRIP_TARGET = lldpd_extra_install
SERVICE_USER = auto
STARTABLE = yes

SERVICE_SETUP = src/service-setup.sh

SPK_COMMANDS = sbin/lldpcli sbin/lldpctl
SPK_COMMANDS = bin/lldpcli bin/lldpctl

include ../../mk/spksrc.spk.mk

.PHONY: lldpd_extra_install
lldpd_extra_install:
install -m 755 -d $(STAGING_DIR)/var
install -m 755 -d $(STAGING_DIR)/var/run
Empty file removed spk/lldpd/PLIST
Empty file.
31 changes: 0 additions & 31 deletions spk/lldpd/src/conf/privilege

This file was deleted.

Binary file modified spk/lldpd/src/lldpd.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 5 additions & 3 deletions spk/lldpd/src/service-setup.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
PATH="${SYNOPKG_PKGDEST}/bin:${PATH}"
LLDPD="${SYNOPKG_PKGDEST}/sbin/lldpd"
SERVICE_COMMAND="${LLDPD} -p ${PID_FILE}"

# required for DSM < 7 only:
GROUP=synocommunity

SERVICE_COMMAND="${SYNOPKG_PKGDEST}/bin/lldpd -p ${PID_FILE}"

0 comments on commit cde9e9f

Please sign in to comment.