f-stack/dpdk/buildtools/gen-pmdinfo-cfile.sh

15 lines
381 B
Bash
Raw Normal View History

2019-06-25 11:12:58 +00:00
#! /bin/sh
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
arfile=$1
output=$2
pmdinfogen=$3
2021-02-05 08:48:47 +00:00
# The generated file must not be empty if compiled in pedantic mode
echo 'static __attribute__((unused)) const char *generator = "'$0'";' > $output
2019-06-25 11:12:58 +00:00
for ofile in `ar t $arfile` ; do
ar p $arfile $ofile | $pmdinfogen - - >> $output 2> /dev/null
done
exit 0