1 | # $Id: Makefile.kmk 1665 2008-06-30 21:14:11Z bird $
|
---|
2 | ## @file
|
---|
3 | # Sub-Makefile for kmk_sed.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (c) 2006-2008 knut st. osmundsen <[email protected]>
|
---|
8 | #
|
---|
9 | # This file is part of kBuild.
|
---|
10 | #
|
---|
11 | # kBuild is free software; you can redistribute it and/or modify
|
---|
12 | # it under the terms of the GNU General Public License as published by
|
---|
13 | # the Free Software Foundation; either version 2 of the License, or
|
---|
14 | # (at your option) any later version.
|
---|
15 | #
|
---|
16 | # kBuild is distributed in the hope that it will be useful,
|
---|
17 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
18 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
---|
19 | # GNU General Public License for more details.
|
---|
20 | #
|
---|
21 | # You should have received a copy of the GNU General Public License
|
---|
22 | # along with kBuild; if not, write to the Free Software
|
---|
23 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
---|
24 | #
|
---|
25 | #
|
---|
26 |
|
---|
27 | SUB_DEPTH = ../..
|
---|
28 | include $(KBUILD_PATH)/subheader.kmk
|
---|
29 |
|
---|
30 | #
|
---|
31 | # kmk_sed
|
---|
32 | #
|
---|
33 | PROGRAMS += kmk_sed
|
---|
34 |
|
---|
35 | kmk_sed_TEMPLATE = BIN
|
---|
36 | kmk_sed_DEPS = \
|
---|
37 | $(PATH_kmk_sed)/config.h \
|
---|
38 | $(PATH_kmk_sed)/regex.h
|
---|
39 | kmk_sed_CLEAN = $(kmk_sed_DEPS)
|
---|
40 | kmk_sed_INCS = \
|
---|
41 | $(PATH_kmk_sed) \
|
---|
42 | . \
|
---|
43 | lib \
|
---|
44 | intl
|
---|
45 | kmk_sed_DEFS = \
|
---|
46 | HAVE_CONFIG_H
|
---|
47 | kmk_sed_SOURCES = \
|
---|
48 | sed/sed.c \
|
---|
49 | lib/regex.c \
|
---|
50 | sed/compile.c \
|
---|
51 | sed/execute.c \
|
---|
52 | sed/regexp.c \
|
---|
53 | sed/fmt.c \
|
---|
54 | sed/mbcs.c \
|
---|
55 | lib/getopt1.c \
|
---|
56 | lib/getopt.c \
|
---|
57 | lib/utils.c
|
---|
58 | kmk_sed_SOURCES.darwin = \
|
---|
59 | lib/strverscmp.c \
|
---|
60 | lib/obstack.c \
|
---|
61 | lib/getline.c
|
---|
62 | kmk_sed_SOURCES.dragonfly = \
|
---|
63 | lib/strverscmp.c \
|
---|
64 | lib/obstack.c \
|
---|
65 | lib/getline.c
|
---|
66 | kmk_sed_SOURCES.freebsd = \
|
---|
67 | lib/strverscmp.c \
|
---|
68 | lib/obstack.c \
|
---|
69 | lib/getline.c
|
---|
70 | kmk_sed_SOURCES.solaris = \
|
---|
71 | lib/strverscmp.c \
|
---|
72 | lib/obstack.c \
|
---|
73 | lib/getline.c
|
---|
74 | kmk_sed_SOURCES.win = \
|
---|
75 | lib/strverscmp.c \
|
---|
76 | lib/obstack.c \
|
---|
77 | lib/mkstemp.c \
|
---|
78 | lib/getline.c \
|
---|
79 | ../lib/startuphacks-win.c
|
---|
80 |
|
---|
81 | include $(FILE_KBUILD_SUB_FOOTER)
|
---|
82 |
|
---|
83 | #
|
---|
84 | # Use checked in config.h instead of running ./configure for it.
|
---|
85 | #
|
---|
86 | kmk_sed_config.h.$(KBUILD_TARGET) := $(kmk_sed_PATH)/config.h.$(KBUILD_TARGET)
|
---|
87 |
|
---|
88 | $(PATH_kmk_sed)/config.h: $(kmk_sed_config.h.$(KBUILD_TARGET)) | $(call DIRDEP,$(PATH_kmk_sed))
|
---|
89 | $(CP) -f $^ $@
|
---|
90 |
|
---|
91 | #
|
---|
92 | # Use the regex lib shipped with sed and not anything installed on the system.
|
---|
93 | #
|
---|
94 | $(PATH_kmk_sed)/regex.h: $(kmk_sed_PATH)/lib/regex_.h | $(call DIRDEP,$(PATH_kmk_sed))
|
---|
95 | $(CP) -f $^ $@
|
---|
96 |
|
---|