File: setup-gtkglextmm.sh

package info (click to toggle)
gtkglextmm 1.2.0-8
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid, stretch
  • size: 5,248 kB
  • ctags: 4,387
  • sloc: sh: 8,904; cpp: 4,594; xml: 1,605; ansic: 832; makefile: 353; perl: 179
file content (51 lines) | stat: -rwxr-xr-x 873 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#!/bin/sh
#
# Setup gtkglextmm win32 binary package.
#

PKGCONFIG_FILES="lib/pkgconfig/gdkglextmm-1.0.pc lib/pkgconfig/gdkglextmm-win32-1.0.pc lib/pkgconfig/gtkglextmm-1.0.pc lib/pkgconfig/gtkglextmm-win32-1.0.pc"

PREFIX=""

case $# in
1)
    PREFIX="$1"
    ;;
*)
    echo ""
    echo "Usage: ${0#*/} <unpacked prefix dir>"
    echo ""
    echo "Example: ./${0#*/} c:/gtkglextmm"
    echo ""
    exit
    ;;
esac

#
# Update .pc files
#
for file in ${PKGCONFIG_FILES}; do

    src="${PREFIX}/${file}.orig-$$"
    dst="${PREFIX}/${file}"

    echo -n "${dst}: "

    if test ! -f ${dst}; then
        echo "no such file"
        exit
    fi

    cp ${dst} ${src}
    cat ${src} | sed -e "s|^prefix=.*|prefix=${PREFIX}|" > ${dst}

    echo "updated"

done

echo "done."

echo ""
echo "PATH:            ${PREFIX}/bin"
echo "PKG_CONFIG_PATH: ${PREFIX}/lib/pkgconfig"
echo ""