From: Robert Foss <[email protected]>

Use the HAS_INTEL automake flag to avoid building tools that won't
compile unless libdrm_intel is available in the build system.

Signed-off-by: Robert Foss <[email protected]>
---
 tools/Makefile.sources | 50 +++++++++++++++++++++++++++++---------------------
 1 file changed, 29 insertions(+), 21 deletions(-)

diff --git a/tools/Makefile.sources b/tools/Makefile.sources
index 5d5958d..c2dab8e 100644
--- a/tools/Makefile.sources
+++ b/tools/Makefile.sources
@@ -1,42 +1,54 @@
-noinst_PROGRAMS = \
-       hsw_compute_wrpll \
-       skl_compute_wrpll \
-       skl_ddb_allocation \
+noinst_PROGRAMS =              \
+       hsw_compute_wrpll       \
+       skl_compute_wrpll       \
+       skl_ddb_allocation      \
        $(NULL)
 
-bin_PROGRAMS =                                 \
+bin_PROGRAMS =                         \
        igt_stats                       \
-       intel_audio_dump                \
+       intel_audio_dump                \
        intel_reg                       \
        intel_backlight                 \
        intel_bios_dumper               \
        intel_bios_reader               \
        intel_display_crc               \
        intel_display_poller            \
-       intel_dump_decode               \
-       intel_error_decode              \
        intel_forcewaked                \
        intel_gpu_frequency             \
-       intel_framebuffer_dump          \
        intel_firmware_decode           \
-       intel_gpu_time                  \
-       intel_gpu_top                   \
-       intel_gtt                       \
+       intel_gpu_time                  \
+       intel_gpu_top                   \
+       intel_gtt                       \
        intel_infoframes                \
        intel_l3_parity                 \
        intel_lid                       \
        intel_opregion_decode           \
        intel_panel_fitter              \
-       intel_perf_counters             \
-       intel_reg_checker               \
+       intel_reg_checker               \
        intel_residency                 \
-       intel_stepping                  \
+       intel_stepping                  \
        intel_watermark
 
 dist_bin_SCRIPTS = intel_gpu_abrt
 
-intel_dump_decode_SOURCES =    \
-       intel_dump_decode.c
+if HAVE_INTEL
+       bin_PROGRAMS +=                 \
+               intel_dump_decode       \
+               intel_error_decode      \
+               intel_framebuffer_dump  \
+               intel_perf_counters     \
+               $(NULL)
+
+       intel_dump_decode_SOURCES =     \
+               intel_dump_decode.c     \
+               $(NULL)
+
+       intel_error_decode_SOURCES =    \
+               intel_error_decode.c    \
+               $(NULL)
+
+       intel_error_decode_LDFLAGS = -lz
+endif
 
 intel_reg_SOURCES =            \
        intel_reg.c             \
@@ -44,10 +56,6 @@ intel_reg_SOURCES =          \
        intel_reg_spec.c        \
        intel_reg_spec.h
 
-intel_error_decode_SOURCES =   \
-       intel_error_decode.c
-intel_error_decode_LDFLAGS = -lz
-
 intel_bios_reader_SOURCES =    \
        intel_bios_reader.c     \
        intel_bios.h
-- 
2.7.4

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

Reply via email to