File: Makefile.am

package info (click to toggle)
libzip 0.8-1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 2,324 kB
  • ctags: 389
  • sloc: sh: 9,486; ansic: 4,099; makefile: 226
file content (99 lines) | stat: -rw-r--r-- 2,640 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
MANFMT=@MANFMT@
man1_MANS=${MAN1:.mdoc=.${MANFMT}}
man3_MANS=${MAN3:.mdoc=.${MANFMT}}

DISTCLEANFILES=${HTML}
EXTRA_DIST=${MANDOC} ${MAN} CMakeLists.txt

MAN1=	zipcmp.mdoc zipmerge.mdoc
MAN3=	libzip.mdoc \
	zip_add.mdoc \
	zip_add_dir.mdoc \
	zip_close.mdoc \
	zip_delete.mdoc \
	zip_error_clear.mdoc \
	zip_error_get.mdoc \
	zip_error_get_sys_type.mdoc \
	zip_error_to_str.mdoc \
	zip_errors.mdoc \
	zip_fclose.mdoc \
	zip_file_strerror.mdoc \
	zip_fopen.mdoc \
	zip_fread.mdoc \
	zip_get_archive_comment.mdoc \
	zip_get_file_comment.mdoc \
	zip_get_name.mdoc \
	zip_get_num_files.mdoc \
	zip_name_locate.mdoc \
	zip_open.mdoc \
	zip_rename.mdoc \
	zip_set_archive_comment.mdoc \
	zip_set_file_comment.mdoc \
	zip_source_buffer.mdoc \
	zip_source_file.mdoc \
	zip_source_filep.mdoc \
	zip_source_free.mdoc \
	zip_source_function.mdoc \
	zip_source_zip.mdoc \
	zip_stat.mdoc \
	zip_stat_init.mdoc \
	zip_unchange.mdoc \
	zip_unchange_all.mdoc \
	zip_unchange_archive.mdoc

install-data-hook: link-man3

LN=ln

link-man3: install-man3 uninstall-hook
	${LN} ${DESTDIR}${man3dir}/zip_error_clear.3 \
		${DESTDIR}${man3dir}/zip_file_error_clear.3
	${LN} ${DESTDIR}${man3dir}/zip_error_get.3 \
		${DESTDIR}${man3dir}/zip_file_error_get.3
	${LN} ${DESTDIR}${man3dir}/zip_fopen.3 \
		${DESTDIR}${man3dir}/zip_fopen_index.3
	${LN} ${DESTDIR}${man3dir}/zip_add.3 \
		${DESTDIR}${man3dir}/zip_replace.3
	${LN} ${DESTDIR}${man3dir}/zip_stat.3 \
		${DESTDIR}${man3dir}/zip_stat_index.3
	${LN} ${DESTDIR}${man3dir}/zip_file_strerror.3 \
		${DESTDIR}${man3dir}/zip_strerror.3

uninstall-hook:
	-rm -f ${DESTDIR}${man3dir}/zip_file_error_clear.3
	-rm -f ${DESTDIR}${man3dir}/zip_file_error_get.3
	-rm -f ${DESTDIR}${man3dir}/zip_fopen_index.3
	-rm -f ${DESTDIR}${man3dir}/zip_replace.3
	-rm -f ${DESTDIR}${man3dir}/zip_stat_index.3
	-rm -f ${DESTDIR}${man3dir}/zip_strerror.3

link-html: ${HTML}
	-rm -f zip_file_error_get.html zip_fopen_index.html \
		zip_replace.html zip_stat_index.html \
		zip_strerror.html
	${LN} zip_error_get.html zip_file_error_get.html
	${LN} zip_fopen.html zip_fopen_index.html
	${LN} zip_add.html zip_replace.html
	${LN} zip_stat.html zip_stat_index.html
	${LN} zip_file_strerror.html zip_strerror.html

MANDOC=${MAN1} ${MAN3}
HTML=${MANDOC:.mdoc=.html}
MAN=${MANDOC:.mdoc=.man}

MDOC2MAN=mdoc2man
SUFFIXES=.man .mdoc .html

.PHONY: mkman update-errors

mkman: ${MAN}
mkhtml: ${HTML} link-html

update-errors:
	sh $(srcdir)/make_zip_errors.sh $(srcdir)/../lib/zip.h zip_errors.mdoc

.mdoc.man:
	${MDOC2MAN} $< > $@.$$$$ && mv $@.$$$$ $@

.mdoc.html:
	nroff -mdoc2html $< | sed -e "s,../html[0-9]/,," > $@.$$$$ && mv $@.$$$$ $@