mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-pkg
synced 2026-01-15 20:13:32 +01:00
This commit removes everything not strictly necessary for running "make clean all" inside jw-build. packaging jw-devtest. This cuts the repo down from 24077 to 4725 lines of code. The idea is to 1) Further remove bloat from the remaining bits 2) Re-add what's necessary to build and package other essential repos. The decision should be based on whether or not jw-build can also be useful in a non-janware context. Signed-off-by: Jan Lindemann <jan@janware.com>
41 lines
1.6 KiB
Makefile
41 lines
1.6 KiB
Makefile
#
|
|
# SPDX-License-Identifier: LGPL-2.0-only
|
|
#
|
|
# Makefile for managing multiple software repositories in one tree
|
|
#
|
|
# (C) Copyright 2001-2025, Jan Lindemann <jan@janware.com>
|
|
#
|
|
# This is the top-level Makefile for a janware software build tree. It is
|
|
# provided under the terms of the GNU Lesser Public License, Version 2.
|
|
#
|
|
# Some of its targets download software from janware GmbH servers. For those,
|
|
# you will need a janware.com user account. Ask admin@janware.com if you want
|
|
# one, then define the JANWARE_USER = <janware user name> environment variable.
|
|
#
|
|
# Current documentation on how this Makefile is meant to be used can be found
|
|
# under https://janware.com/wiki/pub/en/sw/build/. Running "make help" might
|
|
# take you there semi-automatically.
|
|
#
|
|
|
|
PROJECTS_MAKEFILE_NAME := $(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST))
|
|
JWBDIR_GIT_REMOTE ?= ssh://$(JANWARE_USER)@git.janware.com/srv/git/jan/proj/jw-build
|
|
JWBDIR ?= $(notdir $(JWBDIR_GIT_REMOTE))
|
|
PROJECTS_DIR_INCLUDE_MK = $(JWBDIR)/make/projects-dir-include.mk
|
|
|
|
ifndef JANWARE_USER
|
|
JANWARE_USER = $(shell id -un)
|
|
$(warning Assuming JANWARE_USER=$(JANWARE_USER) from id -un)
|
|
$(warning Explicitly set environment variable JANWARE_USER to turn off this warning!)
|
|
endif
|
|
|
|
-include local.mk
|
|
|
|
all:
|
|
|
|
include $(PROJECTS_DIR_INCLUDE_MK)
|
|
|
|
$(PROJECTS_DIR_INCLUDE_MK):
|
|
git clone $(JWBDIR_GIT_REMOTE) $(JWBDIR)
|
|
[ -L $(PROJECTS_MAKEFILE_NAME) ] || \
|
|
ln -sf `find $(JWBDIR) -type f -print0 | xargs -0 grep -l some-random-string-to-id-this-makefile` \
|
|
$(PROJECTS_MAKEFILE_NAME)
|