]> git.baikalelectronics.ru Git - kernel.git/commit
tools feature: Add missing -lzstd to the fast path feature detection
authorArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 4 Sep 2020 20:20:02 +0000 (17:20 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Wed, 9 Sep 2020 14:11:01 +0000 (11:11 -0300)
commitc4310847bca49bdd7fa0e9e468ecace1de6bda9c
treefb85e8b0bf619158f105aec13da85fadddda1d27
parentb82294038671537a1f80eeb3a63235bd29e600c0
tools feature: Add missing -lzstd to the fast path feature detection

We were failing that due to GTK2+ and then for the ZSTD test, which made
test-all.c, the fast path feature detection file to fail and thus
trigger building all of the feature tests, slowing down the test.

Eventually the ZSTD test would be built and would succeed, since it had
the needed -lzstd, avoiding:

  $ cat /tmp/build/perf/feature/test-all.make.output
  /usr/bin/ld: /tmp/ccRRJQ4u.o: in function `main_test_libzstd':
  /home/acme/git/perf/tools/build/feature/test-libzstd.c:8: undefined reference to `ZSTD_createCStream'
  /usr/bin/ld: /home/acme/git/perf/tools/build/feature/test-libzstd.c:9: undefined reference to `ZSTD_freeCStream'
  collect2: error: ld returned 1 exit status
  $

Fix it by adding -lzstd to the test-all target.

Now I need an entry to 'perf test' to make sure that
/tmp/build/perf/feature/test-all.make.output is empty...

Fixes: fe76fd8749049b96 ("tools build: Implement libzstd feature check, LIBZSTD_DIR and NO_LIBZSTD defines")
Reviewed-by: Alexei Budankov <alexey.budankov@linux.intel.com>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Link: http://lore.kernel.org/lkml/20200904202611.GJ3753976@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/build/feature/Makefile