summaryrefslogtreecommitdiffstats
path: root/term-utils/Makemodule.am
diff options
context:
space:
mode:
authorKarel Zak2012-06-26 17:53:09 +0200
committerKarel Zak2012-06-26 17:53:09 +0200
commit22d2322eb1202f6961041b8fcacbe6e6856fb6b0 (patch)
treea0cf1195fe05d2cc7c3ad681a84b6be365df676f /term-utils/Makemodule.am
parentbuild-sys: convert text-utils/ to module (diff)
downloadkernel-qcow2-util-linux-22d2322eb1202f6961041b8fcacbe6e6856fb6b0.tar.gz
kernel-qcow2-util-linux-22d2322eb1202f6961041b8fcacbe6e6856fb6b0.tar.xz
kernel-qcow2-util-linux-22d2322eb1202f6961041b8fcacbe6e6856fb6b0.zip
build-sys: convert term-utils/ to module
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'term-utils/Makemodule.am')
-rw-r--r--term-utils/Makemodule.am99
1 files changed, 99 insertions, 0 deletions
diff --git a/term-utils/Makemodule.am b/term-utils/Makemodule.am
new file mode 100644
index 000000000..419aec535
--- /dev/null
+++ b/term-utils/Makemodule.am
@@ -0,0 +1,99 @@
+
+usrbin_exec_PROGRAMS += script
+dist_man_MANS += term-utils/script.1
+script_SOURCES = term-utils/script.c
+script_LDADD =
+if HAVE_UTIL
+script_LDADD += -lutil
+endif
+if HAVE_UTEMPTER
+script_LDADD += -lutempter
+endif
+
+
+usrbin_exec_PROGRAMS += scriptreplay
+dist_man_MANS += term-utils/scriptreplay.1
+scriptreplay_SOURCES = term-utils/scriptreplay.c
+
+
+if BUILD_AGETTY
+sbin_PROGRAMS += agetty
+dist_man_MANS += term-utils/agetty.8
+agetty_SOURCES = term-utils/agetty.c
+if !HAVE_LANGINFO
+agetty_SOURCES += lib/langinfo.c
+endif
+endif # BUILD_AGETTY
+
+
+# TODO: add BUILD_SETTERM to configure.am
+if HAVE_NCURSES
+if LINUX
+usrbin_exec_PROGRAMS += setterm
+dist_man_MANS += term-utils/setterm.1
+setterm_SOURCES = term-utils/setterm.c
+endif
+if HAVE_TINFO
+setterm_LDADD = -ltinfo
+else
+setterm_LDADD = @NCURSES_LIBS@
+endif
+endif
+
+
+if BUILD_RESET
+dist_usrbin_exec_SCRIPTS += term-utils/reset
+dist_man_MANS += term-utils/reset.1
+endif
+EXTRA_DIST += term-utils/reset.033c
+
+
+if BUILD_MESG
+usrbin_exec_PROGRAMS += mesg
+dist_man_MANS += term-utils/mesg.1
+mesg_SOURCES = term-utils/mesg.c
+endif
+
+
+if BUILD_WALL
+usrbin_exec_PROGRAMS += wall
+wall_SOURCES = \
+ term-utils/wall.c \
+ term-utils/ttymsg.c \
+ term-utils/ttymsg.h \
+ lib/strutils.c \
+ lib/fileutils.c
+
+dist_man_MANS += term-utils/wall.1
+wall_CFLAGS = $(SUID_CFLAGS) $(AM_CFLAGS)
+wall_LDFLAGS = $(SUID_LDFLAGS) $(AM_LDFLAGS)
+
+if USE_TTY_GROUP
+if MAKEINSTALL_DO_CHOWN
+install-exec-hook-wall::
+ chgrp tty $(DESTDIR)$(usrbin_execdir)/wall
+ chmod g+s $(DESTDIR)$(usrbin_execdir)/wall
+
+INSTALL_EXEC_HOOKS += install-exec-hook-wall
+endif
+endif
+endif # BUILD_WALL
+
+
+if BUILD_WRITE
+usrbin_exec_PROGRAMS += write
+dist_man_MANS += term-utils/write.1
+write_SOURCES = term-utils/write.c
+write_CFLAGS = $(SUID_CFLAGS) $(AM_CFLAGS)
+write_LDFLAGS = $(SUID_LDFLAGS) $(AM_LDFLAGS)
+
+if USE_TTY_GROUP
+if MAKEINSTALL_DO_CHOWN
+install-exec-hook-write::
+ chgrp tty $(DESTDIR)$(usrbin_execdir)/write
+ chmod g+s $(DESTDIR)$(usrbin_execdir)/write
+
+INSTALL_EXEC_HOOKS += install-exec-hook-write
+endif
+endif
+endif # BUILD_WRITE