Sort object files for deterministic linking order

This is from the Debian reproducible team.

Signed-off-by: Sebastian Andrzej Siewior <sebastian@breakpoint.cc>
This commit is contained in:
Reiner Herrmann 2016-07-03 21:47:13 +02:00 committed by Sebastian Andrzej Siewior
parent 86acd501a4
commit 81aeb56951

View File

@ -89,7 +89,7 @@ $(OBJECTS): $(HEADERS)
$(LTCOMPILE) $(CFLAGS) $(LDFLAGS) -o $@ -c $<
$(LIBNAME): $(OBJECTS)
libtool --mode=link --tag=CC $(CC) $(CFLAGS) $(LDFLAGS) `find . -type f | grep "[.]lo" | xargs` -o $(LIBNAME) -rpath $(LIBPATH) -version-info $(VERSION) -export-symbols libtfm.symbols
libtool --mode=link --tag=CC $(CC) $(CFLAGS) $(LDFLAGS) `find . -type f | LC_ALL=C sort | grep "[.]lo" | xargs` -o $(LIBNAME) -rpath $(LIBPATH) -version-info $(VERSION) -export-symbols libtfm.symbols
install: $(LIBNAME)
install -d -g $(GROUP) -o $(USER) $(DESTDIR)$(LIBPATH)