mirror of
https://github.com/servo/servo.git
synced 2025-08-07 14:35:33 +01:00
Makefile cleanups
This commit is contained in:
parent
7d0521eb90
commit
7d785c364f
1 changed files with 70 additions and 43 deletions
113
Makefile.in
113
Makefile.in
|
@ -39,35 +39,36 @@ SERVO_DEPS = \
|
||||||
CHECK_DEPS =
|
CHECK_DEPS =
|
||||||
CLEAN_DEPS =
|
CLEAN_DEPS =
|
||||||
AZURE_DEPS = \
|
AZURE_DEPS = \
|
||||||
src/rust-geom/libgeom.dummy
|
rust-geom
|
||||||
GLUT_DEPS = \
|
GLUT_DEPS = \
|
||||||
src/rust-opengles/libopengles.dummy
|
rust-opengles
|
||||||
LAYERS_DEPS = \
|
LAYERS_DEPS = \
|
||||||
src/rust-geom/libgeom.dummy \
|
rust-geom \
|
||||||
src/rust-opengles/libopengles.dummy \
|
rust-opengles \
|
||||||
src/rust-glut/libglut.dummy \
|
rust-glut \
|
||||||
src/rust-azure/libazure.dummy \
|
rust-azure
|
||||||
|
|
||||||
ifeq ($(OSTYPE),darwin)
|
ifeq ($(OSTYPE),darwin)
|
||||||
SERVO_DEPS += src/rust-cocoa/libcocoa.dummy
|
SERVO_DEPS += rust-cocoa
|
||||||
# I want the cocoa check to come before the servo check since if cocoa
|
# I want the cocoa check to come before the servo check since if cocoa
|
||||||
# doesn't work neither does servo
|
# doesn't work neither does servo
|
||||||
CHECK_DEPS += check-rust-cocoa
|
CHECK_DEPS += check-rust-cocoa
|
||||||
CLEAN_DEPS += clean-rust-cocoa
|
CLEAN_DEPS += clean-rust-cocoa
|
||||||
AZURE_DEPS += src/rust-cocoa/libcocoa.dummy src/rust-geom/libgeom.dummy
|
AZURE_DEPS += rust-cocoa
|
||||||
LAYERS_DEPS += src/rust-cocoa/libcocoa.dummy
|
LAYERS_DEPS += rust-cocoa
|
||||||
endif
|
endif
|
||||||
|
|
||||||
SERVO_DEPS += \
|
SERVO_DEPS += \
|
||||||
src/rust-harfbuzz/libharfbuzz.dummy \
|
mozjs \
|
||||||
src/rust-mozjs/libmozjs.dummy \
|
rust-harfbuzz \
|
||||||
src/rust-azure/libazure.dummy \
|
rust-mozjs \
|
||||||
src/rust-stb-image/libstb-image.dummy \
|
rust-azure \
|
||||||
src/rust-geom/libgeom.dummy \
|
rust-stb-image \
|
||||||
src/rust-opengles/libopengles.dummy \
|
rust-geom \
|
||||||
src/rust-glut/libglut.dummy \
|
rust-opengles \
|
||||||
src/rust-layers/liblayers.dummy \
|
rust-glut \
|
||||||
src/rust-http-client/libhttp_client.dummy \
|
rust-layers \
|
||||||
|
rust-http-client \
|
||||||
$(NULL)
|
$(NULL)
|
||||||
|
|
||||||
CHECK_DEPS += \
|
CHECK_DEPS += \
|
||||||
|
@ -97,9 +98,13 @@ CLEAN_DEPS += \
|
||||||
clean-servo \
|
clean-servo \
|
||||||
$(NULL)
|
$(NULL)
|
||||||
|
|
||||||
|
|
||||||
.PHONY: all
|
.PHONY: all
|
||||||
all: servo package
|
all: servo package
|
||||||
|
|
||||||
|
|
||||||
|
# Servo binaries
|
||||||
|
|
||||||
servo: $(SERVO_DEPS)
|
servo: $(SERVO_DEPS)
|
||||||
$(RUSTC) $(RUSTFLAGS) $(RUSTLIBS) -o $@ $< --bin
|
$(RUSTC) $(RUSTFLAGS) $(RUSTLIBS) -o $@ $< --bin
|
||||||
|
|
||||||
|
@ -109,13 +114,45 @@ libservo.dummy: $(SERVO_DEPS)
|
||||||
servo-test: $(SERVO_DEPS)
|
servo-test: $(SERVO_DEPS)
|
||||||
$(RUSTC) $(RUSTFLAGS) $(RUSTLIBS) --test -o $@ $<
|
$(RUSTC) $(RUSTFLAGS) $(RUSTLIBS) --test -o $@ $<
|
||||||
|
|
||||||
|
|
||||||
|
# Convenient sub-project targets
|
||||||
|
|
||||||
|
.PHONY: mozjs rust-harfbuzz rust-mozjs rust-azure rust-cocoa \
|
||||||
|
rust-stb-image rust-geom rust-opengles rust-glut rust-layers \
|
||||||
|
rust-http-client
|
||||||
|
|
||||||
|
mozjs: src/mozjs/libjs_static.a
|
||||||
|
|
||||||
|
rust-harfbuzz: src/rust-harfbuzz/libharfbuzz.dummy
|
||||||
|
|
||||||
|
rust-mozjs: src/rust-mozjs/libmozjs.dummy
|
||||||
|
|
||||||
|
rust-azure: src/rust-azure/libazure.dummy
|
||||||
|
|
||||||
|
rust-cocoa: src/rust-cocoa/libcocoa.dummy
|
||||||
|
|
||||||
|
rust-stb-image: src/rust-stb-image/libstb-image.dummy
|
||||||
|
|
||||||
|
rust-geom: src/rust-geom/libgeom.dummy
|
||||||
|
|
||||||
|
rust-opengles: src/rust-opengles/libopengles.dummy
|
||||||
|
|
||||||
|
rust-glut: src/rust-glut/libglut.dummy
|
||||||
|
|
||||||
|
rust-layers: src/rust-layers/liblayers.dummy
|
||||||
|
|
||||||
|
rust-http-client: src/rust-http-client/libhttp_client.dummy
|
||||||
|
|
||||||
|
|
||||||
|
# Subproject rules
|
||||||
|
|
||||||
src/mozjs/libjs_static.a:
|
src/mozjs/libjs_static.a:
|
||||||
$(MAKE) -C src/mozjs
|
$(MAKE) -C src/mozjs
|
||||||
|
|
||||||
src/rust-harfbuzz/libharfbuzz.dummy:
|
src/rust-harfbuzz/libharfbuzz.dummy:
|
||||||
$(MAKE) -C src/rust-harfbuzz
|
$(MAKE) -C src/rust-harfbuzz
|
||||||
|
|
||||||
src/rust-mozjs/libmozjs.dummy: src/mozjs/libjs_static.a
|
src/rust-mozjs/libmozjs.dummy: mozjs
|
||||||
RUSTFLAGS="$(RUSTFLAGS) -L ../mozjs/" CFLAGS="-I../mozjs/dist/include" \
|
RUSTFLAGS="$(RUSTFLAGS) -L ../mozjs/" CFLAGS="-I../mozjs/dist/include" \
|
||||||
$(MAKE) -C src/rust-mozjs
|
$(MAKE) -C src/rust-mozjs
|
||||||
|
|
||||||
|
@ -144,104 +181,94 @@ src/rust-layers/liblayers.dummy: $(LAYERS_DEPS)
|
||||||
src/rust-http-client/libhttp_client.dummy:
|
src/rust-http-client/libhttp_client.dummy:
|
||||||
$(MAKE) -C src/rust-http-client
|
$(MAKE) -C src/rust-http-client
|
||||||
|
|
||||||
|
|
||||||
|
# Testing targets
|
||||||
|
|
||||||
|
.PHONY: check $(CHECK_DEPS)
|
||||||
|
|
||||||
check: $(CHECK_DEPS)
|
check: $(CHECK_DEPS)
|
||||||
|
|
||||||
check-servo: servo-test
|
check-servo: servo-test
|
||||||
./servo-test $(TESTNAME)
|
./servo-test $(TESTNAME)
|
||||||
|
|
||||||
.PHONY: check-rust-harfbuzz
|
|
||||||
check-rust-harfbuzz:
|
check-rust-harfbuzz:
|
||||||
$(MAKE) check -C src/rust-harfbuzz
|
$(MAKE) check -C src/rust-harfbuzz
|
||||||
|
|
||||||
.PHONY: check-rust-mozjs
|
check-rust-mozjs: mozjs
|
||||||
check-rust-mozjs: src/mozjs/libjs_static.a
|
|
||||||
RUSTFLAGS="$(RUSTFLAGS) -L ../mozjs/" CFLAGS="-I../mozjs/dist/include" \
|
RUSTFLAGS="$(RUSTFLAGS) -L ../mozjs/" CFLAGS="-I../mozjs/dist/include" \
|
||||||
$(MAKE) check -C src/rust-mozjs
|
$(MAKE) check -C src/rust-mozjs
|
||||||
|
|
||||||
.PHONY: check-rust-azure
|
|
||||||
check-rust-azure: $(AZURE_DEPS)
|
check-rust-azure: $(AZURE_DEPS)
|
||||||
RUSTFLAGS="$(RUSTFLAGS) -L ../rust-cocoa -L ../rust-geom" $(MAKE) check -C src/rust-azure
|
RUSTFLAGS="$(RUSTFLAGS) -L ../rust-cocoa -L ../rust-geom" $(MAKE) check -C src/rust-azure
|
||||||
|
|
||||||
.PHONY: check-rust-cocoa
|
|
||||||
check-rust-cocoa:
|
check-rust-cocoa:
|
||||||
$(MAKE) check -C src/rust-cocoa
|
$(MAKE) check -C src/rust-cocoa
|
||||||
|
|
||||||
.PHONY: check-rust-stb-image
|
|
||||||
check-rust-stb-image:
|
check-rust-stb-image:
|
||||||
$(MAKE) check -C src/rust-stb-image
|
$(MAKE) check -C src/rust-stb-image
|
||||||
|
|
||||||
.PHONY: check-rust-geom
|
|
||||||
check-rust-geom:
|
check-rust-geom:
|
||||||
$(MAKE) check -C src/rust-geom
|
$(MAKE) check -C src/rust-geom
|
||||||
|
|
||||||
.PHONY: check-rust-opengles
|
|
||||||
check-rust-opengles:
|
check-rust-opengles:
|
||||||
$(MAKE) check -C src/rust-opengles
|
$(MAKE) check -C src/rust-opengles
|
||||||
|
|
||||||
.PHONY: check-rust-glut
|
|
||||||
check-rust-glut: $(GLUT_DEPS)
|
check-rust-glut: $(GLUT_DEPS)
|
||||||
RUSTFLAGS="$(RUSTFLAGS) -L ../rust-opengles" $(MAKE) check -C src/rust-glut
|
RUSTFLAGS="$(RUSTFLAGS) -L ../rust-opengles" $(MAKE) check -C src/rust-glut
|
||||||
|
|
||||||
.PHONY: check-rust-layers
|
|
||||||
check-rust-layers: $(LAYERS_DEPS)
|
check-rust-layers: $(LAYERS_DEPS)
|
||||||
RUSTFLAGS="$(RUSTFLAGS) -L ../rust-geom -L ../rust-opengles -L ../rust-glut -L ../rust-azure -L ../rust-cocoa" \
|
RUSTFLAGS="$(RUSTFLAGS) -L ../rust-geom -L ../rust-opengles -L ../rust-glut -L ../rust-azure -L ../rust-cocoa" \
|
||||||
$(MAKE) check -C src/rust-layers
|
$(MAKE) check -C src/rust-layers
|
||||||
|
|
||||||
.PHONY: check-rust-http-client
|
|
||||||
check-rust-http-client:
|
check-rust-http-client:
|
||||||
$(MAKE) check -C src/rust-http-client
|
$(MAKE) check -C src/rust-http-client
|
||||||
|
|
||||||
.PHONY: clean
|
|
||||||
|
# Clean targets
|
||||||
|
|
||||||
|
.PHONY: clean $(CLEAN_DEPS)
|
||||||
|
|
||||||
clean: $(CLEAN_DEPS)
|
clean: $(CLEAN_DEPS)
|
||||||
|
|
||||||
.PHONY: clean-rust-harfbuzz
|
|
||||||
clean-rust-harfbuzz:
|
clean-rust-harfbuzz:
|
||||||
$(MAKE) clean -C src/rust-harfbuzz
|
$(MAKE) clean -C src/rust-harfbuzz
|
||||||
|
|
||||||
.PHONY: clean-mozjs
|
|
||||||
clean-mozjs:
|
clean-mozjs:
|
||||||
$(MAKE) clean -C src/mozjs
|
$(MAKE) clean -C src/mozjs
|
||||||
|
|
||||||
.PHONY: clean-rust-mozjs
|
|
||||||
clean-rust-mozjs:
|
clean-rust-mozjs:
|
||||||
$(MAKE) clean -C src/rust-mozjs
|
$(MAKE) clean -C src/rust-mozjs
|
||||||
|
|
||||||
.PHONY: clean-rust-azure
|
|
||||||
clean-rust-azure:
|
clean-rust-azure:
|
||||||
$(MAKE) clean -C src/rust-azure
|
$(MAKE) clean -C src/rust-azure
|
||||||
|
|
||||||
.PHONY: clean-rust-cocoa
|
|
||||||
clean-rust-cocoa:
|
clean-rust-cocoa:
|
||||||
$(MAKE) clean -C src/rust-cocoa
|
$(MAKE) clean -C src/rust-cocoa
|
||||||
|
|
||||||
.PHONY: clean-rust-stb-image
|
|
||||||
clean-rust-stb-image:
|
clean-rust-stb-image:
|
||||||
$(MAKE) clean -C src/rust-stb-image
|
$(MAKE) clean -C src/rust-stb-image
|
||||||
|
|
||||||
.PHONY: clean-rust-geom
|
|
||||||
clean-rust-geom:
|
clean-rust-geom:
|
||||||
$(MAKE) clean -C src/rust-geom
|
$(MAKE) clean -C src/rust-geom
|
||||||
|
|
||||||
.PHONY: clean-rust-opengles
|
|
||||||
clean-rust-opengles:
|
clean-rust-opengles:
|
||||||
$(MAKE) clean -C src/rust-opengles
|
$(MAKE) clean -C src/rust-opengles
|
||||||
|
|
||||||
.PHONY: clean-rust-glut
|
|
||||||
clean-rust-glut:
|
clean-rust-glut:
|
||||||
$(MAKE) clean -C src/rust-glut
|
$(MAKE) clean -C src/rust-glut
|
||||||
|
|
||||||
.PHONY: clean-rust-layers
|
|
||||||
clean-rust-layers:
|
clean-rust-layers:
|
||||||
$(MAKE) clean -C src/rust-layers
|
$(MAKE) clean -C src/rust-layers
|
||||||
|
|
||||||
.PHONY: clean-rust-http-client
|
|
||||||
clean-rust-http-client:
|
clean-rust-http-client:
|
||||||
$(MAKE) clean -C src/rust-http-client
|
$(MAKE) clean -C src/rust-http-client
|
||||||
|
|
||||||
.PHONY: clean-servo
|
|
||||||
clean-servo:
|
clean-servo:
|
||||||
rm -f servo servo-test
|
rm -f servo servo-test
|
||||||
|
|
||||||
|
|
||||||
|
# Darwin app packaging
|
||||||
|
|
||||||
ifeq ($(OSTYPE),darwin)
|
ifeq ($(OSTYPE),darwin)
|
||||||
|
|
||||||
package: servo
|
package: servo
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue