Changeset 3259 for trunk/base/tcl.m4


Ignore:
Timestamp:
Aug 16, 2003, 9:11:40 AM (17 years ago)
Author:
landonf (Landon Fuller)
Message:

Move OD_TCL_PACKAGE_DIR from tcl.m4 to aclocal.m4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/base/tcl.m4

    r2803 r3259  
    25672567    AC_SUBST(TCL_INCLUDES)
    25682568])
    2569 
    2570 #------------------------------------------------------------------------
    2571 # OD_TCL_PACKAGE_DIR --
    2572 #
    2573 #       Locate the correct directory for Tcl package installation
    2574 #
    2575 # Arguments:
    2576 #       None.
    2577 #
    2578 # Requires:
    2579 #       TCLVERSION must be set
    2580 #       CYGPATH must be set
    2581 #
    2582 # Results:
    2583 #
    2584 #       Adds a --with-tclpackage switch to configure.
    2585 #       Result is cached.
    2586 #
    2587 #       Substs the following vars:
    2588 #               TCL_PACKAGE_DIR
    2589 #------------------------------------------------------------------------
    2590 
    2591 AC_DEFUN(OD_TCL_PACKAGE_DIR, [
    2592     AC_MSG_CHECKING(for Tcl package directory)
    2593 
    2594     AC_ARG_WITH(tclpackage, [  --with-tclpackage       Tcl package installation directory.], with_tclpackagedir=${withval})
    2595 
    2596     if test x"${with_tclpackagedir}" != x ; then
    2597         ac_cv_c_tclpkgd=${with_tclpackagedir}
    2598     else
    2599         AC_CACHE_VAL(ac_cv_c_tclpkgd, [
    2600             # Use the value from --with-tclpackagedir, if it was given
    2601 
    2602             if test x"${with_tclpackagedir}" != x ; then
    2603                 ac_cv_c_tclpkgd=${with_tclpackagedir}
    2604             else
    2605                 if test "`uname -s`" = "Darwin" ; then
    2606                     if test -d "/System/Library/Tcl/"; then
    2607                         ac_cv_c_tclpkgd="/System/Library/Tcl/"
    2608                     fi
    2609                 else
    2610                     for i in /usr/lib /usr/pkg/lib /usr/local/lib; do
    2611                         if test -d "$i/tcl$TCL_VERSION" ; then
    2612                             ac_cv_c_tclpkgd="$i/tcl$TCL_VERSION/"
    2613                         fi
    2614                     done
    2615                 fi
    2616             fi
    2617         ])
    2618     fi
    2619 
    2620     if test x"${ac_cv_c_tclpkgd}" = x ; then
    2621         AC_MSG_ERROR(Tcl package directory not found.  Please specify its location with --with-tclpackagedir)
    2622     else
    2623         AC_MSG_RESULT(${ac_cv_c_tclpkgd})
    2624     fi
    2625 
    2626     # Convert to a native path and substitute into the output files.
    2627 
    2628     PACKAGE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tclpkgd}`
    2629 
    2630     TCL_PACKAGE_DIR=${PACKAGE_DIR_NATIVE}
    2631 
    2632     AC_SUBST(TCL_PACKAGE_DIR)
    2633 ])
Note: See TracChangeset for help on using the changeset viewer.