mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-pkg
synced 2026-01-15 12:03:31 +01:00
defs.mk: Remove some unnecessary invocations of /bin/pwd
Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
parent
f28afc777c
commit
f502fcd9c2
1 changed files with 18 additions and 5 deletions
23
make/defs.mk
23
make/defs.mk
|
|
@ -36,14 +36,21 @@ BROWSER ?= xdg-open
|
|||
RM := $(shell which rm)
|
||||
AR = /usr/bin/ar
|
||||
PWD := $(shell which pwd)
|
||||
CWD := $(shell $(PWD))
|
||||
BIN_INSTALL := /usr/bin/install
|
||||
SUDO ?= /usr/bin/sudo
|
||||
|
||||
# ----- standard variables
|
||||
ifneq ($(wildcard $(TOPDIR)/.git),)
|
||||
VCS ?= git
|
||||
else ifneq ($(wildcard $(TOPDIR)/CVS),)
|
||||
VCS ?= cvs
|
||||
endif
|
||||
|
||||
CVSTOPDIR ?= $(PROJECTS_DIR)/..
|
||||
|
||||
ifeq ($(PROJECT),)
|
||||
PROJECT := $(patsubst $(FLAVOUR_PREFIX)%,%,$(notdir $(shell cd $(TOPDIR); $(PWD) | $(SED) 's/.*\///; s/-[0-9].*//')))
|
||||
PROJECT := $(patsubst $(FLAVOUR_PREFIX)%,%,$(notdir $(realpath $(TOPDIR))))
|
||||
endif
|
||||
|
||||
GET_OS_SH ?= /bin/bash $(MOD_SCRIPT_DIR)/get-os.sh
|
||||
|
|
@ -121,7 +128,13 @@ CVS_RSH ?= /usr/bin/ssh
|
|||
# ----- input dirs
|
||||
JW_BUILD_DIR = $(MODDIR)
|
||||
PROJECT_STEM = $(PROJECT)-$(DIST_VERSION)
|
||||
CVS_ROOT_DIR = $(shell test -d CVS && $(PWD) | $(SED) -e "s%`$(CAT) CVS/Repository`%%; s%/$$%%")
|
||||
|
||||
# only works if checked out true to CVS, i.e. below proj
|
||||
ifeq ($(VCS),cvs)
|
||||
CVS_MODULE = $(shell $(SED) "s%/$$%%" CVS/Repository)
|
||||
CVS_ROOT_DIR = $(patsubst %/$(CVS_MODULE),%,$(CWD))
|
||||
endif
|
||||
|
||||
REV_SUBDIRS = $(shell echo $(SUBDIRS) | awk '{for (i=NF; i>=1; i--) printf ("%s ",$$i)}')
|
||||
FRESH_CVSDIR = $(HOME)/local/src/cvs.fresh
|
||||
IMAGE_DIR ?= $(CVS_ROOT_DIR)/images
|
||||
|
|
@ -172,7 +185,7 @@ BUILD_USER := $(shell id -un)
|
|||
JANWARE_USER ?= $(BUILD_USER)
|
||||
JANWARE_CLIENT ?= jw
|
||||
JANWARE_WIKI ?= $(JANWARE_CLIENT)
|
||||
JANWARE_URL_DOC_MODULE ?= https://janware.com/wiki/$(JANWARE_WIKI)/assets/types/data/sw/$(PROJECT)/$(notdir $(shell $(PWD)))
|
||||
JANWARE_URL_DOC_MODULE ?= https://janware.com/wiki/$(JANWARE_WIKI)/assets/types/data/sw/$(PROJECT)/$(notdir $(CWD))
|
||||
JANWARE_URL_DOC_PROJECT ?= https://janware.com/wiki/$(JANWARE_WIKI)/assets/types/data/sw/$(PROJECT)/$(PROJECT)
|
||||
PKG_VENDOR ?= janware GmbH
|
||||
|
||||
|
|
@ -560,7 +573,7 @@ INSTALLED_IMG ?= $(addprefix $(INSTALL_IMGDIR)/,$(IMAGES))
|
|||
# -- MO
|
||||
INSTALLATION_FILE_TYPES += MO
|
||||
BUILD_MO ?=
|
||||
BUILD_MODIR ?= $(PWD)
|
||||
BUILD_MODIR ?= $(CWD)
|
||||
INSTALL_MODIR ?= $(ENV_PREFIX)/usr/share/locale/$(GETTEXT_LOCALE)/LC_MESSAGES
|
||||
INSTALLED_MO ?= $(addprefix $(INSTALL_MODIR)/,$(wildcard *.mo))
|
||||
|
||||
|
|
@ -771,7 +784,7 @@ else
|
|||
endif
|
||||
|
||||
define install_links
|
||||
cwd=`$(PWD)`; \
|
||||
cwd="$(CWD)"; \
|
||||
echo "o in $(INSTALL_$(1)DIR):" ;\
|
||||
for f in $(notdir $(INSTALLED_$(1))); do \
|
||||
cd $(INSTALL_$(1)DIR); \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue