Change in osmo-pcap[master]: Install cfg files with autotools

2018-11-02 Thread Pau Espin Pedrol
Pau Espin Pedrol has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/11546 )

Change subject: Install cfg files with autotools
..

Install cfg files with autotools

Cfg files are moved to doc/examples like in other osmocom projects.
All the cfg files get installed into
$prefix/share/doc/osmo-pcap/examples/$subdir/, and 1 script per binary is
installed into /etc/osmocom.

Change-Id: If3f3a7d3867c0d4d2b1fe01f465532d1ce4bda66
---
M Makefile.am
M configure.ac
M contrib/Makefile.am
M debian/osmo-pcap-client.install
M debian/osmo-pcap-server.install
M debian/rules
A doc/Makefile.am
A doc/examples/Makefile.am
R doc/examples/osmo-pcap-client/osmo-pcap-client-tls.cfg
R doc/examples/osmo-pcap-client/osmo-pcap-client.cfg
R doc/examples/osmo-pcap-server/osmo-pcap-server-tls.cfg
R doc/examples/osmo-pcap-server/osmo-pcap-server.cfg
12 files changed, 40 insertions(+), 13 deletions(-)

Approvals:
  Jenkins Builder: Verified
  daniel: Looks good to me, approved



diff --git a/Makefile.am b/Makefile.am
index 0f4a249..1dd1ff4 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,6 +1,6 @@
 AUTOMAKE_OPTIONS = foreign dist-bzip2 1.6

-SUBDIRS = include src contrib tests
+SUBDIRS = include src contrib doc tests

 BUILT_SOURCES = $(top_srcdir)/.version
 EXTRA_DIST = git-version-gen .version
diff --git a/configure.ac b/configure.ac
index f885e6d..95c5270 100644
--- a/configure.ac
+++ b/configure.ac
@@ -145,5 +145,7 @@
 src/Makefile
 contrib/Makefile
 contrib/systemd/Makefile
+doc/Makefile
+doc/examples/Makefile
 tests/Makefile
 Makefile)
diff --git a/contrib/Makefile.am b/contrib/Makefile.am
index 7bd8c23..e1927a7 100644
--- a/contrib/Makefile.am
+++ b/contrib/Makefile.am
@@ -1,3 +1,2 @@
 SUBDIRS = systemd
 dist_pkgdata_DATA = osmo_pcap_clean_old
-EXTRA_DIST = osmo-pcap-server.cfg osmo-pcap-client.cfg
diff --git a/debian/osmo-pcap-client.install b/debian/osmo-pcap-client.install
index ac7c65c..ef6576e 100644
--- a/debian/osmo-pcap-client.install
+++ b/debian/osmo-pcap-client.install
@@ -1,2 +1,5 @@
+etc/osmocom/osmo-pcap-client.cfg
 lib/systemd/system/osmo-pcap-client.service
 usr/bin/osmo-pcap-client
+usr/share/doc/osmo-pcap/examples/osmo-pcap-client/osmo-pcap-client.cfg
+usr/share/doc/osmo-pcap/examples/osmo-pcap-client/osmo-pcap-client-tls.cfg
diff --git a/debian/osmo-pcap-server.install b/debian/osmo-pcap-server.install
index 6ba698e..cedee92 100644
--- a/debian/osmo-pcap-server.install
+++ b/debian/osmo-pcap-server.install
@@ -1,2 +1,5 @@
+etc/osmocom/osmo-pcap-server.cfg
 lib/systemd/system/osmo-pcap-server.service
 usr/bin/osmo-pcap-server
+usr/share/doc/osmo-pcap/examples/osmo-pcap-server/osmo-pcap-server.cfg
+usr/share/doc/osmo-pcap/examples/osmo-pcap-server/osmo-pcap-server-tls.cfg
diff --git a/debian/rules b/debian/rules
index a9a8b30..90bd79e 100755
--- a/debian/rules
+++ b/debian/rules
@@ -21,17 +21,6 @@
PCAP_CFLAGS=$(PCAP_CFLAGS) \
PCAP_LIBS=$(PCAP_LIBS)

-override_dh_auto_install:
-   dh_auto_install $@
-   install -d -m 0755 $(CURDIR)/debian/osmo-pcap-client/etc/osmo-pcap/
-   install -m 0644 $(CURDIR)/contrib/osmo-pcap-client.cfg 
$(CURDIR)/debian/osmo-pcap-client/etc/osmo-pcap
-
-   install -d -m 0755 $(CURDIR)/debian/osmo-pcap-server/etc/osmo-pcap/
-   install -m 0644 $(CURDIR)/contrib/osmo-pcap-server.cfg 
$(CURDIR)/debian/osmo-pcap-server/etc/osmo-pcap
-
-   install -d -m 0755 $(CURDIR)/debian/osmo-pcap-server/etc/cron.daily/
-   install -m 0755 $(CURDIR)/contrib/osmo_pcap_clean_old 
$(CURDIR)/debian/osmo-pcap-server/etc/cron.daily/
-
 override_dh_strip:
dh_strip -posmo-pcap-client --dbg-package=osmo-pcap-client-dbg
dh_strip -posmo-pcap-server --dbg-package=osmo-pcap-server-dbg
diff --git a/doc/Makefile.am b/doc/Makefile.am
new file mode 100644
index 000..aee2d7b
--- /dev/null
+++ b/doc/Makefile.am
@@ -0,0 +1 @@
+SUBDIRS = examples
diff --git a/doc/examples/Makefile.am b/doc/examples/Makefile.am
new file mode 100644
index 000..9337c9e
--- /dev/null
+++ b/doc/examples/Makefile.am
@@ -0,0 +1,30 @@
+OSMOCONF_FILES = \
+   osmo-pcap-client/osmo-pcap-client.cfg \
+   osmo-pcap-server/osmo-pcap-server.cfg
+
+osmoconfdir = $(sysconfdir)/osmocom
+osmoconf_DATA = $(OSMOCONF_FILES)
+EXTRA_DIST = $(OSMOCONF_FILES)
+
+CFG_FILES = find $(srcdir) -type f -name '*.cfg*' | sed -e 's,^$(srcdir),,'
+
+dist-hook:
+   for f in $$($(CFG_FILES)); do \
+   j="$(distdir)/$$f" && \
+   mkdir -p "$$(dirname $$j)" && \
+   $(INSTALL_DATA) $(srcdir)/$$f $$j; \
+   done
+
+install-data-hook:
+   for f in $$($(CFG_FILES)); do \
+   j="$(DESTDIR)$(docdir)/examples/$$f" && \
+   mkdir -p "$$(dirname $$j)" && \
+   $(INSTALL_DATA) $(srcdir)/$$f $$j; \
+   done
+
+uninstall-hook:
+   @$(PRE_UNINSTALL)
+   for f in $$($(CFG_FILES)); do \
+   

Change in osmo-pcap[master]: Install cfg files with autotools

2018-11-01 Thread daniel
daniel has posted comments on this change. ( https://gerrit.osmocom.org/11546 )

Change subject: Install cfg files with autotools
..


Patch Set 3: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/11546
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If3f3a7d3867c0d4d2b1fe01f465532d1ce4bda66
Gerrit-Change-Number: 11546
Gerrit-PatchSet: 3
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: daniel 
Gerrit-Comment-Date: Thu, 01 Nov 2018 19:28:09 +
Gerrit-HasComments: No
Gerrit-HasLabels: Yes


Change in osmo-pcap[master]: Install cfg files with autotools

2018-11-01 Thread Pau Espin Pedrol
Hello daniel, Jenkins Builder,

I'd like you to reexamine a change. Please visit

https://gerrit.osmocom.org/11546

to look at the new patch set (#3).

Change subject: Install cfg files with autotools
..

Install cfg files with autotools

Cfg files are moved to doc/examples like in other osmocom projects.
All the cfg files get installed into
$prefix/share/doc/osmo-pcap/examples/$subdir/, and 1 script per binary is
installed into /etc/osmocom.

Change-Id: If3f3a7d3867c0d4d2b1fe01f465532d1ce4bda66
---
M Makefile.am
M configure.ac
M contrib/Makefile.am
M debian/osmo-pcap-client.install
M debian/osmo-pcap-server.install
M debian/rules
A doc/Makefile.am
A doc/examples/Makefile.am
R doc/examples/osmo-pcap-client/osmo-pcap-client-tls.cfg
R doc/examples/osmo-pcap-client/osmo-pcap-client.cfg
R doc/examples/osmo-pcap-server/osmo-pcap-server-tls.cfg
R doc/examples/osmo-pcap-server/osmo-pcap-server.cfg
12 files changed, 40 insertions(+), 13 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-pcap refs/changes/46/11546/3
--
To view, visit https://gerrit.osmocom.org/11546
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: If3f3a7d3867c0d4d2b1fe01f465532d1ce4bda66
Gerrit-Change-Number: 11546
Gerrit-PatchSet: 3
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: daniel 


Change in osmo-pcap[master]: Install cfg files with autotools

2018-10-31 Thread daniel
daniel has posted comments on this change. ( https://gerrit.osmocom.org/11546 )

Change subject: Install cfg files with autotools
..


Patch Set 2: Code-Review-1

(1 comment)

Apart from the commit message it looks good

https://gerrit.osmocom.org/#/c/11546/2//COMMIT_MSG
Commit Message:

https://gerrit.osmocom.org/#/c/11546/2//COMMIT_MSG@11
PS2, Line 11: $prefix/share/doc/osmo-trx/examples/$subdir/, and 1 script per 
binary is
s/osmo-trx/osmo-pcap/



--
To view, visit https://gerrit.osmocom.org/11546
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If3f3a7d3867c0d4d2b1fe01f465532d1ce4bda66
Gerrit-Change-Number: 11546
Gerrit-PatchSet: 2
Gerrit-Owner: Pau Espin Pedrol 
Gerrit-Reviewer: Jenkins Builder (102)
Gerrit-Reviewer: daniel 
Gerrit-Comment-Date: Wed, 31 Oct 2018 18:02:14 +
Gerrit-HasComments: Yes
Gerrit-HasLabels: Yes


Change in osmo-pcap[master]: Install cfg files with autotools

2018-10-31 Thread Pau Espin Pedrol
Pau Espin Pedrol has uploaded this change for review. ( 
https://gerrit.osmocom.org/11546


Change subject: Install cfg files with autotools
..

Install cfg files with autotools

Cfg files are moved to doc/examples like in other osmocom projects.
All the cfg files get installed into
$prefix/share/doc/osmo-trx/examples/$subdir/, and 1 script per binary is
installed into /etc/osmocom.

Change-Id: If3f3a7d3867c0d4d2b1fe01f465532d1ce4bda66
---
M Makefile.am
M configure.ac
M contrib/Makefile.am
M debian/osmo-pcap-client.install
M debian/osmo-pcap-server.install
M debian/rules
A doc/Makefile.am
A doc/examples/Makefile.am
R doc/examples/osmo-pcap-client/osmo-pcap-client-tls.cfg
R doc/examples/osmo-pcap-client/osmo-pcap-client.cfg
R doc/examples/osmo-pcap-server/osmo-pcap-server-tls.cfg
R doc/examples/osmo-pcap-server/osmo-pcap-server.cfg
12 files changed, 40 insertions(+), 13 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-pcap refs/changes/46/11546/1

diff --git a/Makefile.am b/Makefile.am
index 61eb85d..cf8dfa3 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,6 +1,6 @@
 AUTOMAKE_OPTIONS = foreign dist-bzip2 1.6

-SUBDIRS = include src contrib tests
+SUBDIRS = include src contrib doc tests

 BUILT_SOURCES = $(top_srcdir)/.version
 EXTRA_DIST = git-version-gen .version
diff --git a/configure.ac b/configure.ac
index a0f786f..b16ae13 100644
--- a/configure.ac
+++ b/configure.ac
@@ -138,5 +138,7 @@
 src/Makefile
 contrib/Makefile
 contrib/systemd/Makefile
+doc/Makefile
+doc/examples/Makefile
 tests/Makefile
 Makefile)
diff --git a/contrib/Makefile.am b/contrib/Makefile.am
index 7bd8c23..e1927a7 100644
--- a/contrib/Makefile.am
+++ b/contrib/Makefile.am
@@ -1,3 +1,2 @@
 SUBDIRS = systemd
 dist_pkgdata_DATA = osmo_pcap_clean_old
-EXTRA_DIST = osmo-pcap-server.cfg osmo-pcap-client.cfg
diff --git a/debian/osmo-pcap-client.install b/debian/osmo-pcap-client.install
index ac7c65c..ef6576e 100644
--- a/debian/osmo-pcap-client.install
+++ b/debian/osmo-pcap-client.install
@@ -1,2 +1,5 @@
+etc/osmocom/osmo-pcap-client.cfg
 lib/systemd/system/osmo-pcap-client.service
 usr/bin/osmo-pcap-client
+usr/share/doc/osmo-pcap/examples/osmo-pcap-client/osmo-pcap-client.cfg
+usr/share/doc/osmo-pcap/examples/osmo-pcap-client/osmo-pcap-client-tls.cfg
diff --git a/debian/osmo-pcap-server.install b/debian/osmo-pcap-server.install
index 6ba698e..cedee92 100644
--- a/debian/osmo-pcap-server.install
+++ b/debian/osmo-pcap-server.install
@@ -1,2 +1,5 @@
+etc/osmocom/osmo-pcap-server.cfg
 lib/systemd/system/osmo-pcap-server.service
 usr/bin/osmo-pcap-server
+usr/share/doc/osmo-pcap/examples/osmo-pcap-server/osmo-pcap-server.cfg
+usr/share/doc/osmo-pcap/examples/osmo-pcap-server/osmo-pcap-server-tls.cfg
diff --git a/debian/rules b/debian/rules
index a9a8b30..90bd79e 100755
--- a/debian/rules
+++ b/debian/rules
@@ -21,17 +21,6 @@
PCAP_CFLAGS=$(PCAP_CFLAGS) \
PCAP_LIBS=$(PCAP_LIBS)

-override_dh_auto_install:
-   dh_auto_install $@
-   install -d -m 0755 $(CURDIR)/debian/osmo-pcap-client/etc/osmo-pcap/
-   install -m 0644 $(CURDIR)/contrib/osmo-pcap-client.cfg 
$(CURDIR)/debian/osmo-pcap-client/etc/osmo-pcap
-
-   install -d -m 0755 $(CURDIR)/debian/osmo-pcap-server/etc/osmo-pcap/
-   install -m 0644 $(CURDIR)/contrib/osmo-pcap-server.cfg 
$(CURDIR)/debian/osmo-pcap-server/etc/osmo-pcap
-
-   install -d -m 0755 $(CURDIR)/debian/osmo-pcap-server/etc/cron.daily/
-   install -m 0755 $(CURDIR)/contrib/osmo_pcap_clean_old 
$(CURDIR)/debian/osmo-pcap-server/etc/cron.daily/
-
 override_dh_strip:
dh_strip -posmo-pcap-client --dbg-package=osmo-pcap-client-dbg
dh_strip -posmo-pcap-server --dbg-package=osmo-pcap-server-dbg
diff --git a/doc/Makefile.am b/doc/Makefile.am
new file mode 100644
index 000..aee2d7b
--- /dev/null
+++ b/doc/Makefile.am
@@ -0,0 +1 @@
+SUBDIRS = examples
diff --git a/doc/examples/Makefile.am b/doc/examples/Makefile.am
new file mode 100644
index 000..9337c9e
--- /dev/null
+++ b/doc/examples/Makefile.am
@@ -0,0 +1,30 @@
+OSMOCONF_FILES = \
+   osmo-pcap-client/osmo-pcap-client.cfg \
+   osmo-pcap-server/osmo-pcap-server.cfg
+
+osmoconfdir = $(sysconfdir)/osmocom
+osmoconf_DATA = $(OSMOCONF_FILES)
+EXTRA_DIST = $(OSMOCONF_FILES)
+
+CFG_FILES = find $(srcdir) -type f -name '*.cfg*' | sed -e 's,^$(srcdir),,'
+
+dist-hook:
+   for f in $$($(CFG_FILES)); do \
+   j="$(distdir)/$$f" && \
+   mkdir -p "$$(dirname $$j)" && \
+   $(INSTALL_DATA) $(srcdir)/$$f $$j; \
+   done
+
+install-data-hook:
+   for f in $$($(CFG_FILES)); do \
+   j="$(DESTDIR)$(docdir)/examples/$$f" && \
+   mkdir -p "$$(dirname $$j)" && \
+   $(INSTALL_DATA) $(srcdir)/$$f $$j; \
+   done
+
+uninstall-hook:
+   @$(PRE_UNINSTALL)
+   for f in $$($(CFG_FILES)); do \
+