[GOLD] make clean
[deliverable/binutils-gdb.git] / gold / Makefile.am
index df99f23c3a771d3c075f53798f80d9aeea7a6993..fd0a3591855f7b5942c1e9dbcc6033615cff669c 100644 (file)
@@ -1,6 +1,6 @@
 ## Process this file with automake to generate Makefile.in
 #
-#  Copyright (C) 2006-2014 Free Software Foundation, Inc.
+#  Copyright (C) 2006-2018 Free Software Foundation, Inc.
 #
 # This file is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -25,8 +25,18 @@ tooldir = $(exec_prefix)/$(target_alias)
 
 ACLOCAL_AMFLAGS = -I ../bfd -I ../config
 
-AM_CFLAGS = $(WARN_CFLAGS) $(LFS_CFLAGS) $(RANDOM_SEED_CFLAGS)
-AM_CXXFLAGS = $(WARN_CXXFLAGS) $(LFS_CFLAGS) $(RANDOM_SEED_CFLAGS)
+# This is where we get zlib from.  zlibdir is -L../zlib and zlibinc is
+# -I../zlib, unless we were configured with --with-system-zlib, in which
+# case both are empty.
+ZLIB = @zlibdir@ -lz
+ZLIBINC = @zlibinc@
+
+THREADFLAGS = @PTHREAD_CFLAGS@
+THREADLIBS = @PTHREAD_LIBS@
+
+AM_CFLAGS = $(WARN_CFLAGS) $(LFS_CFLAGS) $(RANDOM_SEED_CFLAGS) $(ZLIBINC) $(THREADFLAGS)
+AM_CXXFLAGS = $(WARN_CXXFLAGS) $(LFS_CFLAGS) $(RANDOM_SEED_CFLAGS) $(ZLIBINC) $(THREADFLAGS)
+AM_LDFLAGS = $(THREADFLAGS)
 
 AM_CPPFLAGS = \
        -I$(srcdir) -I$(srcdir)/../include -I$(srcdir)/../elfcpp \
@@ -40,10 +50,6 @@ if PLUGINS
 LIBDL = @DLOPEN_LIBS@
 endif
 
-if THREADS
-THREADSLIB = -lpthread
-endif
-
 AM_YFLAGS = -d
 
 # Automake 1.10+ disables lex and yacc output file regeneration if
@@ -163,14 +169,17 @@ DEFFILES = arm-reloc.def aarch64-reloc.def
 
 EXTRA_DIST = yyscript.c yyscript.h
 
+diststuff: $(EXTRA_DIST)
+
 TARGETSOURCES = \
        i386.cc x86_64.cc sparc.cc powerpc.cc arm.cc arm-reloc-property.cc tilegx.cc \
-       mips.cc aarch64.cc aarch64-reloc-property.cc
+       mips.cc aarch64.cc aarch64-reloc-property.cc s390.cc
 
 ALL_TARGETOBJS = \
        i386.$(OBJEXT) x86_64.$(OBJEXT) sparc.$(OBJEXT) powerpc.$(OBJEXT) \
        arm.$(OBJEXT) arm-reloc-property.$(OBJEXT) tilegx.$(OBJEXT) \
-       mips.$(OBJEXT) aarch64.$(OBJEXT) aarch64-reloc-property.$(OBJEXT)
+       mips.$(OBJEXT) aarch64.$(OBJEXT) aarch64-reloc-property.$(OBJEXT) \
+       s390.$(OBJEXT)
 
 libgold_a_SOURCES = $(CCFILES) $(HFILES) $(YFILES) $(DEFFILES)
 libgold_a_LIBADD = $(LIBOBJS)
@@ -178,7 +187,7 @@ libgold_a_LIBADD = $(LIBOBJS)
 sources_var = main.cc
 deps_var = $(TARGETOBJS) libgold.a $(LIBIBERTY) $(LIBINTL_DEP)
 ldadd_var = $(TARGETOBJS) libgold.a $(LIBIBERTY) $(GOLD_LDADD) $(LIBINTL) \
-        $(THREADSLIB) $(LIBDL)
+        $(THREADLIBS) $(LIBDL) $(ZLIB)
 ldflags_var = $(GOLD_LDFLAGS)
 
 ld_new_SOURCES = $(sources_var)
@@ -192,12 +201,12 @@ incremental_dump_SOURCES = incremental-dump.cc
 incremental_dump_DEPENDENCIES = $(TARGETOBJS) libgold.a $(LIBIBERTY) \
        $(LIBINTL_DEP)
 incremental_dump_LDADD = $(TARGETOBJS) libgold.a $(LIBIBERTY) $(LIBINTL) \
-        $(THREADSLIB) $(LIBDL)
+        $(THREADLIBS) $(LIBDL) $(ZLIB)
 
 dwp_SOURCES = dwp.cc
 dwp_DEPENDENCIES = libgold.a $(LIBIBERTY) $(LIBINTL_DEP)
-dwp_LDADD = libgold.a $(LIBIBERTY) $(GOLD_LDADD) $(LIBINTL) $(THREADSLIB) \
-       $(LIBDL)
+dwp_LDADD = libgold.a $(LIBIBERTY) $(GOLD_LDADD) $(LIBINTL) $(THREADLIBS) \
+       $(LIBDL) $(ZLIB)
 dwp_LDFLAGS = $(GOLD_LDFLAGS)
 
 CONFIG_STATUS_DEPENDENCIES = $(srcdir)/../bfd/development.sh
@@ -306,6 +315,7 @@ bootstrap-test-r: ld2-r
 
 check_PROGRAMS = ld1 ld2 ld1-r ld2-r
 TESTS = bootstrap-test bootstrap-test-r
+MOSTLYCLEANFILES = bootstrap-test bootstrap-test-r
 
 # Verify that changing the number of threads doesn't change the
 # treehash computation, by building ld1 and ld3 the same way except
@@ -315,6 +325,7 @@ TESTS = bootstrap-test bootstrap-test-r
 # because the treehash can still operate in that mode.
 check_PROGRAMS += ld4
 TESTS += bootstrap-test-treehash-chunksize
+MOSTLYCLEANFILES += bootstrap-test-treehash-chunksize
 
 gcctestdir3/ld: ld-new
        test -d gcctestdir3 || mkdir -p gcctestdir3
@@ -349,6 +360,7 @@ ld3_LDFLAGS += -Wl,--thread-count=13
 ld4_LDFLAGS += -Wl,--thread-count=3
 check_PROGRAMS += ld3
 TESTS += bootstrap-test-treehash-chunksize
+MOSTLYCLEANFILES += bootstrap-test-treehash-chunksize
 
 bootstrap-test-treehash: ld1 ld3
        rm -f $@
This page took 0.02508 seconds and 4 git commands to generate.