Merge branch 'entidi/ethercat-proper-systemd-support' into stable-1.5
This commit is contained in:
commit
4164e10ccd
|
|
@ -33,6 +33,7 @@ ethercat.spec
|
|||
examples/dc_user/ec_dc_user_example
|
||||
examples/user/ec_user_example
|
||||
lib/libethercat.la
|
||||
lib/libethercat.pc
|
||||
libtool
|
||||
master/*.o.d
|
||||
script/ethercat.service
|
||||
|
|
|
|||
|
|
@ -0,0 +1,15 @@
|
|||
build:
|
||||
stage: build
|
||||
|
||||
before_script:
|
||||
- apt update
|
||||
- apt install -y linux-source linux-headers-4.19.0-16-all
|
||||
|
||||
script:
|
||||
- ./bootstrap
|
||||
- ./configure --with-linux-dir=/usr/src/linux-headers-4.19.0-16-amd64 --disable-8139too
|
||||
- make -j8 all modules
|
||||
|
||||
include:
|
||||
- template: 'Workflows/MergeRequest-Pipelines.gitlab-ci.yml'
|
||||
|
||||
2
INSTALL
2
INSTALL
|
|
@ -18,7 +18,7 @@ section of the documentation available from http://etherlab.org/en/ethercat.
|
|||
|
||||
For the impatient: The procedure mainly consists of calling
|
||||
|
||||
$ ./boostrap # to create the configure script, if downloaded from the repo
|
||||
$ ./bootstrap # to create the configure script, if downloaded from the repo
|
||||
|
||||
$ ./configure
|
||||
$ make all modules
|
||||
|
|
|
|||
|
|
@ -29,6 +29,9 @@
|
|||
|
||||
ACLOCAL_AMFLAGS = -I m4
|
||||
|
||||
AM_DISTCHECK_CONFIGURE_FLAGS = \
|
||||
--with-systemdsystemunitdir=$$dc_install_base/$(systemdsystemunitdir)
|
||||
|
||||
SUBDIRS = \
|
||||
include \
|
||||
script
|
||||
|
|
|
|||
32
configure.ac
32
configure.ac
|
|
@ -45,6 +45,8 @@ AM_INIT_AUTOMAKE([-Wall -Werror dist-bzip2 subdir-objects])
|
|||
AC_CONFIG_HEADERS([config.h])
|
||||
AC_CONFIG_SRCDIR([config.h.in])
|
||||
AC_CONFIG_MACRO_DIR([m4])
|
||||
PKG_PROG_PKG_CONFIG
|
||||
PKG_INSTALLDIR()
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
# Global
|
||||
|
|
@ -1077,6 +1079,35 @@ else
|
|||
AC_MSG_RESULT([no])
|
||||
fi
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
# systemd service support
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
AC_ARG_WITH([systemdsystemunitdir],
|
||||
AS_HELP_STRING([--with-systemdsystemunitdir=DIR],
|
||||
[Directory for systemd service files]),
|
||||
,
|
||||
[with_systemdsystemunitdir=auto]
|
||||
)
|
||||
|
||||
case "${with_systemdsystemunitdir}" in
|
||||
yes)
|
||||
with_systemdsystemunitdir=$($PKG_CONFIG --variable=systemdsystemunitdir systemd)
|
||||
if test "x$with_systemdsystemunitdir" = "x"; then
|
||||
AC_MSG_ERROR([systemd support requested but pkg-config unable to query systemd package])
|
||||
fi
|
||||
;;
|
||||
no)
|
||||
with_systemdsystemunitdir=
|
||||
;;
|
||||
auto)
|
||||
with_systemdsystemunitdir=$($PKG_CONFIG --variable=systemdsystemunitdir systemd)
|
||||
;;
|
||||
esac
|
||||
|
||||
AM_CONDITIONAL(HAVE_SYSTEMD, test "x$with_systemdsystemunitdir" != "x")
|
||||
AC_SUBST(systemdsystemunitdir,[$with_systemdsystemunitdir])
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
AC_CONFIG_FILES([
|
||||
|
|
@ -1112,6 +1143,7 @@ AC_CONFIG_FILES([
|
|||
examples/xenomai_posix/Makefile
|
||||
include/Makefile
|
||||
lib/Makefile
|
||||
lib/libethercat.pc
|
||||
m4/Makefile
|
||||
master/Kbuild
|
||||
master/Makefile
|
||||
|
|
|
|||
|
|
@ -54,28 +54,37 @@ $(EXT_FILES): $(ETHERCAT_CMD)
|
|||
pdf: $(EXT_FILES)
|
||||
$(MAKE) -C images
|
||||
$(MAKE) -C graphs
|
||||
|
||||
# compile twice to update the table of contents
|
||||
pdflatex $(LATEX_OPTIONS) $(FILE)
|
||||
pdflatex $(LATEX_OPTIONS) $(FILE)
|
||||
|
||||
pdflatex $(LATEX_OPTIONS) $(FILE)_fr
|
||||
pdflatex $(LATEX_OPTIONS) $(FILE)_fr
|
||||
|
||||
index:
|
||||
makeindex $(FILE)
|
||||
makeindex $(FILE).nlo -s nomencl.ist -o $(FILE).nls
|
||||
|
||||
makeindex $(FILE)_fr
|
||||
makeindex $(FILE)_fr.nlo -s nomencl.ist -o $(FILE)_fr.nls
|
||||
|
||||
clean:
|
||||
@rm -f \
|
||||
$(FILE).aux \
|
||||
$(FILE).dvi \
|
||||
$(FILE).idx \
|
||||
$(FILE).ilg \
|
||||
$(FILE).ind \
|
||||
$(FILE).lof \
|
||||
$(FILE).log \
|
||||
$(FILE).lol \
|
||||
$(FILE).lot \
|
||||
$(FILE).nlo \
|
||||
$(FILE).nls \
|
||||
$(FILE).out \
|
||||
$(FILE).pdf \
|
||||
$(FILE).toc \
|
||||
*.aux \
|
||||
*.dvi \
|
||||
*.idx \
|
||||
*.ilg \
|
||||
*.ind \
|
||||
*.lof \
|
||||
*.log \
|
||||
*.lol \
|
||||
*.lot \
|
||||
*.nlo \
|
||||
*.nls \
|
||||
*.out \
|
||||
*.pdf \
|
||||
*.toc \
|
||||
*~ \
|
||||
images/*.bak
|
||||
|
||||
|
|
|
|||
|
|
@ -307,7 +307,7 @@ EtherCAT functionality (see \autoref{chap:api}).
|
|||
|
||||
\item Accessing IDNs via the command-line tool.
|
||||
|
||||
\item Accessing IDNs at runtime via the the user-space library.
|
||||
\item Accessing IDNs at runtime via the user-space library.
|
||||
|
||||
\end{itemize}
|
||||
|
||||
|
|
@ -2903,7 +2903,7 @@ are rare, there are a few aspects that can (and should be) dealt with.
|
|||
|
||||
%------------------------------------------------------------------------------
|
||||
|
||||
\subsection{Application Interface Profiling}
|
||||
\section{Application Interface Profiling}
|
||||
\label{sec:timing-profile}
|
||||
\index{Profiling}
|
||||
% FIXME
|
||||
|
|
@ -2985,7 +2985,7 @@ in \autoref{sec:timing-bus}.
|
|||
|
||||
%------------------------------------------------------------------------------
|
||||
|
||||
\subsection{Bus Cycle Measuring}
|
||||
\section{Bus Cycle Measuring}
|
||||
\label{sec:timing-bus}
|
||||
\index{Bus cycle}
|
||||
|
||||
|
|
@ -3165,6 +3165,10 @@ interface) & \\
|
|||
\lstinline+--with-devices+ & Number of Ethernet devices for redundant
|
||||
operation ($>1$ switches redundancy on) & 1\\
|
||||
|
||||
\lstinline+--with-systemdsystemunitdir+ & Systemd unit directory ("no"
|
||||
disables service file installation)
|
||||
& auto \\
|
||||
|
||||
\lstinline+--enable-debug-if+ & Create a debug interface for each master & no\\
|
||||
|
||||
\lstinline+--enable-debug-ring+ & Create a debug ring to record frames & no\\
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -73,6 +73,8 @@ libethercat_la_CFLAGS = -fno-strict-aliasing -Wall -I$(top_srcdir)
|
|||
#
|
||||
libethercat_la_LDFLAGS = -version-info 2:0:1
|
||||
|
||||
pkgconfig_DATA = libethercat.pc
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
if ENABLE_RTDM
|
||||
|
|
|
|||
|
|
@ -0,0 +1,40 @@
|
|||
#
|
||||
# pkgconfig file for ethercat library
|
||||
#
|
||||
# Copyright 2021 Bjarne von Horn (vh at igh dot de)
|
||||
#
|
||||
# This file is part of the ethercat library.
|
||||
#
|
||||
# The ethercat library is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU Lesser General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or (at your
|
||||
# option) any later version.
|
||||
#
|
||||
# The ethercat library is distributed in the hope that it will be useful, but
|
||||
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
||||
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
# License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public License
|
||||
# along with the ethercat library. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
# ---
|
||||
#
|
||||
# The license mentioned above concerns the source code only. Using the
|
||||
# EtherCAT technology and brand is only permitted in compliance with the
|
||||
# industrial property and similar rights of Beckhoff Automation GmbH.
|
||||
#
|
||||
# vim: tw=78 noexpandtab
|
||||
#
|
||||
|
||||
prefix=@prefix@
|
||||
exec_prefix=@exec_prefix@
|
||||
libdir=@libdir@
|
||||
includedir=@includedir@
|
||||
|
||||
Name: libethercat
|
||||
Description: Client support library for the EtherCAT Master
|
||||
URL: http://www.etherlab.org
|
||||
Version: @VERSION@
|
||||
Libs: -L${libdir} -lethercat
|
||||
Cflags: -I${includedir}
|
||||
|
|
@ -35,9 +35,6 @@ SUBDIRS = init.d sysconfig
|
|||
|
||||
sbin_SCRIPTS = ethercatctl
|
||||
|
||||
systemddir = $(libdir)/systemd/system
|
||||
systemd_DATA = ethercat.service
|
||||
|
||||
dist_sysconf_DATA = ethercat.conf
|
||||
|
||||
EXTRA_DIST = \
|
||||
|
|
@ -49,4 +46,8 @@ BUILT_SOURCES = \
|
|||
ethercatctl \
|
||||
ethercat.service
|
||||
|
||||
if HAVE_SYSTEMD
|
||||
systemdsystemunit_DATA = ethercat.service
|
||||
endif
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@ string CommandDomains::helpString(const string &binaryBaseName) const
|
|||
<< endl
|
||||
<< "Command-specific options:" << endl
|
||||
<< " --domain -d <index> Positive numerical domain index." << endl
|
||||
<< " If ommitted, all domains are" << endl
|
||||
<< " If omitted, all domains are" << endl
|
||||
<< " displayed." << endl
|
||||
<< endl
|
||||
<< " --verbose -v Show FMMUs and process data" << endl
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ string CommandPdos::helpString(const string &binaryBaseName) const
|
|||
<< "Enable 1" << endl
|
||||
<< endl
|
||||
<< "2) Assigned PDOs - PDO direction, hexadecimal index and" << endl
|
||||
<< " the PDO name, if avaliable. Note that a 'Tx' and 'Rx'" << endl
|
||||
<< " the PDO name, if available. Note that a 'Tx' and 'Rx'" << endl
|
||||
<< " are seen from the slave's point of view. Example:" << endl
|
||||
<< endl
|
||||
<< " TxPDO 0x1a00 \"Channel1\"" << endl
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ string CommandSlaves::helpString(const string &binaryBaseName) const
|
|||
<< endl
|
||||
<< "1 5555:0 PREOP + EL3162 2C. Ana. Input 0-10V" << endl
|
||||
<< "| | | | | |" << endl
|
||||
<< "| | | | | \\- Name from the SII if avaliable," << endl
|
||||
<< "| | | | | \\- Name from the SII if available," << endl
|
||||
<< "| | | | | otherwise vendor ID and product" << endl
|
||||
<< "| | | | | code (both hexadecimal)." << endl
|
||||
<< "| | | | \\- Error flag. '+' means no error," << endl
|
||||
|
|
|
|||
Loading…
Reference in New Issue