chapel-lang/chapel — pull request #1020 by gbtitus (2014-12-17 19:58:00+00:00)
Title: Simplify third-party Makefiles.

This is a follow-up to https://github.com/chapel-lang/chapel/pull/1013,
which simplified third-party/gmp/Makefile{,.include}. That passed
nightly testing last night, so now we're doing the other third-party
packages.

First, in Makefile.include (or for llvm, Makefile,share), change the
ordering of the make(1) variable definitions to be generally:

base and unique build dirs
build dirs
install dirs
source dirs and files, if any
lib dirs and files, if any

Second, these lines in Makefile were superfluous:

_ABS_DIR = $(shell pwd)
_INSTALL_DIR = $(_ABS_DIR)/$(_INSTALL_SUBDIR)
_BUILD_DIR = $(_ABS_DIR)/$(_BUILD_SUBDIR)
_DIR = $(_ABS_DIR)

Because _ABS_DIR isn't referenced anywhere else, they're equivalent
to:

_DIR = $(shell pwd)
_INSTALL_DIR = $(_DIR)/$(_INSTALL_SUBDIR)
_BUILD_DIR = $(_DIR)/$(_BUILD_SUBDIR)

But these latter two definitions of _{INSTALL,BUILD}_DIR are
identical to the ones in Makefile.include, which is included here by
virtue of ../../make/Makefile.base being included at the top. So they
can go. And the first definition here is effectively the same as this
one that is already in Makefile.include:

_DIR = $(shell pwd)/../../third-party/qthread

So, it can go as well.

While here, I also got rid of the unreferenced BINUTILS_GOLD_DIR
definition in the llvm Makefile, after checking with the author that
there was no expectation it would be needed in the future.