r600g/sb: Move variable dereference after null check.

Fixes "Deference before null check" defect reported by Coverity.

Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Vadim Girlin <vadimgirlin@gmail.com>
Android: remove unused MESA_ENABLED_APIS variable

The variable was forgotten during the FEATURE_* removal.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
scons: drop obsolete enabled_apis variable

The variable was forgotten during the FEATURE_* removal.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
gbm: move source file lists to Makefile.sources

Allow the lists to be shared among build systems.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
XXX S-O gbm: enable subdir-objects to prevent automake warnings

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
gtest: move source file lists to Makefile.sources

* Allow the lists to be shared among build systems.
* *.la files are hangled by top .gitignore, drop local one.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
XXX S-O gtest: enable subdir-objects to prevent automake warnings

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
mesa/program: move source files list to Makefile.sources

Rip out the source file list from mesa/Makefile.sources, to a
more sensible location/file.
* Split PROGRAM_FILES and GENERATED_FILES.
* Update the automake and Android build systems.
* Slightly reshuffle the Android.mk for readability sake.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
scons: build mesa/program as a convinience library

* Demangle the large and complex mesa/SConscript.
* Reuse the same source file lists.
* Makes the build systems symmetric.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
dri/common: move source file lists to Makefile.sources

* Allow the lists to be shared among build systems.
* Update automake and Android build systems.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
XXXgallium/drivers: enable subdir-objects

r300 still need some love, everything else looks great

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
XXX S-O gallium/state_trackers: set subdir-objects for glx and xvmc

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
dri: Merge drisw_util.c into dri_util.c

The only important difference was not calling drmGetVersion, and making
the swrast extension vtable.  That doesn't justify duplicating the other
330 lines of code.

v2: fix the scons build (code by Emil Velikov)
v3: fix scons build with swrast-only (code by Emil Velikov)

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
(cherry picked from commit 494d892047b39e54543f1e7eaadeb0adaba45f80)
XXXscons: move scons from gallium/targets/ to mesa/drivers/dri/common/

In a preparation to build common_dri_{drm,sw} is a similar fasion to
other build systems and share the same Makefile.sources.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
automake: build dri/common SW (drisw) library along side the HW (dri2) one

With the recent dri/common unification/cleanup it makes sense to build
libdriswcommon.la and then link it to the swrast driver(s).

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
targets/vdpau: symlink vl_winsys_{dri,xsp}.c for each target

Make automake's subdir-objects work.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
targets/xvmc: symlink vl_winsys_{dri,xsp}.c for each target

Make automake's subdir-objects work.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
targets/r300: move drm_target.c to common folder

... and symlink for each target.
Make automake's subdir-objects work for r300.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
targets/r600: move drm_target.c to a common folder

... and symlink to each target.
Make automake's subdir-objects work for r600.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
targets/radeonsi: move drm_target.c to a common folder

... and symlink to each target.
Make automake's subdir-objects work for radeonsi.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>