[llvm-commits] [llvm] r164633 - in /llvm/trunk: Makefile.config.in Makefile.rules autoconf/configure.ac configure projects/sample/Makefile.llvm.rules tools/llvm-config/Makefile
Sebastian Pop
spop at codeaurora.org
Tue Sep 25 14:15:09 PDT 2012
Author: spop
Date: Tue Sep 25 16:15:08 2012
New Revision: 164633
URL: http://llvm.org/viewvc/llvm-project?rev=164633&view=rev
Log:
Add --program-prefix support to build
Modified:
llvm/trunk/Makefile.config.in
llvm/trunk/Makefile.rules
llvm/trunk/autoconf/configure.ac
llvm/trunk/configure
llvm/trunk/projects/sample/Makefile.llvm.rules
llvm/trunk/tools/llvm-config/Makefile
Modified: llvm/trunk/Makefile.config.in
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/Makefile.config.in?rev=164633&r1=164632&r2=164633&view=diff
==============================================================================
--- llvm/trunk/Makefile.config.in (original)
+++ llvm/trunk/Makefile.config.in Tue Sep 25 16:15:08 2012
@@ -61,6 +61,7 @@
prefix := @prefix@
PROJ_prefix := $(prefix)
+program_prefix := @program_prefix@
PROJ_VERSION := $(LLVMVersion)
else
ifndef PROJ_SRC_ROOT
Modified: llvm/trunk/Makefile.rules
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/Makefile.rules?rev=164633&r1=164632&r2=164633&view=diff
==============================================================================
--- llvm/trunk/Makefile.rules (original)
+++ llvm/trunk/Makefile.rules Tue Sep 25 16:15:08 2012
@@ -1541,7 +1541,7 @@
else
ToolBinDir = $(DESTDIR)$(PROJ_bindir)
endif
-DestTool = $(ToolBinDir)/$(TOOLEXENAME)
+DestTool = $(ToolBinDir)/$(program_prefix)$(TOOLEXENAME)
install-local:: $(DestTool)
@@ -1556,7 +1556,7 @@
# TOOLALIAS install.
ifdef TOOLALIAS
-DestToolAlias = $(ToolBinDir)/$(TOOLALIAS)$(EXEEXT)
+DestToolAlias = $(ToolBinDir)/$(program_prefix)$(TOOLALIAS)$(EXEEXT)
install-local:: $(DestToolAlias)
Modified: llvm/trunk/autoconf/configure.ac
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/autoconf/configure.ac?rev=164633&r1=164632&r2=164633&view=diff
==============================================================================
--- llvm/trunk/autoconf/configure.ac (original)
+++ llvm/trunk/autoconf/configure.ac Tue Sep 25 16:15:08 2012
@@ -1732,6 +1732,11 @@
dnl OCaml findlib META file
AC_CONFIG_FILES([bindings/ocaml/llvm/META.llvm])
+dnl Add --program-prefix value to Makefile.rules. Already an ARG variable.
+test "x$program_prefix" = "xNONE" && program_prefix=""
+AC_SUBST([program_prefix])
+
+
dnl Do special configuration of Makefiles
AC_CONFIG_COMMANDS([setup],,[llvm_src="${srcdir}"])
AC_CONFIG_MAKEFILE(Makefile)
Modified: llvm/trunk/configure
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/configure?rev=164633&r1=164632&r2=164633&view=diff
==============================================================================
--- llvm/trunk/configure (original)
+++ llvm/trunk/configure Tue Sep 25 16:15:08 2012
@@ -792,6 +792,7 @@
ENABLE_VISIBILITY_INLINES_HIDDEN
RPATH
RDYNAMIC
+program_prefix
LIBOBJS
LTLIBOBJS'
ac_subst_files=''
@@ -10316,7 +10317,7 @@
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 10319 "configure"
+#line 10320 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -21409,6 +21410,10 @@
ac_config_files="$ac_config_files bindings/ocaml/llvm/META.llvm"
+test "x$program_prefix" = "xNONE" && program_prefix=""
+
+
+
ac_config_commands="$ac_config_commands setup"
ac_config_commands="$ac_config_commands Makefile"
@@ -22334,11 +22339,12 @@
ENABLE_VISIBILITY_INLINES_HIDDEN!$ENABLE_VISIBILITY_INLINES_HIDDEN$ac_delim
RPATH!$RPATH$ac_delim
RDYNAMIC!$RDYNAMIC$ac_delim
+program_prefix!$program_prefix$ac_delim
LIBOBJS!$LIBOBJS$ac_delim
LTLIBOBJS!$LTLIBOBJS$ac_delim
_ACEOF
- if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 95; then
+ if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 96; then
break
elif $ac_last_try; then
{ { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
@@ -22357,7 +22363,7 @@
cat >>$CONFIG_STATUS <<_ACEOF
cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
+/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
_ACEOF
sed '
s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
@@ -22370,8 +22376,6 @@
' >>$CONFIG_STATUS <conf$$subs.sed
rm -f conf$$subs.sed
cat >>$CONFIG_STATUS <<_ACEOF
-:end
-s/|#_!!_#|//g
CEOF$ac_eof
_ACEOF
@@ -22619,7 +22623,7 @@
s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
s&@INSTALL@&$ac_INSTALL&;t t
$ac_datarootdir_hack
-" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
+" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" | sed 's/|#_!!_#|//g' >$tmp/out
test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
{ ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
Modified: llvm/trunk/projects/sample/Makefile.llvm.rules
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/projects/sample/Makefile.llvm.rules?rev=164633&r1=164632&r2=164633&view=diff
==============================================================================
--- llvm/trunk/projects/sample/Makefile.llvm.rules (original)
+++ llvm/trunk/projects/sample/Makefile.llvm.rules Tue Sep 25 16:15:08 2012
@@ -1437,7 +1437,7 @@
uninstall-local::
$(Echo) Uninstall circumvented with NO_INSTALL
else
-DestTool = $(DESTDIR)$(PROJ_bindir)/$(TOOLEXENAME)
+DestTool = $(DESTDIR)$(PROJ_bindir)/$(program_prefix)$(TOOLEXENAME)
install-local:: $(DestTool)
@@ -1451,7 +1451,7 @@
# TOOLALIAS install.
ifdef TOOLALIAS
-DestToolAlias = $(DESTDIR)$(PROJ_bindir)/$(TOOLALIAS)$(EXEEXT)
+DestToolAlias = $(DESTDIR)$(PROJ_bindir)/$(program_prefix)$(TOOLALIAS)$(EXEEXT)
install-local:: $(DestToolAlias)
Modified: llvm/trunk/tools/llvm-config/Makefile
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-config/Makefile?rev=164633&r1=164632&r2=164633&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-config/Makefile (original)
+++ llvm/trunk/tools/llvm-config/Makefile Tue Sep 25 16:15:08 2012
@@ -63,5 +63,5 @@
install:: $(DESTDIR)$(PROJ_bindir)
$(Echo) Installing llvm-config-host
$(Verb) $(ProgInstall) $(BuildLLVMToolDir)/llvm-config \
- $(DESTDIR)$(PROJ_bindir)/llvm-config-host
+ $(DESTDIR)$(PROJ_bindir)/$(program_prefix)llvm-config-host
endif
More information about the llvm-commits
mailing list