Commit 0bcd9ae
sparse: Fix errors due to missing target-specific variables
In particular, sparse issues the following errors:
attr.c:472:43: error: undefined identifier 'ETC_GITATTRIBUTES'
config.c:821:43: error: undefined identifier 'ETC_GITCONFIG'
exec_cmd.c:14:37: error: undefined identifier 'PREFIX'
exec_cmd.c:83:28: error: undefined identifier 'GIT_EXEC_PATH'
builtin/help.c:328:46: error: undefined identifier 'GIT_MAN_PATH'
builtin/help.c:374:40: error: undefined identifier 'GIT_INFO_PATH'
builtin/help.c:382:45: error: undefined identifier 'GIT_HTML_PATH'
git.c:96:42: error: undefined identifier 'GIT_HTML_PATH'
git.c:241:35: error: invalid initializer
http.c:293:43: error: undefined identifier 'GIT_HTTP_USER_AGENT'
which is caused by not passing the target-specific additions to
the EXTRA_CPPFLAGS variable to cgcc.
In order to fix the problem, we define a new sparse target which
depends on a set of non-existent "sparse object" files (*.sp)
which correspond to the set of C source files. In addition to the
new target, we also provide a new pattern rule for "creating" the
sparse object files from the source files by running cgcc. This
allows us to add '*.sp' to the rules setting the target-specific
EXTRA_CPPFLAGS variable, which is then included in the new pattern
rule to run cgcc.
Also, we change the 'check' target to re-direct the user to the
new sparse target.
Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Signed-off-by: Junio C Hamano <gitster@pobox.com>1 parent 1e0f8c4 commit 0bcd9ae
1 file changed
+28
-17
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1581 | 1581 | | |
1582 | 1582 | | |
1583 | 1583 | | |
| 1584 | + | |
1584 | 1585 | | |
1585 | 1586 | | |
1586 | 1587 | | |
| |||
1676 | 1677 | | |
1677 | 1678 | | |
1678 | 1679 | | |
1679 | | - | |
| 1680 | + | |
1680 | 1681 | | |
1681 | 1682 | | |
1682 | 1683 | | |
1683 | 1684 | | |
1684 | 1685 | | |
1685 | 1686 | | |
1686 | | - | |
| 1687 | + | |
1687 | 1688 | | |
1688 | | - | |
1689 | | - | |
| 1689 | + | |
| 1690 | + | |
1690 | 1691 | | |
1691 | 1692 | | |
1692 | 1693 | | |
| |||
1972 | 1973 | | |
1973 | 1974 | | |
1974 | 1975 | | |
1975 | | - | |
| 1976 | + | |
1976 | 1977 | | |
1977 | 1978 | | |
1978 | 1979 | | |
1979 | 1980 | | |
1980 | | - | |
| 1981 | + | |
1981 | 1982 | | |
1982 | 1983 | | |
1983 | | - | |
| 1984 | + | |
| 1985 | + | |
1984 | 1986 | | |
1985 | | - | |
| 1987 | + | |
| 1988 | + | |
1986 | 1989 | | |
1987 | | - | |
| 1990 | + | |
| 1991 | + | |
1988 | 1992 | | |
1989 | 1993 | | |
1990 | | - | |
| 1994 | + | |
1991 | 1995 | | |
1992 | 1996 | | |
1993 | 1997 | | |
1994 | | - | |
| 1998 | + | |
| 1999 | + | |
1995 | 2000 | | |
1996 | 2001 | | |
1997 | 2002 | | |
1998 | | - | |
| 2003 | + | |
1999 | 2004 | | |
2000 | 2005 | | |
2001 | 2006 | | |
| |||
2161 | 2166 | | |
2162 | 2167 | | |
2163 | 2168 | | |
| 2169 | + | |
| 2170 | + | |
| 2171 | + | |
| 2172 | + | |
| 2173 | + | |
| 2174 | + | |
| 2175 | + | |
| 2176 | + | |
| 2177 | + | |
2164 | 2178 | | |
2165 | 2179 | | |
2166 | 2180 | | |
2167 | | - | |
2168 | | - | |
2169 | | - | |
2170 | | - | |
2171 | | - | |
| 2181 | + | |
| 2182 | + | |
2172 | 2183 | | |
2173 | 2184 | | |
2174 | 2185 | | |
| |||
0 commit comments