2014-02-25 09:55:36 -05:00
|
|
|
-include local.mk
|
|
|
|
|
2014-02-26 14:16:54 -05:00
|
|
|
CMAKE_FLAGS := -DCMAKE_BUILD_TYPE=Debug -DCMAKE_PREFIX_PATH=.deps/usr -DLibUV_USE_STATIC=YES
|
2014-01-31 08:39:15 -05:00
|
|
|
|
2014-02-24 19:22:48 -05:00
|
|
|
# Extra CMake flags which extend the default set
|
2014-02-26 14:16:54 -05:00
|
|
|
CMAKE_EXTRA_FLAGS :=
|
2014-02-24 19:22:48 -05:00
|
|
|
|
2014-02-28 21:32:25 -05:00
|
|
|
# For use where we want to make sure only a single job is run. This also avoids
|
|
|
|
# any warnings from the sub-make.
|
|
|
|
SINGLE_MAKE = export MAKEFLAGS= ; $(MAKE)
|
|
|
|
|
2014-02-24 14:57:47 -05:00
|
|
|
build/bin/nvim: deps
|
2014-02-28 21:32:25 -05:00
|
|
|
$(MAKE) -C build
|
2014-01-31 08:39:15 -05:00
|
|
|
|
2014-02-24 14:57:47 -05:00
|
|
|
test: build/bin/nvim
|
2014-02-28 21:32:25 -05:00
|
|
|
$(SINGLE_MAKE) -C src/testdir
|
2014-02-01 09:27:24 -05:00
|
|
|
|
2014-02-27 14:57:06 -05:00
|
|
|
unittest: build/bin/nvim
|
|
|
|
sh -e scripts/unittest.sh
|
|
|
|
|
|
|
|
deps: .deps/usr/lib/libuv.a .deps/usr/lib/libluajit-5.1.a .deps/usr/bin/busted
|
2014-02-01 09:20:02 -05:00
|
|
|
|
|
|
|
.deps/usr/lib/libuv.a:
|
2014-02-24 05:04:42 -05:00
|
|
|
sh -e scripts/compile-libuv.sh
|
2014-02-01 09:20:02 -05:00
|
|
|
|
2014-02-27 14:57:06 -05:00
|
|
|
.deps/usr/lib/libluajit-5.1.a:
|
|
|
|
sh -e scripts/compile-lua.sh
|
|
|
|
|
|
|
|
.deps/usr/bin/busted:
|
|
|
|
sh -e scripts/setup-test-tools.sh
|
|
|
|
|
2014-02-24 16:00:39 -05:00
|
|
|
cmake: clean deps
|
2014-01-31 08:39:15 -05:00
|
|
|
mkdir build
|
2014-02-24 19:22:48 -05:00
|
|
|
cd build && cmake $(CMAKE_FLAGS) $(CMAKE_EXTRA_FLAGS) ../
|
2014-01-31 08:39:15 -05:00
|
|
|
|
2014-02-01 09:20:02 -05:00
|
|
|
clean:
|
|
|
|
rm -rf build
|
2014-02-28 21:32:25 -05:00
|
|
|
$(MAKE) -C src/testdir clean
|
2014-03-11 14:11:46 -04:00
|
|
|
$(MAKE) -C test/includes clean
|
2014-02-01 09:20:02 -05:00
|
|
|
|
2014-02-24 19:04:51 -05:00
|
|
|
install: build/bin/nvim
|
2014-02-28 21:32:25 -05:00
|
|
|
$(MAKE) -C build install
|
2014-02-24 19:04:51 -05:00
|
|
|
|
2014-02-27 16:31:45 -05:00
|
|
|
.PHONY: test unittest deps cmake install
|
2014-02-01 09:27:24 -05:00
|
|
|
|
2014-02-24 14:57:47 -05:00
|
|
|
.DEFAULT: build/bin/nvim
|