diff options
| author | Johannes Schneider <johannes.schneider@leica-geosystems.com> | 2025-02-13 12:42:03 +0100 |
|---|---|---|
| committer | Steve Sakoman <steve@sakoman.com> | 2025-02-21 06:25:06 -0800 |
| commit | 656d4b9b4241d825c87c48295036ae0b3ded56e7 (patch) | |
| tree | a4fd09c31c654ee20197bcafc7b6ff25aee23b90 | |
| parent | b7eed581007fdb31451e36eb13750bc7d3bb56c4 (diff) | |
| download | poky-656d4b9b4241d825c87c48295036ae0b3ded56e7.tar.gz | |
ppp: Revert lock path to /var/lock
ppp version 2.5.0 fails to run properly if an expected /run/pppd/lock
directory does not exist, which is not usually created in a yocto
built OS.
Backport the patch from upstream version 2.5.1 that fixes the issue by
reverting back to /var/lock.
The related github issue upstream was:
"lock directory moved in ppp-2.5.0 #419" [1]
Link: https://github.com/ppp-project/ppp/issues/419
(From OE-Core rev: 0869eb50e39c567cc1d50db4eb287f02866196cf)
Signed-off-by: Johannes Schneider <johannes.schneider@leica-geosystems.com>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
| -rw-r--r-- | meta/recipes-connectivity/ppp/ppp/0001-Revert-lock-path-to-var-lock-435.patch | 63 | ||||
| -rw-r--r-- | meta/recipes-connectivity/ppp/ppp_2.5.0.bb | 1 |
2 files changed, 64 insertions, 0 deletions
diff --git a/meta/recipes-connectivity/ppp/ppp/0001-Revert-lock-path-to-var-lock-435.patch b/meta/recipes-connectivity/ppp/ppp/0001-Revert-lock-path-to-var-lock-435.patch new file mode 100644 index 0000000000..573eb413b0 --- /dev/null +++ b/meta/recipes-connectivity/ppp/ppp/0001-Revert-lock-path-to-var-lock-435.patch | |||
| @@ -0,0 +1,63 @@ | |||
| 1 | From 99cbf5e269994482edaf64624be8b1c806f9587c Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Dominique Martinet <asmadeus@codewreck.org> | ||
| 3 | Date: Tue, 10 Oct 2023 10:05:50 +0900 | ||
| 4 | Subject: [PATCH] Revert lock path to /var/lock (#435) | ||
| 5 | |||
| 6 | lock dir changed on linux from /var/lock to /run/pppd/lock with | ||
| 7 | pppd-2.5.0, which makes pppd fail to start if the distribution does not | ||
| 8 | pre-create the directory. | ||
| 9 | |||
| 10 | This reverts it back to /var/lock. | ||
| 11 | |||
| 12 | The paths for other OS should be identical as LOCALSTATEDIR should be | ||
| 13 | /var, but also revert them back as well just in case. | ||
| 14 | Since the variable is no longer used remove it from makefiles. | ||
| 15 | |||
| 16 | Fixes: 66a8c74c3f73 ("Let ./configure control the paths for pppd") | ||
| 17 | Fixes: #419 | ||
| 18 | |||
| 19 | Signed-off-by: Dominique Martinet <dominique.martinet@atmark-techno.com> | ||
| 20 | Co-authored-by: Dominique Martinet <dominique.martinet@atmark-techno.com> | ||
| 21 | |||
| 22 | Upstream-Status: Backport [https://github.com/ppp-project/ppp/commit/99cbf5e269994482edaf64624be8b1c806f9587c] | ||
| 23 | --- | ||
| 24 | pppd/Makefile.am | 2 +- | ||
| 25 | pppd/pathnames.h | 6 +++--- | ||
| 26 | 2 files changed, 4 insertions(+), 4 deletions(-) | ||
| 27 | |||
| 28 | diff --git a/pppd/Makefile.am b/pppd/Makefile.am | ||
| 29 | index e5bedf2..7cb3005 100644 | ||
| 30 | --- a/pppd/Makefile.am | ||
| 31 | +++ b/pppd/Makefile.am | ||
| 32 | @@ -83,7 +83,7 @@ pppd_SOURCES = \ | ||
| 33 | upap.c \ | ||
| 34 | utils.c | ||
| 35 | |||
| 36 | -pppd_CPPFLAGS = -DSYSCONFDIR=\"${sysconfdir}\" -DLOCALSTATEDIR=\"${localstatedir}\" -DPPPD_RUNTIME_DIR='"@PPPD_RUNTIME_DIR@"' -DPPPD_LOGFILE_DIR='"@PPPD_LOGFILE_DIR@"' | ||
| 37 | +pppd_CPPFLAGS = -DSYSCONFDIR=\"${sysconfdir}\" -DPPPD_RUNTIME_DIR='"@PPPD_RUNTIME_DIR@"' -DPPPD_LOGFILE_DIR='"@PPPD_LOGFILE_DIR@"' | ||
| 38 | pppd_LDFLAGS = | ||
| 39 | pppd_LIBS = | ||
| 40 | |||
| 41 | diff --git a/pppd/pathnames.h b/pppd/pathnames.h | ||
| 42 | index de2fb68..12609a9 100644 | ||
| 43 | --- a/pppd/pathnames.h | ||
| 44 | +++ b/pppd/pathnames.h | ||
| 45 | @@ -120,12 +120,12 @@ | ||
| 46 | #define PPP_PATH_PPPDB PPP_PATH_VARRUN "/pppd2.tdb" | ||
| 47 | |||
| 48 | #ifdef __linux__ | ||
| 49 | -#define PPP_PATH_LOCKDIR PPP_PATH_VARRUN "/lock" | ||
| 50 | +#define PPP_PATH_LOCKDIR "/var/lock" | ||
| 51 | #else | ||
| 52 | #ifdef SVR4 | ||
| 53 | -#define PPP_PATH_LOCKDIR LOCALSTATEDIR "/spool/locks" | ||
| 54 | +#define PPP_PATH_LOCKDIR "/var/spool/locks" | ||
| 55 | #else | ||
| 56 | -#define PPP_PATH_LOCKDIR LOCALSTATEDIR "/spool/lock" | ||
| 57 | +#define PPP_PATH_LOCKDIR "/var/spool/lock" | ||
| 58 | #endif | ||
| 59 | #endif | ||
| 60 | |||
| 61 | -- | ||
| 62 | 2.43.0 | ||
| 63 | |||
diff --git a/meta/recipes-connectivity/ppp/ppp_2.5.0.bb b/meta/recipes-connectivity/ppp/ppp_2.5.0.bb index 5f0c75de83..badf22db97 100644 --- a/meta/recipes-connectivity/ppp/ppp_2.5.0.bb +++ b/meta/recipes-connectivity/ppp/ppp_2.5.0.bb | |||
| @@ -23,6 +23,7 @@ SRC_URI = "https://download.samba.org/pub/${BPN}/${BP}.tar.gz \ | |||
| 23 | file://ppp_on_boot \ | 23 | file://ppp_on_boot \ |
| 24 | file://provider \ | 24 | file://provider \ |
| 25 | file://ppp@.service \ | 25 | file://ppp@.service \ |
| 26 | file://0001-Revert-lock-path-to-var-lock-435.patch \ | ||
| 26 | " | 27 | " |
| 27 | 28 | ||
| 28 | SRC_URI[sha256sum] = "5cae0e8075f8a1755f16ca290eb44e6b3545d3f292af4da65ecffe897de636ff" | 29 | SRC_URI[sha256sum] = "5cae0e8075f8a1755f16ca290eb44e6b3545d3f292af4da65ecffe897de636ff" |
