make (706:9b7baae18541) make (743:e0f0cd7d244a)
1
2# Copyright (C) Igor Sysoev
3# Copyright (C) Valentin V. Bartenev
4# Copyright (C) NGINX, Inc.
5
6. auto/cc/deps
7
8$echo "creating $NXT_MAKEFILE"

--- 40 unchanged lines hidden (view full) ---

49for nxt_src in $NXT_LIB_SRCS
50do
51 nxt_obj=${nxt_src%.c}.o
52 $echo " $NXT_BUILD_DIR/$nxt_obj \\" >> $NXT_MAKEFILE
53done
54
55$echo >> $NXT_MAKEFILE
56
1
2# Copyright (C) Igor Sysoev
3# Copyright (C) Valentin V. Bartenev
4# Copyright (C) NGINX, Inc.
5
6. auto/cc/deps
7
8$echo "creating $NXT_MAKEFILE"

--- 40 unchanged lines hidden (view full) ---

49for nxt_src in $NXT_LIB_SRCS
50do
51 nxt_obj=${nxt_src%.c}.o
52 $echo " $NXT_BUILD_DIR/$nxt_obj \\" >> $NXT_MAKEFILE
53done
54
55$echo >> $NXT_MAKEFILE
56
57$echo "NXT_LIB_UNIT_OBJS = \\" >> $NXT_MAKEFILE
58$echo " $NXT_BUILD_DIR/src/nxt_lvlhsh.o \\" >> $NXT_MAKEFILE
59$echo " $NXT_BUILD_DIR/src/nxt_murmur_hash.o \\" >> $NXT_MAKEFILE
57
60
61for nxt_src in $NXT_LIB_UNIT_SRCS
62do
63 nxt_obj=${nxt_src%.c}.o
64 $echo " $NXT_BUILD_DIR/$nxt_obj \\" >> $NXT_MAKEFILE
65done
66
67$echo >> $NXT_MAKEFILE
68
69
58# Shared and static library.
59
60cat << END >> $NXT_MAKEFILE
61
62libnxt: $NXT_BUILD_DIR/$NXT_LIB_SHARED $NXT_BUILD_DIR/$NXT_LIB_STATIC
63
64$NXT_BUILD_DIR/$NXT_LIB_SHARED: \$(NXT_LIB_OBJS)
65 \$(NXT_SHARED_LOCAL_LINK) -o $NXT_BUILD_DIR/$NXT_LIB_SHARED \\
66 \$(NXT_LIB_OBJS) \\
67 $NXT_LIBM $NXT_LIBS $NXT_LIB_AUX_LIBS
68
69$NXT_BUILD_DIR/$NXT_LIB_STATIC: \$(NXT_LIB_OBJS)
70 $NXT_STATIC_LINK $NXT_BUILD_DIR/$NXT_LIB_STATIC \\
71 \$(NXT_LIB_OBJS)
72
70# Shared and static library.
71
72cat << END >> $NXT_MAKEFILE
73
74libnxt: $NXT_BUILD_DIR/$NXT_LIB_SHARED $NXT_BUILD_DIR/$NXT_LIB_STATIC
75
76$NXT_BUILD_DIR/$NXT_LIB_SHARED: \$(NXT_LIB_OBJS)
77 \$(NXT_SHARED_LOCAL_LINK) -o $NXT_BUILD_DIR/$NXT_LIB_SHARED \\
78 \$(NXT_LIB_OBJS) \\
79 $NXT_LIBM $NXT_LIBS $NXT_LIB_AUX_LIBS
80
81$NXT_BUILD_DIR/$NXT_LIB_STATIC: \$(NXT_LIB_OBJS)
82 $NXT_STATIC_LINK $NXT_BUILD_DIR/$NXT_LIB_STATIC \\
83 \$(NXT_LIB_OBJS)
84
85$NXT_BUILD_DIR/$NXT_LIB_UNIT_STATIC: \$(NXT_LIB_UNIT_OBJS)
86 $NXT_STATIC_LINK $NXT_BUILD_DIR/$NXT_LIB_UNIT_STATIC \\
87 \$(NXT_LIB_UNIT_OBJS)
88
73END
74
75
76# Object files.
77
89END
90
91
92# Object files.
93
78for nxt_src in $NXT_LIB_SRCS $NXT_TEST_SRCS
94for nxt_src in $NXT_LIB_SRCS $NXT_TEST_SRCS $NXT_LIB_UNIT_SRCS \
95 src/test/nxt_unit_app_test.c
79do
80 nxt_obj=${nxt_src%.c}.o
81 nxt_dep=${nxt_src%.c}.dep
82 nxt_dep_flags=`nxt_gen_dep_flags`
83 nxt_dep_post=`nxt_gen_dep_post`
84 cat << END >> $NXT_MAKEFILE
85
86$NXT_BUILD_DIR/$nxt_obj: $nxt_src

--- 37 unchanged lines hidden (view full) ---

124$NXT_BUILD_DIR/utf8_file_name_test: $NXT_LIB_UTF8_FILE_NAME_TEST_SRCS \\
125 $NXT_BUILD_DIR/$NXT_LIB_STATIC
126 \$(CC) \$(CFLAGS) \$(NXT_LIB_INCS) $NXT_LIB_AUX_CFLAGS \\
127 -o $NXT_BUILD_DIR/utf8_file_name_test \\
128 $NXT_LIB_UTF8_FILE_NAME_TEST_SRCS \\
129 $NXT_BUILD_DIR/$NXT_LIB_STATIC \\
130 $NXT_LD_OPT $NXT_LIBM $NXT_LIBS
131
96do
97 nxt_obj=${nxt_src%.c}.o
98 nxt_dep=${nxt_src%.c}.dep
99 nxt_dep_flags=`nxt_gen_dep_flags`
100 nxt_dep_post=`nxt_gen_dep_post`
101 cat << END >> $NXT_MAKEFILE
102
103$NXT_BUILD_DIR/$nxt_obj: $nxt_src

--- 37 unchanged lines hidden (view full) ---

141$NXT_BUILD_DIR/utf8_file_name_test: $NXT_LIB_UTF8_FILE_NAME_TEST_SRCS \\
142 $NXT_BUILD_DIR/$NXT_LIB_STATIC
143 \$(CC) \$(CFLAGS) \$(NXT_LIB_INCS) $NXT_LIB_AUX_CFLAGS \\
144 -o $NXT_BUILD_DIR/utf8_file_name_test \\
145 $NXT_LIB_UTF8_FILE_NAME_TEST_SRCS \\
146 $NXT_BUILD_DIR/$NXT_LIB_STATIC \\
147 $NXT_LD_OPT $NXT_LIBM $NXT_LIBS
148
149$NXT_BUILD_DIR/unit_app_test: $NXT_BUILD_DIR/src/test/nxt_unit_app_test.o \\
150 $NXT_BUILD_DIR/$NXT_LIB_UNIT_STATIC
151 \$(NXT_EXEC_LINK) -o $NXT_BUILD_DIR/unit_app_test \\
152 \$(CFLAGS) $NXT_BUILD_DIR/src/test/nxt_unit_app_test.o \\
153 $NXT_BUILD_DIR/$NXT_LIB_UNIT_STATIC \\
154 $NXT_LD_OPT $NXT_LIBM $NXT_LIBS $NXT_LIB_AUX_LIBS
155
132END
133
134
135NXT_MAKE_INCS="src $NXT_BUILD_DIR"
136NXT_MAKE_SRCS="$NXT_SRCS"
137
138
139# The include pathes list.

--- 96 unchanged lines hidden (view full) ---

236# Makefile.
237# *.dSYM is MacOSX Clang debug information.
238
239cat << END > Makefile
240
241include $NXT_MAKEFILE
242
243.PHONY: tests
156END
157
158
159NXT_MAKE_INCS="src $NXT_BUILD_DIR"
160NXT_MAKE_SRCS="$NXT_SRCS"
161
162
163# The include pathes list.

--- 96 unchanged lines hidden (view full) ---

260# Makefile.
261# *.dSYM is MacOSX Clang debug information.
262
263cat << END > Makefile
264
265include $NXT_MAKEFILE
266
267.PHONY: tests
244tests: $NXT_BUILD_DIR/tests $NXT_BUILD_DIR/utf8_file_name_test
268tests: $NXT_BUILD_DIR/tests $NXT_BUILD_DIR/utf8_file_name_test \\
269 $NXT_BUILD_DIR/unit_app_test
245
246.PHONY: clean
247clean:
248 rm -rf $NXT_BUILD_DIR *.dSYM Makefile
249
250END
270
271.PHONY: clean
272clean:
273 rm -rf $NXT_BUILD_DIR *.dSYM Makefile
274
275END