Skip to content

Commit

Permalink
Merge branch '4572_cleanup'
Browse files Browse the repository at this point in the history
* 4572_cleanup: (43 commits)
  Update po/*.po.
  Update copyright years.
  maint/update-years.sh: add command to restore script permissions.
  (check_dir_is_empty): handle the return value of mc_opendir().
  viewer: type accuracy related to the WView::locked flag.
  mcedit: type accuracy.
  mcedit: reset WEdit::locked flag at file unlock.
  WEdit: remove unused member max_column.
  search: change types of start and end search positions from gsize to off_t.
  mcedit (editsearch): minor refactoring.
  (edit_search_show_error): rename from edit_show_search_error.
  mcedit: move definition of edit_search_options_t to editsearch.c.
  src/vfs/tar/tar.c: fix typos.
  (size_trunc_len): fix Undefined Binary Operator Result.
  (quick_create_labeled_input): fix potential leak of memory.
  (listbox_drawscroll:) fix division by zero warning.
  (edit_dialog_search_show): fix uninitialized value and null pointer dereference.
  mcedit: fix uninitialized value function call.
  (configure_box): fix uninitialized value function call.
  (quick_dialog_skip): fix undefined behavior.
  ...
  • Loading branch information
aborodin committed Jan 11, 2025
2 parents 2503882 + 04e3dfa commit dbc92b8
Show file tree
Hide file tree
Showing 319 changed files with 3,216 additions and 2,937 deletions.
59 changes: 29 additions & 30 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,9 @@ if $HAVE_nroff; then
AC_CACHE_VAL(mc_cv_mandoc, [
nroff -mandoc < /dev/null > /dev/null 2>&1
if test $? = 0; then
mc_cv_mandoc=-mandoc
mc_cv_mandoc=-mandoc
else
mc_cv_mandoc=-man
mc_cv_mandoc=-man
fi
])
MANDOC=$mc_cv_mandoc
Expand All @@ -109,9 +109,9 @@ if $HAVE_nroff; then
AC_CACHE_VAL(mc_cv_man_nocolor, [
nroff -c < /dev/null > /dev/null 2>&1
if test $? = 0; then
mc_cv_man_nocolor=-c
mc_cv_man_nocolor=-c
else
mc_cv_man_nocolor=
mc_cv_man_nocolor=
fi
])
MAN_FLAGS=$mc_cv_man_nocolor
Expand All @@ -122,12 +122,12 @@ if $HAVE_nroff; then
mc_cv_nroff_tascii=
nroff -Tlatin1 < /dev/null > /dev/null 2>&1 /dev/null
if test $? = 0; then
mc_cv_nroff_tascii=-Tlatin1
mc_cv_nroff_tascii=-Tlatin1
else
nroff -Tascii < /dev/null > /dev/null 2>&1 /dev/null
if test $? = 0; then
mc_cv_nroff_tascii=-Tascii
fi
mc_cv_nroff_tascii=-Tascii
fi
fi
])
AC_MSG_RESULT([${mc_cv_nroff_tascii-no}])
Expand Down Expand Up @@ -239,9 +239,9 @@ dnl Check for header files
dnl ############################################################################

AC_CHECK_HEADERS([string.h memory.h limits.h malloc.h \
utime.h sys/statfs.h sys/vfs.h \
sys/select.h sys/ioctl.h stropts.h arpa/inet.h \
sys/socket.h])
utime.h sys/statfs.h sys/vfs.h \
sys/select.h sys/ioctl.h stropts.h arpa/inet.h \
sys/socket.h])
dnl This macro is redefined in m4.include/gnulib/sys_types_h.m4
dnl to work around a buggy version in autoconf <= 2.69.
AC_HEADER_MAJOR
Expand Down Expand Up @@ -318,9 +318,9 @@ dnl Check for functions
dnl ############################################################################

AC_CHECK_FUNCS([\
strverscmp \
strncasecmp \
realpath
strverscmp \
strncasecmp \
realpath
])

dnl getpt is a GNU Extension (glibc 2.1.x)
Expand Down Expand Up @@ -420,17 +420,16 @@ AC_ARG_WITH([gpm-mouse],
case $host_os in
linux*)
if test x$with_gpm_mouse != xno; then
AC_CHECK_LIB(gpm, Gpm_Repeat,
[AC_DEFINE(HAVE_LIBGPM, 1,
[Define to enable gpm mouse support on Linux])
mouse_lib="gpm and xterm"
MCLIBS="$MCLIBS -lgpm"],
AC_CHECK_LIB(gpm, Gpm_Repeat,
[AC_DEFINE(HAVE_LIBGPM, 1, [Define to enable gpm mouse support on Linux])
mouse_lib="gpm and xterm"
MCLIBS="$MCLIBS -lgpm"],
if test "x$with_gpm_mouse" = "xyes"; then
[AC_MSG_ERROR([libgpm is missing or older than 0.18])]
else
[AC_MSG_WARN([libgpm is missing or older than 0.18])]
fi
)
)
fi
;;
esac
Expand Down Expand Up @@ -477,12 +476,12 @@ AC_ARG_WITH([diff_viewer],
AS_HELP_STRING([--with-diff-viewer], [Compile with diff viewer @<:@yes@:>@]))

if test x$with_diff_viewer != xno; then
AC_DEFINE(USE_DIFF_VIEW, 1, [Define to enable diff viewer])
use_diff=yes
diff_msg="yes"
AC_MSG_NOTICE([using diff viewer])
AC_DEFINE(USE_DIFF_VIEW, 1, [Define to enable diff viewer])
use_diff=yes
diff_msg="yes"
AC_MSG_NOTICE([using diff viewer])
else
diff_msg="no"
diff_msg="no"
fi

mc_SUBSHELL
Expand Down Expand Up @@ -522,20 +521,20 @@ ALL_DOC_LINGUAS="es hu it pl ru sr"
DOC_LINGUAS=
if test "x$USE_NLS" = xyes; then
if test -z "$LINGUAS"; then
langs="`grep -v '^#' $srcdir/po/LINGUAS`"
langs="`grep -v '^#' $srcdir/po/LINGUAS`"
else
langs="$LINGUAS"
langs="$LINGUAS"
fi
else
langs=
fi

for h_lang in $ALL_DOC_LINGUAS; do
for lang in $langs; do
if test "$lang" = "$h_lang"; then
DOC_LINGUAS="$DOC_LINGUAS $lang"
break
fi
if test "$lang" = "$h_lang"; then
DOC_LINGUAS="$DOC_LINGUAS $lang"
break
fi
done
done
AC_SUBST(DOC_LINGUAS)
Expand Down
11 changes: 1 addition & 10 deletions doc/HACKING
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,7 @@ lists.
Compiling from GIT
==================

To compile GNU Midnight commander from GIT, the following software is
required:

Autoconf 2.64 and above (latest is recommended)
Automake 1.14 and above (latest is recommended)
Gettext 0.18.2 and above
Glib 2.32 and above

Full list of requirements you can see at:
https://www.midnight-commander.org/wiki/doc/buildAndInstall/req
The full list of requirements is listed in the INSTALL file.

It is recommended that all those tools are installed with the same
prefix. Make sure that the tools with the right version are first in
Expand Down
81 changes: 29 additions & 52 deletions doc/INSTALL
Original file line number Diff line number Diff line change
@@ -1,18 +1,40 @@
Build requirements for GNU Midnight Commander
---------------------------------------------

- glibc
- gcc
- glibc or uClibc or musl
- https://www.gnu.org/software/libc/
- https://uclibc.org
- https://www.musl-libc.org
- gcc or clang
- https://gcc.gnu.org
- https://clang.llvm.org
- make
- https://www.gnu.org/software/make/
- autoconf >= 2.64
- https://www.gnu.org/software/autoconf/
- automake >= 1.14
- https://www.gnu.org/software/automake/
- libtool
- https://www.gnu.org/software/libtool/
- pkg-config (optional)
- https://pkg-config.freedesktop.org/wiki/
- glib2 >= 2.32
- slang2 or ncurses
- https://www.gtk.org
- slang2 or ncurses screen library
- https://www.jedsoft.org/slang/
- https://invisible-island.net/ncurses/ncurses.html
- gettext >= 0.18.2
- libssh2 >= 1.2.8 is required only for sftp vfs
- libaspell to support spell checking in the internal editor
- ext2fs >= 1.42.4 to support ext{2,3,4}fs extended attributes
- https://www.gnu.org/software/gettext/
- pcre or pcre2 (as an alternative to glib-regexp)
- https://www.pcre.org
- gpm (general purpose mouse daemon as an alternative to xterm mouse)
- https://www.nico.schottelius.org/software/gpm/
- libssh2 >= 1.2.8 (required only for sftp vfs)
- https://libssh2.org
- libaspell (spell checking support in the internal editor)
- http://aspell.net
- ext2fs >= 1.42.4 (support for ext{2,3,4}fs extended attributes)
- https://e2fsprogs.sourceforge.net


Installation instructions for GNU Midnight Commander
Expand Down Expand Up @@ -222,61 +244,16 @@ only needed on systems where users cannot access /dev/vcsaN, where N is
the virtual console number, on which the uses is logged on.


Obtaining related software
--------------------------

glib
----

The only "hard" dependency of GNU Midnight Commander is glib. You can
get glib from

* https://download.gnome.org/sources/glib/

Minimal version of glib: 2.32.0
Recommended version: 2.32.x and higher.

Newer versions may work, but haven't been tested.

PCRE
----

Both PCRE and PCRE2 libraries are supported. You can get PCRE from

* https://www.pcre.org

Terminal database
-----------------

There are many incomplete terminal databases out there, however, a
complete terminfo is bundled with ncurses. (It is simple to generate
the termcap database using the infocmp utility in ncurses).

Some terminfo data are included with the mc distribution (lib/*.ti).
Particularly linux, xterm and vt100. Use e.g. ''tic linux.ti'' to use
them.

If you want to run mc on xterm/color_xterm/ansi_xterm (not rxvt), then
you might read lib/README.xterm for further information.

Screen libraries
----------------

GNU Midnight Commander can use the included version of S-Lang, but you
can get the latest version here:

* https://www.jedsoft.org/slang/

Alternatively, you can use ncurses:

* https://invisible-island.net/ncurses/announce.html

Mouse support
-------------

The general purpose mouse (gpm) daemon is available from
you might read contrib/README.xterm for further information.

* https://www.nico.schottelius.org/software/gpm/

Porting
-------
Expand Down
2 changes: 1 addition & 1 deletion lib/charsets.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
Text conversion from one charset to another.
Copyright (C) 2001-2024
Copyright (C) 2001-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/event/event.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Handle events in application.
Interface functions: init/deinit; start/stop
Copyright (C) 2011-2024
Copyright (C) 2011-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/event/manage.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Handle any events in application.
Manage events: add, delete, destroy, search
Copyright (C) 2011-2024
Copyright (C) 2011-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/event/raise.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Handle any events in application.
Raise events.
Copyright (C) 2011-2024
Copyright (C) 2011-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/filehighlight/common.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
File highlight plugin.
Interface functions
Copyright (C) 2009-2024
Copyright (C) 2009-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/filehighlight/get-color.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
File highlight plugin.
Interface functions. get color pair index for highlighted file.
Copyright (C) 2009-2024
Copyright (C) 2009-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/filehighlight/ini-file-read.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
File highlight plugin.
Reading and parse rules from ini-files
Copyright (C) 2009-2024
Copyright (C) 2009-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/glibcompat.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
GLIB - Library of useful routines for C programming
Copyright (C) 2009-2024
Copyright (C) 2009-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/global.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
Global structure for some library-related variables
Copyright (C) 2009-2024
Copyright (C) 2009-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/hook.c
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
Slavaz: Warning! this file is deprecated and should be replaced
by mcevents functional.
Copyright (C) 1994-2024
Copyright (C) 1994-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/keybind.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
Definitions of key bindings.
Copyright (C) 2005-2024
Copyright (C) 2005-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/lock.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
File locking
Copyright (C) 2003-2024
Copyright (C) 2003-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/logging.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
Provides a log file to ease tracing the program.
Copyright (C) 2006-2024
Copyright (C) 2006-2025
Free Software Foundation, Inc.
Written by:
Expand Down
2 changes: 1 addition & 1 deletion lib/mcconfig/common.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
Configure module for the Midnight Commander
Copyright (C) 1994-2024
Copyright (C) 1994-2025
Free Software Foundation, Inc.
This file is part of the Midnight Commander.
Expand Down
2 changes: 1 addition & 1 deletion lib/mcconfig/get.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
Configure module for the Midnight Commander
Copyright (C) 1994-2024
Copyright (C) 1994-2025
Free Software Foundation, Inc.
This file is part of the Midnight Commander.
Expand Down
Loading

0 comments on commit dbc92b8

Please sign in to comment.