$ pkgdata -v -p bin_mkltfs -m static -q packagelist.txt
# Calling icu-config: ./icu-config --incpkgdatafile
sh: 1: ./icu-config: not found
pkgdata: icu-config: Could not read from icu-config. (fix PATH or use -O option)
required parameter is missing: -O is required for static and shared builds.
Run 'pkgdata --help' for help.
I found this interesting behaviour:
$ pkgdata -v -p bin_mkltfs -m static -q packagelist.txt
# Calling icu-config: ./icu-config --incpkgdatafile
sh: 1: ./icu-config: not found
pkgdata: icu-config: Could not read from icu-config. (fix PATH or use -O option)
required parameter is missing: -O is required for static and shared builds.
Run 'pkgdata --help' for help.
$ /usr/bin/pkgdata -v -p bin_mkltfs -m static -q packagelist.txt icu/4.8. 1.1/pkgdata. inc icu/4.8. 1.1/pkgdata. inc DEPRECATED= -g -Wall -O2 -Wall -ansi -pedantic -Wshadow -Wpointer-arith -Wmissing- prototypes -Wwrite-strings -Wno-long-long -c", "-I/usr/include -DPIC -fPIC", "gcc -g -Wall -O2 -Wall -ansi -pedantic -Wshadow -Wpointer-arith -Wmissing- prototypes -Wwrite-strings -Wno-long-long -shared -Wl,-Bsymbolic" LIB_FILE] = libbin_mkltfs LIB_FILE_ VERSION] = libbin_mkltfs.a (static) DEPRECATED= -g -Wall -O2 -Wall -ansi -pedantic -Wshadow -Wpointer-arith -Wmissing- prototypes -Wwrite-strings -Wno-long-long -c -I/usr/include -DPIC -fPIC -o ./bin_mkltfs_dat.o ./bin_mkltfs_dat.s
# Calling icu-config: /usr/bin/icu-config --incpkgdatafile
# icu-config said: /usr/lib/
# pkgdata: Reading packagelist.txt..
# Reading options file /usr/lib/
# pkgDataFlags= "-a gcc", "so", "so", "a", "lib", ".48.1.1", "gcc -D_REENTRANT -DU_ATTRIBUTE_
# Writing package file ./bin_mkltfs.dat ..
# libFileName[
# libFileName[
# Generating assembly code of type -a gcc ..
pkgdata: gcc -D_REENTRANT -DU_ATTRIBUTE_
pkgdata: ar r ./libbin_mkltfs.a ./bin_mkltfs_dat.o
pkgdata: ranlib ./libbin_mkltfs.a
In other words pkgdata works if invoked with the full path of the executable and fails if called only by program name, even if it is in the PATH:
$ echo $PATH sbin:/usr/ local/bin: /usr/sbin: /usr/bin: /sbin:/ bin:/usr/ games
/usr/local/
So it is definitely a pkgdata bug.