The recent fix that prevents "-v" from triggering source downloads
exposed a different bug that allowed the build script to download the
bottled package instead of the source package; fix the logic.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
The == comparison was comparing the versions rather than directly
comparing the strings, which lead to false positives.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
When building software "linking step did not complete" sounds
like ld failed. Let's be clear about this.
ClosesHomebrew/homebrew#14407.
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Clarify the error message arising from XCodeDependency so that users know
XCode.app is needed and that just installing the CLT does not count as
"installing XCode".
This prevents multiple calls to flag-modifying ENV methods from
resulting in large amounts of consecutive spaces.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Specifying dependencies with a URL works, even if by accident, but
factory is called repeatedly on this URL and this results in multiple
downloads of the same file.
Fix this by checking const_defined? here too, and DRY up the code a bit.
FixesHomebrew/homebrew#14285.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
- When using CPATH, we only need -isysroot and not the other -I spam.
- LDFLAGS use -isysroot instead of -L
Turns out that the linker also understands the
-isysroot flag which behaves more natural (in the
sense: "like the internal defaults `/usr/lib` etc.)
than adding `-L$(SDKROOT).
Especially for duplicates, the linker first searches
through all `-L` dirs and then looks at the sysroot
or internal defaults. This is what we want.
- Pkg-config needs CC with CFLAGS passed to configure.
ClosesHomebrew/homebrew#14351.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
XQuartz isn't added to the default library paths so if something is
linked against a Homebrew libpng then it doesn't work against the
XQuartz libpng. The CLT provides X11 on Lion so don't request users
install XQuartz if it isn't needed on Mountain Lion.
FixesHomebrew/homebrew#14325.
Due to the new const_defined? checks, passing certain names (such as
those that start with a digit) that are illegal constant names will
raise NameError. Catch this and error out gracefully, as we would have
previously.
FixesHomebrew/homebrew#14342.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Simplify access to the different forms of a formula's build options by
making options into real objects rather than strings, and expose both
the 'name' and 'flag' form.