cjdelisle/cjdns — pull request #458 by interfect (2014-02-14 10:07:03+00:00)
Title: Enabling CFLAGS and LDFLAGS environment variables to affect all compilation

Previously, the CFLAGS environment variable was able to affect the compiler options for the cnacl dependency build, but not for the libuv dependency build or the main build. These changes allow the CFLAGS environment variable to affect compilation of not only cnacl, but also libuv and cjdns itself.

The LDFLAGS environment variable is now also checked, and used to provide flags to the linker when linking cjdns.

These changes allow cjdns to be built in new and exciting ways. For example, we can build with NEON support (including the special optimized ARM NEON assembly functions in cnacl) and optimizations specific to the processor in the BeagleBone Black, with debugging symbols turned on, by running this:

```
CFLAGS="-march=armv7-a -mtune=cortex-a8 -marm -mfloat-abi=hard -mfpu=neon -g" LDFLAGS="-march=armv7-a -mtune=cortex-a8 -mfloat-abi=hard -marm -mfpu=neon -g" ./do
```