busybox: Obey base_bindir, sysconfdir, etc. don't hardcode at /, /bin.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
busybox: Make tool symlinking code obey base_bindir.

Link to ${base_bindir}/busybox and avoid relative symlink optimizations
based on fixed layout assumptions.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
opkg: Obey sysconfdir.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
opkg: Obey base_bindir in postinst script.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
uclibc: Obey base_prefix & base_libdir, don't hardcode at / & /lib.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
uclibc: Use base_prefix for ldconfig packaging.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
uclibc: Package uclibc before uclibc-dev to get proper content.

uclibc-dev's patterns are not specific enough and work on assumption
base_libdir != libdir. If they are equal, actual .so's are pulled into
-dev package, so give them a chance to go into main package first.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
uclibc: Rename uclibc-thread-db package to *-dev to fix QA issues.

uclibc-thread-db contains debugging support libs, both static and shared
variants with sumlinks, which generates QA errors "non -dev/-dbg/-nativesdk
package contains symlink .so". The easiest solution is to cast the package
-dev, which makes full sense.
-FILES_uclibc-thread-db = "${base_libdir}/libthread_db*"
+FILES_uclibc-thread-db-dev = "${base_libdir}/libthread_db*"

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
gcc: Extend patch to obey base_libdir for uclibc host.

For gcc 4.7, need also patch top-level config/linux.h, other arch-specific
patches are not enough.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
libc-package.bbclass: Obey base_bindir for shell shebang.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
package.bbclass: Obey base_bindir/base_sbindir (incl. shell shebang).

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
update-alternatives.bbclass: Obey base_bindir for shell shebang.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
useradd.bbclass: Obey base_bindir for shell shebang.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
shadow: Obey sysconfdir.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
update-rc.d: Rewrite installed script to obey sysconfdir.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
update-rc.d.bbclass: Obey base_bindir for shell shebang.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
uclibc: Add patches to obey prefix for /etc files and even /dev/log.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
ccache.bbclass: Allow user to override CCACHE_DIR.

For example, some users may want to use single cache directory (instead
of per-package) with known max size limit, to better control disk usage.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
TARGET_LDFLAGS: Building for arbitrary prefix requires -rpath-link to libdir.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
It turns out that when for non standard prefix, libdir, etc. locations,
toolchain still can't find shared libs in some cases (like, shlibs this
shlib was linked against). So, switch back to commented out TARGET_LDFLAGS
definition which passes explicit -rpath-link to linker.
shebang-rewrite.bbclass: Automatically rewrite interp path for shell scripts.

This bbclass will scan and rewrite shebang (#!) line of all scripts in all
packages build, to replace "/bin" path prefix with $bindir instead.

Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>