source: trunk/essentials/sys-apps/diffutils/kNIX-bootstrap.kmk

Last change on this file was 3845, checked in by bird, 11 years ago

svn:eol-style: native

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.8 KB
Line 
1# $Id: kNIX-bootstrap.kmk 3845 2014-03-16 20:31:39Z bird $
2## @file
3#
4# kNIX Boostrap Makefile for diffutils
5#
6# Copyright (c) 2007 knut st. osmundsen <bird-src-spam@anduin.net>
7#
8#
9# This file is part of kLIBC.
10#
11# kLIBC 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# kLIBC 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 kLIBC; if not, write to the Free Software
23# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24#
25#
26
27DEPTH = ../../..
28include $(PATH_KBUILD)/header.kmk
29
30#
31# The diffutils template.
32#
33TEMPLATE_diffutils = diffutils template
34TEMPLATE_diffutils_EXTENDS = usr.bin
35TEMPLATE_diffutils_DEFS = $(TEMPLATE_usr.bin_DEFS) \
36 LOCALEDIR=\"/@unixroot/usr/share/locale\" \
37 HAVE_CONFIG_H
38TEMPLATE_diffutils_INCS = $(TEMPLATE_usr.bin_INCS) \
39 $(PATH_TARGET) \
40 $(PATH_SUB_CURRENT) \
41 $(PATH_SUB_ROOT)/lib
42TEMPLATE_diffutils_LIBS = $(TEMPLATE_usr.bin_LIBS) \
43 $(TARGET_libdiffutils)
44TEMPLATE_diffutils_ORDERDEPS = $(TEMPLATE_usr.bin_ORDERDEPS) \
45 $(PATH_TARGET)/config.h \
46 $(PATH_TARGET)/fnmatch.h
47
48#
49# libdiffutils
50#
51LIBRARIES += libdiffutils
52libdiffutils_TEMPLATE = diffutils
53libdiffutils_NOINST = true
54libdiffutils_SOURCES = \
55 lib/basename.c \
56 lib/c-stack.c \
57 lib/cmpbuf.c \
58 lib/error.c \
59 lib/exclude.c \
60 lib/exitfail.c \
61 lib/freesoft.c \
62 lib/getopt.c \
63 lib/getopt1.c \
64 lib/hard-locale.c \
65 lib/imaxtostr.c \
66 lib/offtostr.c \
67 lib/prepargs.c \
68 lib/posixver.c \
69 lib/quotesys.c \
70 lib/setmode.c \
71 lib/strftime.c \
72 lib/umaxtostr.c \
73 lib/xmalloc.c \
74 lib/xstrtoumax.c \
75 \
76 lib/fnmatch.c
77
78#
79# diff
80#
81PROGRAMS += diff
82diff_TEMPLATE = diffutils
83diff_SOURCES = \
84 src/diff.c \
85 src/analyze.c \
86 src/context.c \
87 src/dir.c \
88 src/ed.c \
89 src/ifdef.c \
90 src/io.c \
91 src/normal.c \
92 src/side.c \
93 src/util.c \
94 $(PATH_TARGET)/version.c
95
96#
97# diff3
98#
99PROGRAMS += diff3
100diff3_TEMPLATE = diffutils
101diff3_SOURCES = \
102 src/diff3.c \
103 $(PATH_TARGET)/version.c
104
105#
106# diff3
107#
108PROGRAMS += sdiff
109sdiff_TEMPLATE = diffutils
110sdiff_SOURCES = \
111 src/sdiff.c \
112 $(PATH_TARGET)/version.c
113
114#
115# cmp
116#
117PROGRAMS += cmp
118cmp_TEMPLATE = diffutils
119cmp_SOURCES = \
120 src/cmp.c \
121 $(PATH_TARGET)/version.c
122
123#
124# config.h and version.c
125#
126$(PATH_TARGET)/config.h: kNIX-bootstrap-$(BUILD_TARGET).$(BUILD_TARGET_ARCH)-config.h
127 $(INSTALL) $< $@
128
129$(PATH_TARGET)/fnmatch.h: lib/fnmatch.hin
130 $(INSTALL) $< $@
131
132$(PATH_TARGET)/version.c:
133 $(RM) -f $@
134 $(APPEND) $@ '#include <config.h>'
135 $(APPEND) $@ 'char const version_string[] = "(GNU diffutils) 5.8.1";'
136 $(APPEND) $@ ''
137
138include $(PATH_KBUILD)/footer.kmk
139
Note: See TracBrowser for help on using the repository browser.