libglvnd/src/util/uthash/tests/mexpand
Brian Nguyen 93bb43c5e7 Add uthash commit 2c8cd98e0be93d38ff3340a0fbce300bc6739b08 to src/util
uthash's hashtable implementation will be used by libGLX for storing
various mappings needed for correct dispatching.
2013-08-26 11:03:41 -07:00

22 lines
365 B
Bash
Executable file

#!/bin/sh
# utility to macro-expand a test program
CC=gcc
#CPPFLAGS=-DHASH_DEBUG=1
#CC=g++
CPPFLAGS="-m64 -O3"
CFLAGS="-O3 -m64 -pedantic -Wall"
${CC} ${CPPFLAGS} -E -I../src $1 | egrep -v '^#' > /tmp/$1
indent /tmp/$1
${CC} ${CFLAGS} -o /tmp/$1.$$ /tmp/$1
rm -f /tmp/$1.$$
read -p "open /tmp/$1 ? [n] " response
if [ "$response" = "y" ]
then
vi /tmp/$1
fi