build: all now builds static and dynamic lib
The `make all` target now builds both libuv.a and libuv.{so,dylib}
rather than just libuv.a.
This commit is contained in:
parent
5841852703
commit
88a2c7ff20
6
build.mk
6
build.mk
@ -143,7 +143,7 @@ TESTS= \
|
|||||||
test/test-util.o \
|
test/test-util.o \
|
||||||
test/test-walk-handles.o \
|
test/test-walk-handles.o \
|
||||||
|
|
||||||
all: libuv.a
|
.PHONY: all bench clean clean-platform distclean test
|
||||||
|
|
||||||
run-tests$(E): test/run-tests.o test/runner.o $(RUNNER_SRC) $(TESTS) libuv.a
|
run-tests$(E): test/run-tests.o test/runner.o $(RUNNER_SRC) $(TESTS) libuv.a
|
||||||
$(CC) $(CPPFLAGS) $(RUNNER_CFLAGS) -o $@ $^ $(RUNNER_LIBS) $(RUNNER_LDFLAGS)
|
$(CC) $(CPPFLAGS) $(RUNNER_CFLAGS) -o $@ $^ $(RUNNER_LIBS) $(RUNNER_LDFLAGS)
|
||||||
@ -153,10 +153,6 @@ run-benchmarks$(E): test/run-benchmarks.o test/runner.o $(RUNNER_SRC) $(BENCHMAR
|
|||||||
|
|
||||||
test/echo.o: test/echo.c test/echo.h
|
test/echo.o: test/echo.c test/echo.h
|
||||||
|
|
||||||
|
|
||||||
.PHONY: clean clean-platform distclean test bench
|
|
||||||
|
|
||||||
|
|
||||||
test: run-tests$(E)
|
test: run-tests$(E)
|
||||||
$(CURDIR)/$<
|
$(CURDIR)/$<
|
||||||
|
|
||||||
|
|||||||
@ -29,7 +29,7 @@ CPPFLAGS += -D_FILE_OFFSET_BITS=64
|
|||||||
|
|
||||||
RUNNER_SRC=test/runner-unix.c
|
RUNNER_SRC=test/runner-unix.c
|
||||||
RUNNER_CFLAGS=$(CFLAGS) -I$(SRCDIR)/test
|
RUNNER_CFLAGS=$(CFLAGS) -I$(SRCDIR)/test
|
||||||
RUNNER_LDFLAGS=-L"$(CURDIR)" -luv
|
RUNNER_LDFLAGS=
|
||||||
|
|
||||||
DTRACE_OBJS=
|
DTRACE_OBJS=
|
||||||
DTRACE_HEADER=
|
DTRACE_HEADER=
|
||||||
@ -159,6 +159,13 @@ endif
|
|||||||
|
|
||||||
RUNNER_LDFLAGS += $(LDFLAGS)
|
RUNNER_LDFLAGS += $(LDFLAGS)
|
||||||
|
|
||||||
|
all:
|
||||||
|
# Force a sequential build of the static and the shared library.
|
||||||
|
# Works around a make quirk where it forgets to (re)build either
|
||||||
|
# the *.o or *.pic.o files, depending on what target comes first.
|
||||||
|
$(MAKE) -f $(SRCDIR)/Makefile libuv.a
|
||||||
|
$(MAKE) -f $(SRCDIR)/Makefile libuv.$(SOEXT)
|
||||||
|
|
||||||
libuv.a: $(OBJS)
|
libuv.a: $(OBJS)
|
||||||
$(AR) rcs $@ $^
|
$(AR) rcs $@ $^
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user