[Tcsh] tcsh and Alpine Linux: progress, anyone?

Nelson H. F. Beebe beebe at math.utah.edu
Sat Nov 26 20:07:51 UTC 2022


Chritos Zoulas <christos at zoulas.com> suggests that one could handle
the oddity of Alpine Linux like this:

>> I guess one can do something weird like:
>> defined(__linux__) && !defined(__GLIBC__)
>> to work around this...

Excellent!  How about considering this change in the tcsh source code,
adding two lines to config_f.h:

% diff -c config_f.h.org config_f.h
*** config_f.h.org      Wed Nov 23 15:29:09 2022
--- config_f.h  Sat Nov 26 12:31:15 2022
***************
*** 149,154 ****
--- 149,156 ----
   */
  #if defined(__MACHTEN__) || defined(PURIFY) || defined(MALLOC_TRACE) || defined(_OSD_POSIX) || defined(__MVS__) ||
defined (__CYGWIN__) || defined(__GLIBC__) || defined(__OpenBSD__) || defined(__APPLE__) || defined (__ANDROID__) ||
defined(__NetBSD__)
  # define SYSMALLOC
+ #elif defined(__linux__) && !defined(__GLIBC__) /* maybe Alpine Linux, or other musl C library systems */
+ # define SYSMALLOC
  #else
  # undef SYSMALLOC
  #endif

I made a locally patched distribution, tcsh-6.24.02.p1, with that
change, and have successfully built (with both gcc and clang) and
installed tcsh on Alpine 3.15, 3.16, and 3.17 systems here, 
adjusted /etc/shells and /etc/passwd to reflect the availability of
tcsh for local user accounts on those systems, and verified
successful logins running tcsh on those systems.


-------------------------------------------------------------------------------
- Nelson H. F. Beebe                    Tel: +1 801 581 5254                  -
- University of Utah                                                          -
- Department of Mathematics, 110 LCB    Internet e-mail: beebe at math.utah.edu  -
- 155 S 1400 E RM 233                       beebe at acm.org  beebe at computer.org -
- Salt Lake City, UT 84112-0090, USA    URL: http://www.math.utah.edu/~beebe/ -
-------------------------------------------------------------------------------


More information about the Tcsh mailing list