libsoc: fix compilation error caused by multiple goals on make
authorYousong Zhou <yszhou4tech@gmail.com>
Thu, 5 Jul 2018 01:56:04 +0000 (09:56 +0800)
committerRosen Penev <rosenp@gmail.com>
Sat, 3 Aug 2019 19:23:33 +0000 (12:23 -0700)
commitfb0566686d735479f1de7d8b9255e20b4e59910a
treef3178b4015cb6a5eae3dd091db497e6a8915b324
parent1fec7ea23b1834023ad2801424f1976cabc3338f
libsoc: fix compilation error caused by multiple goals on make

Error of the following kind can happen when parallel build with goals "all" and
"install" both specified on the command line.  Seems like make can parallelly
build for both targets causing race conditions

make[3]: Entering directory `/tmp/tmp.HIR3tEIqBb/build_dir/target-mips_24kc_musl/libsoc-2016-12-22-5b788d4d'
Making all in lib
Making install in lib
make[4]: Entering directory `/tmp/tmp.HIR3tEIqBb/build_dir/target-mips_24kc_musl/libsoc-2016-12-22-5b788d4d/lib'
  CC       libsoc_la-gpio.lo
make[4]: Entering directory `/tmp/tmp.HIR3tEIqBb/build_dir/target-mips_24kc_musl/libsoc-2016-12-22-5b788d4d/lib'
  CC       libsoc_la-spi.lo
  CC       libsoc_la-gpio.lo
  CC       libsoc_la-file.lo
  CC       libsoc_la-i2c.lo
  CC       libsoc_la-spi.lo
  CC       libsoc_la-pwm.lo
  CC       libsoc_la-board.lo
  CC       libsoc_la-file.lo
  CC       libsoc_la-conffile.lo
  CC       libsoc_la-debug.lo
  CC       libsoc_la-pwm.lo
  CC       libsoc_la-conffile.lo
  CCLD     libsoc.la
OpenWrt-libtool: link: `libsoc_la-pwm.lo' is not a valid libtool object
make[4]: *** [libsoc.la] Error 1

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
(cherry-picked from 19bde8da683bfee543b3815d0614e7bf900acda3)
libs/libsoc/Makefile