@ -1017,19 +1017,14 @@ endif
# $(1) name of the module (e.g. an extension's name or postgres for core code)
# $(2) source objects, with .o suffix
#
d e f i n e i n s t a l l _ l l v m _ m o d u l e
# Create target directory
$( MKDIR_P ) "$(DESTDIR)${bitcodedir}/$(1)"
# Create sub-directories, if files are in subdirectories
$( MKDIR_P ) $( sort $ ( dir $ ( addprefix $ ( DESTDIR ) $ {bitcodedir }/$ ( 1) /, $ ( 2) ) ) )
# Then install files
#
# The many INSTALL_DATA invocations aren't particularly fast, it'd be
# good if we could coalesce them, but I didn't find a good way.
$( foreach obj , $ {2}, $ ( INSTALL_DATA ) $ ( patsubst %.o ,%.bc , $ ( obj ) ) $ ( DESTDIR ) /$ {bitcodedir }/$ ( 1) /$ ( dir $ ( obj ) ) ;
d e f i n e i n s t a l l _ l l v m _ m o d u l e
$( MKDIR_P ) '$(DESTDIR)${bitcodedir}/$(1)'
$( MKDIR_P ) $( sort $ ( dir $ ( addprefix '$ ( DESTDIR ) $ {bitcodedir }'/$ ( 1) /, $ ( 2) ) ) )
$( foreach obj , $ {2}, $ ( INSTALL_DATA ) $ ( patsubst %.o ,%.bc , $ ( obj ) ) '$ ( DESTDIR ) $ {bitcodedir }'/$ ( 1) /$ ( dir $ ( obj ) )
)
# and generate index
( c d "$(DESTDIR)${bitcodedir}" & & $( LLVM_BINPATH ) / l l v m - l t o - t h i n l t o -thinlto-action = thinlink -o $( 1) .index.bc $( addprefix $( 1) /,$( patsubst %.o,%.bc, $( 2) ) ) )
c d '$(DESTDIR)${bitcodedir}' & & $( LLVM_BINPATH ) / l l v m - l t o - t h i n l t o -thinlto-action = thinlink -o $( 1) .index.bc $( addprefix $( 1) /,$( patsubst %.o,%.bc, $( 2) ) )
e n d e f
# Uninstall LLVM bitcode module.
@ -1040,6 +1035,6 @@ endef
# This intentionally doesn't use the explicit installed file list,
# seems too likely to change regularly.
d e f i n e u n i n s t a l l _ l l v m _ m o d u l e
r m - r f "$(DESTDIR)${bitcodedir}/$(1)/"
r m - f "$(DESTDIR)${bitcodedir}/$(1).index.bc"
r m - r f '$(DESTDIR)${bitcodedir}/$(1)/'
r m - f '$(DESTDIR)${bitcodedir}/$(1).index.bc'
e n d e f