From b62203729f192954922411c15e2eee92595bb2df Mon Sep 17 00:00:00 2001 From: mattias Date: Wed, 15 Jul 2020 08:18:38 +0000 Subject: [PATCH] make install: check if LAZARUS_INSTALL_DIR already set, issue #37356 git-svn-id: trunk@63564 - --- Makefile | 7 ++++++- Makefile.fpc | 8 +++++++- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index a33c66f249..dc5aa2be52 100644 --- a/Makefile +++ b/Makefile @@ -349,13 +349,18 @@ endif override PACKAGE_NAME=lazarus override PACKAGE_VERSION=$(IDEVERSION) RCPP?=$(strip $(firstword cpp$(SRCEXEEXT))) +ifndef LAZARUS_INSTALL_DIR LAZARUS_INSTALL_DIR=$(INSTALL_PREFIX)/share/lazarus INSTALL_MAN_DIR=$(INSTALL_PREFIX)/share/man ifneq ($(findstring $(OS_TARGET),win32 win64),) LAZARUS_INSTALL_DIR=C:\lazarus endif ifneq ($(findstring $(OS_TARGET),freebsd),) -LAZARUS_INSTALL_DIR=/usr/local/lazarus +LAZARUS_INSTALL_DIR=$(INSTALL_PREFIX)/local/lazarus +endif +endif +ifndef INSTALL_MAN_DIR +INSTALL_MAN_DIR=$(INSTALL_PREFIX)/share/man endif ifneq ($(findstring $(OS_TARGET),win32 win64),) IDEVERSION=$(shell .\tools\install\get_lazarus_version.bat) diff --git a/Makefile.fpc b/Makefile.fpc index cd6495b0f8..a00e6eb1b7 100644 --- a/Makefile.fpc +++ b/Makefile.fpc @@ -28,14 +28,20 @@ destdir=$(BASEDIR)/dist [prerules] RCPP?=$(strip $(firstword cpp$(SRCEXEEXT))) # +ifndef LAZARUS_INSTALL_DIR LAZARUS_INSTALL_DIR=$(INSTALL_PREFIX)/share/lazarus INSTALL_MAN_DIR=$(INSTALL_PREFIX)/share/man ifneq ($(findstring $(OS_TARGET),win32 win64),) LAZARUS_INSTALL_DIR=C:\lazarus endif ifneq ($(findstring $(OS_TARGET),freebsd),) -LAZARUS_INSTALL_DIR=/usr/local/lazarus +LAZARUS_INSTALL_DIR=$(INSTALL_PREFIX)/local/lazarus endif +endif +ifndef INSTALL_MAN_DIR +INSTALL_MAN_DIR=$(INSTALL_PREFIX)/share/man +endif + ifneq ($(findstring $(OS_TARGET),win32 win64),) IDEVERSION=$(shell .\tools\install\get_lazarus_version.bat) else