#!/bin/ksh93 # # pthread_mutex_attr_util wrapper script # # Written by Roland Mainz # function add_ld_preload { [[ -x "$1" ]] && LD_PRELOAD="$1:${LD_PRELOAD-}" } add_ld_preload "$PWD/pthread_mutex_attr_util.so" add_ld_preload "/usr/lib/pthread_mutex_attr_util/pthread_mutex_attr_util.so" export LD_PRELOAD # # ToDo: Add option parsing # # # make sure we re-use the PID so we can squeeze this script # between the caller and the original binary, so that the # caller doesn't notice it # exec "$@" # EOF.