mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-26 23:32:58 +00:00
Add an optional separate install prefix for internal components. rdar://10217046
Some files installed by clang are not relevant for general users and we'd like to be able to install them to a different location. This adds a new --with-internal-prefix configure option and a corresponding PROJ_internal_prefix makefile variable, which defaults to the standard prefix. A tool makefile can specify that it should be installed to this internal prefix by defining INTERNAL_TOOL. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145234 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
f86186ee24
commit
ae7e2a4bbb
@ -86,6 +86,13 @@ PROJ_VERSION := 1.0
|
|||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
INTERNAL_PREFIX := @INTERNAL_PREFIX@
|
||||||
|
ifneq ($(INTERNAL_PREFIX),)
|
||||||
|
PROJ_internal_prefix := $(INTERNAL_PREFIX)
|
||||||
|
else
|
||||||
|
PROJ_internal_prefix := $(prefix)
|
||||||
|
endif
|
||||||
|
|
||||||
PROJ_bindir := $(PROJ_prefix)/bin
|
PROJ_bindir := $(PROJ_prefix)/bin
|
||||||
PROJ_libdir := $(PROJ_prefix)/lib
|
PROJ_libdir := $(PROJ_prefix)/lib
|
||||||
PROJ_datadir := $(PROJ_prefix)/share
|
PROJ_datadir := $(PROJ_prefix)/share
|
||||||
|
@ -1503,12 +1503,19 @@ install-local::
|
|||||||
uninstall-local::
|
uninstall-local::
|
||||||
$(Echo) Uninstall circumvented with NO_INSTALL
|
$(Echo) Uninstall circumvented with NO_INSTALL
|
||||||
else
|
else
|
||||||
DestTool = $(DESTDIR)$(PROJ_bindir)/$(TOOLEXENAME)
|
|
||||||
|
ifdef INTERNAL_TOOL
|
||||||
|
ToolBinDir = $(DESTDIR)$(PROJ_internal_prefix)/bin
|
||||||
|
else
|
||||||
|
ToolBinDir = $(DESTDIR)$(PROJ_bindir)
|
||||||
|
endif
|
||||||
|
DestTool = $(ToolBinDir)/$(TOOLEXENAME)
|
||||||
|
|
||||||
install-local:: $(DestTool)
|
install-local:: $(DestTool)
|
||||||
|
|
||||||
$(DestTool): $(ToolBuildPath) $(DESTDIR)$(PROJ_bindir)
|
$(DestTool): $(ToolBuildPath)
|
||||||
$(Echo) Installing $(BuildMode) $(DestTool)
|
$(Echo) Installing $(BuildMode) $(DestTool)
|
||||||
|
$(Verb) $(MKDIR) $(ToolBinDir)
|
||||||
$(Verb) $(ProgInstall) $(ToolBuildPath) $(DestTool)
|
$(Verb) $(ProgInstall) $(ToolBuildPath) $(DestTool)
|
||||||
|
|
||||||
uninstall-local::
|
uninstall-local::
|
||||||
@ -1517,7 +1524,7 @@ uninstall-local::
|
|||||||
|
|
||||||
# TOOLALIAS install.
|
# TOOLALIAS install.
|
||||||
ifdef TOOLALIAS
|
ifdef TOOLALIAS
|
||||||
DestToolAlias = $(DESTDIR)$(PROJ_bindir)/$(TOOLALIAS)$(EXEEXT)
|
DestToolAlias = $(ToolBinDir)/$(TOOLALIAS)$(EXEEXT)
|
||||||
|
|
||||||
install-local:: $(DestToolAlias)
|
install-local:: $(DestToolAlias)
|
||||||
|
|
||||||
@ -2276,6 +2283,7 @@ printvars::
|
|||||||
$(Echo) "LLVM_SRC_ROOT: " '$(LLVM_SRC_ROOT)'
|
$(Echo) "LLVM_SRC_ROOT: " '$(LLVM_SRC_ROOT)'
|
||||||
$(Echo) "LLVM_OBJ_ROOT: " '$(LLVM_OBJ_ROOT)'
|
$(Echo) "LLVM_OBJ_ROOT: " '$(LLVM_OBJ_ROOT)'
|
||||||
$(Echo) "PROJ_prefix : " '$(PROJ_prefix)'
|
$(Echo) "PROJ_prefix : " '$(PROJ_prefix)'
|
||||||
|
$(Echo) "PROJ_internal_prefix : " '$(PROJ_internal_prefix)'
|
||||||
$(Echo) "PROJ_bindir : " '$(PROJ_bindir)'
|
$(Echo) "PROJ_bindir : " '$(PROJ_bindir)'
|
||||||
$(Echo) "PROJ_libdir : " '$(PROJ_libdir)'
|
$(Echo) "PROJ_libdir : " '$(PROJ_libdir)'
|
||||||
$(Echo) "PROJ_etcdir : " '$(PROJ_etcdir)'
|
$(Echo) "PROJ_etcdir : " '$(PROJ_etcdir)'
|
||||||
|
@ -885,6 +885,12 @@ AC_ARG_ENABLE(libffi,AS_HELP_STRING(
|
|||||||
esac],
|
esac],
|
||||||
llvm_cv_enable_libffi=no)
|
llvm_cv_enable_libffi=no)
|
||||||
|
|
||||||
|
AC_ARG_WITH(internal-prefix,
|
||||||
|
AS_HELP_STRING([--with-internal-prefix],
|
||||||
|
[Installation directory for internal files]),,
|
||||||
|
withval="")
|
||||||
|
AC_SUBST(INTERNAL_PREFIX,[$withval])
|
||||||
|
|
||||||
dnl===-----------------------------------------------------------------------===
|
dnl===-----------------------------------------------------------------------===
|
||||||
dnl===
|
dnl===
|
||||||
dnl=== SECTION 4: Check for programs we need and that they are the right version
|
dnl=== SECTION 4: Check for programs we need and that they are the right version
|
||||||
|
18
configure
vendored
18
configure
vendored
@ -711,6 +711,7 @@ EXTRA_OPTIONS
|
|||||||
EXTRA_LD_OPTIONS
|
EXTRA_LD_OPTIONS
|
||||||
CLANG_SRC_ROOT
|
CLANG_SRC_ROOT
|
||||||
BINUTILS_INCDIR
|
BINUTILS_INCDIR
|
||||||
|
INTERNAL_PREFIX
|
||||||
NM
|
NM
|
||||||
ifGNUmake
|
ifGNUmake
|
||||||
LN_S
|
LN_S
|
||||||
@ -1451,6 +1452,7 @@ Optional Packages:
|
|||||||
plugin-api.h file for gold plugin.
|
plugin-api.h file for gold plugin.
|
||||||
--with-bug-report-url Specify the URL where bug reports should be
|
--with-bug-report-url Specify the URL where bug reports should be
|
||||||
submitted (default=http://llvm.org/bugs/)
|
submitted (default=http://llvm.org/bugs/)
|
||||||
|
--with-internal-prefix Installation directory for internal files
|
||||||
--with-tclinclude directory where tcl headers are
|
--with-tclinclude directory where tcl headers are
|
||||||
--with-udis86=<path> Use udis86 external x86 disassembler library
|
--with-udis86=<path> Use udis86 external x86 disassembler library
|
||||||
--with-oprofile=<prefix>
|
--with-oprofile=<prefix>
|
||||||
@ -5671,6 +5673,17 @@ fi
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# Check whether --with-internal-prefix was given.
|
||||||
|
if test "${with_internal_prefix+set}" = set; then
|
||||||
|
withval=$with_internal_prefix;
|
||||||
|
else
|
||||||
|
withval=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
INTERNAL_PREFIX=$withval
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
{ echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
|
{ echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
|
||||||
echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6; }
|
echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6; }
|
||||||
if test "${lt_cv_path_NM+set}" = set; then
|
if test "${lt_cv_path_NM+set}" = set; then
|
||||||
@ -10476,7 +10489,7 @@ else
|
|||||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||||
lt_status=$lt_dlunknown
|
lt_status=$lt_dlunknown
|
||||||
cat > conftest.$ac_ext <<EOF
|
cat > conftest.$ac_ext <<EOF
|
||||||
#line 10479 "configure"
|
#line 10492 "configure"
|
||||||
#include "confdefs.h"
|
#include "confdefs.h"
|
||||||
|
|
||||||
#if HAVE_DLFCN_H
|
#if HAVE_DLFCN_H
|
||||||
@ -21937,6 +21950,7 @@ EXTRA_OPTIONS!$EXTRA_OPTIONS$ac_delim
|
|||||||
EXTRA_LD_OPTIONS!$EXTRA_LD_OPTIONS$ac_delim
|
EXTRA_LD_OPTIONS!$EXTRA_LD_OPTIONS$ac_delim
|
||||||
CLANG_SRC_ROOT!$CLANG_SRC_ROOT$ac_delim
|
CLANG_SRC_ROOT!$CLANG_SRC_ROOT$ac_delim
|
||||||
BINUTILS_INCDIR!$BINUTILS_INCDIR$ac_delim
|
BINUTILS_INCDIR!$BINUTILS_INCDIR$ac_delim
|
||||||
|
INTERNAL_PREFIX!$INTERNAL_PREFIX$ac_delim
|
||||||
NM!$NM$ac_delim
|
NM!$NM$ac_delim
|
||||||
ifGNUmake!$ifGNUmake$ac_delim
|
ifGNUmake!$ifGNUmake$ac_delim
|
||||||
LN_S!$LN_S$ac_delim
|
LN_S!$LN_S$ac_delim
|
||||||
@ -22017,7 +22031,7 @@ LIBOBJS!$LIBOBJS$ac_delim
|
|||||||
LTLIBOBJS!$LTLIBOBJS$ac_delim
|
LTLIBOBJS!$LTLIBOBJS$ac_delim
|
||||||
_ACEOF
|
_ACEOF
|
||||||
|
|
||||||
if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 90; then
|
if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 91; then
|
||||||
break
|
break
|
||||||
elif $ac_last_try; then
|
elif $ac_last_try; then
|
||||||
{ { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
|
{ { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
|
||||||
|
Loading…
x
Reference in New Issue
Block a user