~ubuntu-branches/ubuntu/intrepid/plplot/intrepid

« back to all changes in this revision

Viewing changes to cf/wingcc.ac

  • Committer: Bazaar Package Importer
  • Author(s): Rafael Laboissiere
  • Date: 2006-11-04 10:19:34 UTC
  • mfrom: (2.1.8 edgy)
  • Revision ID: james.westby@ubuntu.com-20061104101934-mlirvdg4gpwi6i5q
Tags: 5.6.1-10
* Orphaning the package
* debian/control: Changed the maintainer to the Debian QA Group

Show diffs side-by-side

added added

removed removed

Lines of Context:
24
24
dnl
25
25
dnl You should have received a copy of the GNU Library General Public License
26
26
dnl along with the file PLplot; if not, write to the Free Software
27
 
dnl Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
28
 
 
29
 
GDI32LIBSTR=-lgdi32
30
 
 
31
 
if test "$enable_wingcc" = "yes"; then
32
 
    AC_MSG_CHECKING(for libgdi32.a)
33
 
 
34
 
    if test -z "$GDI32LIBDIR"; then
35
 
        AC_CHECK_LIB(gdi32, main, [ GDI32LIBDIR=default ], [
 
27
dnl Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301  USA
 
28
 
 
29
PL_ARG_WITH(gdi32-incdir, [User-specified path to the libgdi32 header files], [])
 
30
if test "$enable_wingcc" = "yes"; then
 
31
    if test -z "$with_gdi32_incdir"; then
 
32
        AC_MSG_CHECKING(for libgdi32 header files)
 
33
        AC_PREPROC_IFELSE([#include <windows.h>],
 
34
        [ with_gdi32_incdir=default
 
35
          AC_MSG_RESULT([found in $with_gdi32_incdir]) ], [
 
36
        incdirs="\
 
37
        /usr/include \
 
38
        /usr/local/include"
 
39
 
 
40
        for dir in $incdirs; do
 
41
            if test -r "$dir/windows.h"; then
 
42
               with_gdi32_incdir="$dir"
 
43
               break
 
44
            fi
 
45
        done
 
46
        if test -z "$with_gdi32_incdir"; then
 
47
            AC_MSG_RESULT(not found)
 
48
            AC_MSG_WARN([libgdi32 header files not found, setting enable_wingcc=no])
 
49
            with_gdi32_incdir=default
 
50
            enable_wingcc=no
 
51
        else
 
52
            AC_MSG_RESULT([found in $with_gdi32_incdir])
 
53
        fi ])
 
54
    else
 
55
        AC_MSG_NOTICE("User-specified path to the libgdi32 header files is $with_gdi32_incdir")
 
56
    fi
 
57
    if test "$with_gdi32_incdir" = "/usr/include"; then
 
58
        with_gdi32_incdir=default
 
59
    fi
 
60
    GDI32INCCMD=""
 
61
    GDI32INCPATH=""
 
62
    PL_ADD_TO_INCS($with_gdi32_incdir, GDI32INCCMD, GDI32INCPATH)
 
63
fi
 
64
 
 
65
PL_ARG_WITH(gdi32-libdir, [User-specified path to libgdi32], [])
 
66
if test "$enable_wingcc" = "yes"; then
 
67
    if test -z "$with_gdi32_libdir"; then
 
68
        AC_CHECK_LIB(gdi32, main, [ with_gdi32_libdir=default ], [
36
69
        libdirs="\
37
70
        /usr/lib \
38
71
        /usr/local/lib"
39
72
 
40
73
        for dir in $libdirs; do
41
74
            if test -r "$dir/libgdi32.so" -o -r "$dir/libgdi32.a"; then
42
 
                GDI32LIBDIR="$dir"
 
75
                with_gdi32_libdir="$dir"
43
76
                break
44
77
            fi
45
78
        done
46
 
        if test -z "$GDI32LIBDIR"; then
47
 
            AC_MSG_WARN([GDI32 library not found, setting enable_wingcc=no])
48
 
            GDI32LIBDIR=default
 
79
        if test -z "$with_gdi32_libdir"; then
 
80
            AC_MSG_WARN([gdi32 library not found, setting enable_wingcc=no])
 
81
            with_gdi32_libdir=default
49
82
            enable_wingcc=no
50
83
        fi ])
51
 
    fi
52
 
    if test "$GDI32LIBDIR" = "/usr/lib"; then
53
 
        GDI32LIBDIR=default
54
 
    fi
 
84
    else
 
85
        AC_MSG_NOTICE("User-specified path to libgdi32 is $with_gdi32_libdir")
 
86
    fi
 
87
    if test "$with_gdi32_libdir" = "/usr/lib"; then
 
88
        with_gdi32_libdir=default
 
89
    fi
 
90
    GDI32LIBSTR=-lgdi32
 
91
    GDI32LIBCMD=""
 
92
    GDI32LIBPATH=""
 
93
    PL_ADD_TO_LIBS($with_gdi32_libdir, $GDI32LIBSTR, GDI32LIBCMD, GDI32LIBPATH)
55
94
fi
56
95
 
57
 
GDI32LIBCMD=""
58
 
GDI32LIBPATH=""
59
 
if test "$enable_wingcc" = "yes"; then
60
 
    PL_ADD_TO_LIBS($GDI32LIBDIR, $GDI32LIBSTR, GDI32LIBCMD, GDI32LIBPATH)
61
 
fi
 
96
AC_SUBST(GDI32INCCMD)
62
97
AC_SUBST(GDI32LIBCMD)
63