diff options
| -rw-r--r-- | meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/phc2sys@.service.in (renamed from meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/phc2sys@.service) | 2 | ||||
| -rw-r--r-- | meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/ptp4l@.service.in (renamed from meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/ptp4l@.service) | 2 | ||||
| -rw-r--r-- | meta-oe/recipes-connectivity/linuxptp/linuxptp_4.1.bb | 15 |
3 files changed, 12 insertions, 7 deletions
diff --git a/meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/phc2sys@.service b/meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/phc2sys@.service.in index dd2512bdca..f66dd2d010 100644 --- a/meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/phc2sys@.service +++ b/meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/phc2sys@.service.in | |||
| @@ -7,7 +7,7 @@ Before=time-sync.target | |||
| 7 | 7 | ||
| 8 | [Service] | 8 | [Service] |
| 9 | Type=simple | 9 | Type=simple |
| 10 | ExecStart=/usr/sbin/phc2sys -w -s %I | 10 | ExecStart=@SBINDIR@/phc2sys -w -s %I |
| 11 | 11 | ||
| 12 | [Install] | 12 | [Install] |
| 13 | WantedBy=multi-user.target | 13 | WantedBy=multi-user.target |
diff --git a/meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/ptp4l@.service b/meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/ptp4l@.service.in index 1bad2d72df..2502181412 100644 --- a/meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/ptp4l@.service +++ b/meta-oe/recipes-connectivity/linuxptp/linuxptp/systemd/ptp4l@.service.in | |||
| @@ -5,7 +5,7 @@ After=sys-subsystem-net-devices-%i.device | |||
| 5 | 5 | ||
| 6 | [Service] | 6 | [Service] |
| 7 | Type=simple | 7 | Type=simple |
| 8 | ExecStart=/usr/sbin/ptp4l -f /etc/linuxptp/ptp4l.conf -i %I | 8 | ExecStart=@SBINDIR@/ptp4l -f @SYSCONFDIR@/linuxptp/ptp4l.conf -i %I |
| 9 | 9 | ||
| 10 | [Install] | 10 | [Install] |
| 11 | WantedBy=multi-user.target | 11 | WantedBy=multi-user.target |
diff --git a/meta-oe/recipes-connectivity/linuxptp/linuxptp_4.1.bb b/meta-oe/recipes-connectivity/linuxptp/linuxptp_4.1.bb index a92434385d..9a5c9b5204 100644 --- a/meta-oe/recipes-connectivity/linuxptp/linuxptp_4.1.bb +++ b/meta-oe/recipes-connectivity/linuxptp/linuxptp_4.1.bb | |||
| @@ -10,8 +10,8 @@ LINUXPTP_SRC_URI = "http://sourceforge.net/projects/linuxptp" | |||
| 10 | SRC_URI = "${LINUXPTP_SRC_URI}/files/v4.1/linuxptp-${PV}.tgz \ | 10 | SRC_URI = "${LINUXPTP_SRC_URI}/files/v4.1/linuxptp-${PV}.tgz \ |
| 11 | file://0001-include-string.h-for-strncpy.patch \ | 11 | file://0001-include-string.h-for-strncpy.patch \ |
| 12 | file://0002-linuxptp-Use-CC-in-incdefs.sh.patch \ | 12 | file://0002-linuxptp-Use-CC-in-incdefs.sh.patch \ |
| 13 | file://systemd/phc2sys@.service \ | 13 | file://systemd/phc2sys@.service.in \ |
| 14 | file://systemd/ptp4l@.service \ | 14 | file://systemd/ptp4l@.service.in \ |
| 15 | " | 15 | " |
| 16 | 16 | ||
| 17 | SRC_URI[md5sum] = "1db8699fc155965341759be5e5aad938" | 17 | SRC_URI[md5sum] = "1db8699fc155965341759be5e5aad938" |
| @@ -22,14 +22,15 @@ inherit systemd | |||
| 22 | UPSTREAM_CHECK_URI = "${LINUXPTP_SRC_URI}/files/" | 22 | UPSTREAM_CHECK_URI = "${LINUXPTP_SRC_URI}/files/" |
| 23 | UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)/" | 23 | UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)/" |
| 24 | 24 | ||
| 25 | EXTRA_OEMAKE = "CC='${CC}' EXTRA_CFLAGS='${CFLAGS}' mandir='${mandir}'" | 25 | EXTRA_OEMAKE = "CC='${CC}' EXTRA_CFLAGS='${CFLAGS}' mandir='${mandir}' \ |
| 26 | sbindir='${sbindir}'" | ||
| 26 | 27 | ||
| 27 | export KBUILD_OUTPUT="${RECIPE_SYSROOT}" | 28 | export KBUILD_OUTPUT="${RECIPE_SYSROOT}" |
| 28 | 29 | ||
| 29 | LINUXPTP_SYSTEMD_SERVICES = "phc2sys@.service ptp4l@.service" | 30 | LINUXPTP_SYSTEMD_SERVICES = "phc2sys@.service ptp4l@.service" |
| 30 | 31 | ||
| 31 | do_install() { | 32 | do_install() { |
| 32 | oe_runmake install DESTDIR=${D} prefix=${prefix} | 33 | oe_runmake install DESTDIR=${D} |
| 33 | 34 | ||
| 34 | # Install example configs from source tree | 35 | # Install example configs from source tree |
| 35 | install -d ${D}${docdir}/${PN} | 36 | install -d ${D}${docdir}/${PN} |
| @@ -44,7 +45,11 @@ do_install() { | |||
| 44 | # Install systemd services | 45 | # Install systemd services |
| 45 | install -d ${D}/${systemd_unitdir}/system/ | 46 | install -d ${D}/${systemd_unitdir}/system/ |
| 46 | for service in ${LINUXPTP_SYSTEMD_SERVICES}; do | 47 | for service in ${LINUXPTP_SYSTEMD_SERVICES}; do |
| 47 | install -m 644 ${WORKDIR}/systemd/$service \ | 48 | sed -i -e 's,@SBINDIR@,${sbindir},g' \ |
| 49 | ${WORKDIR}/systemd/$service.in | ||
| 50 | sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' \ | ||
| 51 | ${WORKDIR}/systemd/$service.in | ||
| 52 | install -m 644 ${WORKDIR}/systemd/$service.in \ | ||
| 48 | ${D}/${systemd_unitdir}/system/$service | 53 | ${D}/${systemd_unitdir}/system/$service |
| 49 | done | 54 | done |
| 50 | } | 55 | } |
