]> arthur.barton.de Git - bup.git/blobdiff - GNUmakefile
README: fix and simplify cirrus badges
[bup.git] / GNUmakefile
index f07a3b5a59a15d402cc4dd4fdffed42b0c831757..30f1b3a1cacab7f09f61da6c57f7e7c3c579d58c 100644 (file)
@@ -69,7 +69,7 @@ config/config.vars: configure config/configure config/configure.inc config/*.in
 # _XOPEN_SOURCE version, i.e. -Werror crashes on a mismatch, so for
 # now, we're just going to let Python's version win.
 
-helpers_cflags := $(bup_python_cflags) $(bup_shared_cflags)
+helpers_cflags := $(bup_python_cflags) $(bup_shared_cflags) -I$(CURDIR)/src
 helpers_ldflags := $(bup_python_ldflags) $(bup_shared_ldflags)
 
 ifneq ($(strip $(bup_readline_cflags)),)
@@ -132,7 +132,8 @@ install: all
        $(INSTALL) -pm 0755 lib/cmd/bup "$(dest_libdir)/cmd/bup"
        $(INSTALL) -pm 0755 $(bup_ext_cmds) "$(dest_libdir)/cmd/"
        cd "$(dest_bindir)" && \
-         ln -sf "$$($(bup_python) -c 'import os; print(os.path.relpath("$(abspath $(dest_libdir))/cmd/bup"))')"
+         ln -sf "$$($(CURDIR)/dev/python -c 'import os; print(os.path.relpath("$(abspath $(dest_libdir))/cmd/bup"))')" \
+           .
        set -e; \
        $(INSTALL) -pm 0644 lib/bup/*.py $(dest_libdir)/bup/
        $(INSTALL) -pm 0644 lib/bup/cmd/*.py $(dest_libdir)/bup/cmd/
@@ -205,12 +206,16 @@ get_parallel_n = $(patsubst -j%,%,$(parallel_opt))
 maybe_specific_n = $(if $(filter -j%,$(parallel_opt)),-n$(get_parallel_n))
 xdist_opt = $(if $(filter -j,$(parallel_opt)),-nauto,$(maybe_specific_n))
 
-test: all test/tmp dev/python
-        if test yes = "$$(dev/python -c 'import xdist; print("yes")' 2>/dev/null)"; then \
+lint: dev/bup-exec dev/bup-python
+       ./pylint
+
+test: all test/tmp dev/python lint
+       ./bup features
+       if test yes = "$$(dev/python -c 'import xdist; print("yes")' 2>/dev/null)"; then \
           (set -x; ./pytest $(xdist_opt);) \
-        else \
-          (set -x; ./pytest;) \
-        fi
+       else \
+         (set -x; ./pytest;) \
+       fi
 
 stupid:
        PATH=/bin:/usr/bin $(MAKE) test