Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2001-04-05
06:52 • Ticket [219036ffff] Configuration script modification for Digital Unix &... artifact: 07d0dee044 user: dgp
2000-10-26
08:34 • Closed ticket [219036ffff]. artifact: e73872f405 user: welch
01:09 • New ticket [219036ffff]. artifact: 35e7ab673f user: nobody

Configuration script modification for Digital Unix & Ultrix

Closed / Fixed219036ffffffffffffffffffffffffffffffffffCreated 26 years agoUpdated 26 years ago
Descriptionplain2000-10-26 01:09:43
OriginalBugID: 4063 Bug
Version: 8.3b2
SubmitDate: '2000-01-24'
LastModified: '2000-01-25'
Severity: MED
Status: Released
Submitter: techsupp
ChangedBy: hobbs
OS: Digital Unix
OSVersion: DigitalUnix-4.0F and Ultrix-4.4
Machine: AlphaServer and DecStation
FixedDate: '2000-01-25'
FixedInVersion: 8.3
ClosedDate: '2000-10-25'


Name: kazuro furukawa

Comments:
Above modifications are necessary for DigitalUnix and Ultrix.
Both of them have tzset-localtime bugs, which could not be cured even with -DTZSET.
Although generated Makefile is correct, something is not correct internally with thread in tcl.m4.

ReproducibleScript:
./configure

ObservedBehavior:
Configuration and compilation fails if the thread support is enabled.

DesiredBehavior:
Successful test results.

Patch:
*** unix/configure.in.org       Fri Jan 14 12:53:51 2000
--- unix/configure.in   Tue Jan 18 20:52:45 2000
***************
*** 408,417 ****

  SC_TCL_LINK_LIBS

- # Add the threads support libraries
- 
- LIBS="$LIBS$THREADS_LIBS"
- 
  #--------------------------------------------------------------------
  # The statements below define a collection of compile flags.  This
  # macro depends on the value of SHARED_BUILD, and should be called
--- 408,413 ----
***************
*** 419,424 ****
--- 415,424 ----
  #--------------------------------------------------------------------

  SC_CONFIG_CFLAGS
+ 
+ # Add the threads support libraries
+ 
+ LIBS="$LIBS$THREADS_LIBS"

  SC_ENABLE_SYMBOLS

*** unix/tcl.m4.org     Fri Jan 14 12:53:51 2000
--- unix/tcl.m4 Thu Jan 20 01:15:26 2000
***************
*** 857,869 ****
            DL_LIBS=""
            LDFLAGS=""
            LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
            # see pthread_intro(3) for pthread support on osf1, k.furukawa
            if test "${TCL_THREADS}" = "1" ; then
                if test "$using_gcc" = "no" ; then
!                   EXTRA_CFLAGS="-std1 -pthread"
                    LDFLAGS="-pthread"
                else
!                   THREADS_LIBS=" -lpthread -lmach -lexc -lc"
                fi
            fi
            ;;
--- 857,875 ----
            DL_LIBS=""
            LDFLAGS=""
            LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
+           EXTRA_CFLAGS="-DHAVE_TZSET"
+           if test "$using_gcc" = "no" ; then
+               EXTRA_CFLAGS="${EXTRA_CFLAGS} -std1"
+           fi
            # see pthread_intro(3) for pthread support on osf1, k.furukawa
+           THREADS_LIBS=""
            if test "${TCL_THREADS}" = "1" ; then
+               EXTRA_CFLAGS="${EXTRA_CFLAGS} -DTCL_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64"
                if test "$using_gcc" = "no" ; then
!                   EXTRA_CFLAGS="${EXTRA_CFLAGS} -pthread"
                    LDFLAGS="-pthread"
                else
!                   THREADS_LIBS=" -lpthread -lmach -lexc"
                fi
            fi
            ;;
***************
*** 981,986 ****
--- 987,996 ----
            DL_LIBS=""
            LDFLAGS="-Wl,-D,08000000"
            LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
+           EXTRA_CFLAGS="-DHAVE_TZSET"
+           if test "$using_gcc" = "no" ; then
+               EXTRA_CFLAGS="${EXTRA_CFLAGS} -std1"
+           fi
            ;;
        UNIX_SV* | UnixWare-5*)
            SHLIB_CFLAGS="-KPIC"
*** unix/tclUnixPort.h.org      Fri Oct 29 12:04:58 1999
--- unix/tclUnixPort.h  Thu Jan 13 06:25:25 2000
***************
*** 36,41 ****
--- 36,42 ----
   *---------------------------------------------------------------------------
   */

+ #include <sys/types.h>
  #include <utime.h>
  #include <errno.h>
  #include <fcntl.h>
***************
*** 47,53 ****
  #ifdef HAVE_SYS_PARAM_H
  #   include <sys/param.h>
  #endif
- #include <sys/types.h>
  #ifdef USE_DIRENT2_H
  #   include "../compat/dirent2.h"
  #else
--- 48,53 ----
*** generic/tclClock.c.org      Wed Jan 12 20:12:52 2000
--- generic/tclClock.c  Tue Jan 18 21:03:06 2000
***************
*** 274,287 ****
      /*
       * Some systems forgot to call tzset in localtime, make sure its done.
       */
!     static int  calledTzset = 0;

!     Tcl_MutexLock(&clockMutex);
!     if (!calledTzset) {
!         tzset();
!         calledTzset = 1;
      }
-     Tcl_MutexUnlock(&clockMutex);
  #endif

  #ifndef HAVE_TM_ZONE
--- 274,289 ----
      /*
       * Some systems forgot to call tzset in localtime, make sure its done.
       */
!     {
!       static int  calledTzset = 0;

!       Tcl_MutexLock(&clockMutex);
!       if (!calledTzset) {
!           tzset();
!           calledTzset = 1;
!       }
!       Tcl_MutexUnlock(&clockMutex);
      }
  #endif

  #ifndef HAVE_TM_ZONE

PatchFiles:
unix/configure.in
    unix/tcl.m4
    unix/tclUnixPort.h
    generic/tclClock.c



Patch one (for configure.in) is not viable because it breaks other
platforms that require it.  Something else is need to reset the
LIBS as needed on OSF1.  A variation of the m4 patches were made.

*The user should verify these in CVS ASAP*.  They will appear in
the external CVS by Thursday, Jan 27.

For tclUnixPort.h, the utime was moved lower, and a different solution
was found for tclClock.c 
-- 01/25/2000 hobbs
welch Closed ticket [219036ffff]. [History diff]2000-10-26 08:34:05
dgp Ticket [219036ffff]: 4 changes [History diff]2001-04-05 06:52:47
Log in (anonymous is fine) to add a comment.