view Makefile.am @ 27:9298f8b00db2 stable-1-0-10

patches from Takao Abe add switches for config and pid files
author Carl Byington <carl@five-ten-sg.com>
date Thu, 24 May 2018 10:35:45 -0700
parents 37793d4c90a0
children
line wrap: on
line source

ACLOCAL_AMFLAGS = -I m4

SUBDIRS = src man html info
hackdir = $(sysconfdir)/sm-archive
hack_SCRIPTS = sm-archive sm-archive.service
hack_DATA = sm-archive.conf sm-archive-tmpfs.conf
htmldir = ${datadir}/doc/@PACKAGE@-@VERSION@
html_DATA = AUTHORS COPYING ChangeLog NEWS README
CLEANFILES = sm-archive.service    sm-archive    xml/sm-archive xml/Makefile
EXTRA_DIST = sm-archive.service.rc sm-archive.rc $(hack_DATA) sm-archive.spec $(wildcard m4/*) $(wildcard xml/h*) $(wildcard xml/M*) $(wildcard xml/sm*)

sm-archive: sm-archive.rc
	   cat $(srcdir)/sm-archive.rc     | \
	       sed -e "s,SBINDIR,$(sbindir),g"  | \
	       sed -e "s,SYSCONFDIR,$(sysconfdir),g" >>sm-archive

sm-archive.service: sm-archive.service.rc
	   cat $(srcdir)/sm-archive.service.rc     | \
	       sed -e "s,SBINDIR,$(sbindir),g"  | \
	       sed -e "s,SYSCONFDIR,$(sysconfdir),g" >>sm-archive.service

chkconfig: sm-archive
	   /usr/bin/getent passwd sm-archive || /usr/sbin/useradd -r -d /etc/sm-archive -M -c "sm-archive pseudo-user" -s /sbin/nologin sm-archive
	   mv -f $(sysconfdir)/sm-archive /etc/rc.d/init.d
	   /sbin/chkconfig --del sm-archive
	   /sbin/chkconfig --add sm-archive