From 85a2c290f922f648e5e9f0e69c03116f2d0aeaa6 Mon Sep 17 00:00:00 2001 From: Akshay Nair Date: Sun, 6 Apr 2025 20:23:55 +0530 Subject: Change build setup to install lua prefix correctly + static build libluv --- Makefile | 32 +++++++++++++++++++------------- 1 file changed, 19 insertions(+), 13 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 8e341db..bd58185 100644 --- a/Makefile +++ b/Makefile @@ -1,36 +1,42 @@ -.PHONY: clean build build-release test check +.PHONY: clean build build-release build-source test run check -all: build +all: build-dev PREFIX = "${PWD}/build/installdir" +LUA_PREFIX = "" -build: +build-source: @mkdir -p build - @cd build/ && cmake .. -DCMAKE_INSTALL_PREFIX="${PREFIX}" && make -j12 - # cp --no-preserve=mode,ownership -r ${CEF_PACKAGE_PATH}/lib/* ./build/lib/ - # cp --no-preserve=mode,ownership -r ${CEF_PACKAGE_PATH}/share/cef/* ./build/lib/ + @cd build/ && cmake .. \ + -DNULL_LUA_PREFIX="${LUA_PREFIX}" \ + -DCMAKE_INSTALL_PREFIX="${PREFIX}" \ + && make -j8 + +dev-setup: @cp build/compile_commands.json . -install: build-release +build-dev: build-source dev-setup + +build: + RELEASE=1 make build-source LUA_PREFIX="${PREFIX}/lua" + +install: cd build && cmake --install . --prefix "${PREFIX}" -test: build +test: build-source cd build && QT_QPA_PLATFORM=offscreen ctest -V clean: rm -rf build/ rm -f compile_commands.json -run: build +run: build-dev ./build/null-browser debug: - DEBUG=1 make build + DEBUG=1 make build-dev gdb ./build/null-browser -build-release: - RELEASE=1 make build - check: clang-format -i ./src/**/*.{hpp,cpp} clang-tidy --config-file=.clang-tidy ./src/**/*.{hpp,cpp} -- cgit v1.3.1