#!/bin/sh -e # $Id$ # Configuration report script for @PACKAGE@ @VERSION@ prefix=@prefix@ exec_prefix=@exec_prefix@ sdl_cflags=`sdl-config --cflags` sdl_libs="`sdl-config --libs` -lSDL_image" # Remove any -rpath option from SDL_LIBS, so as not to hardcode # the library path into the executable file: # sdl_libs=`echo $sdl_libs | sed 's:-Wl,-rpath,[^ ]*: :g'` function usage() { exit_code=$1 cat <<__EOF__ Usage: @PACKAGE@-config [OPTION]... Generic options --version print @PACKAGE@ version information --help print this help and exit Compilation support options --cflags print @PACKAGE@/SDL pre-processor and compiler flags --libs print @PACKAGE@/SDL library linking information Install directories @PACKAGE@ was configured to: --prefix --exec-prefix __EOF__ exit $exit_code } while test $# -gt 0; do case "$1" in --version) echo "@VERSION@" exit 0 ;; --help) usage 0 ;; --cflags) echo "-I@includedir@ $sdl_cflags" exit 0 ;; --libs) echo "-L@libdir@ -l@PACKAGE@ $sdl_libs" exit 0 ;; --prefix) echo "$prefix" exit 0 ;; --exec_prefix) echo "$exec_prefix" exit 0 ;; *) usage 1 ;; esac shift done