Commit Graph

2249 Commits

Author SHA1 Message Date
R. Timothy Edwards 2630ebcde1 Reverted a change made to "select area" earlier in the year, which
changed the behavior from selecting subcells if they are unexpanded
to selecting subcells regardless of the expansion state.  The
change was short-sighted and the implementation hard to use.  There
is a need, I think, for a selection method that effectively
unexpands instances, selects everything, and re-expands afterward.
But it's not clear if it is better to select all touching instances
or instances inside the box area;  maybe only interacting
instances (instances with non-space content inside the box).
Regardless, it needs more thought, and meanwhile, the original
behavior works better.
2025-08-04 14:39:10 -04:00
Darryl L. Miles 4e08d178dc appimage: allow git tags with annotation to match expected SHA for ChangeLog
The situation is due to the difference for tags with message / annotation:

$ git tag -l -n1 8.3.534
8.3.534         "Tagging version 8.3.534"

$ git show-ref -s -d refs/tags/8.3.534
4426cc859e
1ec8b6ee1a refs/tags/8.3.534^{}

$ git rev-list -n1 refs/tags/8.3.534
1ec8b6ee1a

Use of rev-lsit will always get the commit ID we expect to see for
the workflow, so we allow either of the SHA above to match at the
point of failure.
2025-08-01 10:58:04 -04:00
Darryl L. Miles 3e5502b936 readline/Makefile: clean fix to unwanted error message 2025-08-01 10:55:50 -04:00
R. Timothy Edwards 8ed7394431 Corrected some basic paint code related to drawing over top non-
Manhattan tiles.  After splitting a non-Manhattan tile crossing
a search area to paint, the routine was automatically merging
tiles to the right.  This is incorrect for tiles inside the search
area, as it can cause the search algorithm to miss unvisited tiles
whose origins are to the left of the split tile, resulting in part
of the area not getting painted.
2025-08-01 10:47:01 -04:00
Darryl L. Miles 1ec8b6ee1a appimage: GHA more debugging for fetch --tags issue 2025-07-29 14:41:49 -04:00
R. Timothy Edwards f52d90346e Updated the version to go along with the merge of pull request #428
from Darryl Miles, which overhauled the Makefile and cleaned up a
lot of long-standing minor issues.
2025-07-29 10:56:54 -04:00
Darryl L. Miles b16bcb35bf Makefile: make -j ordering fix 2025-07-29 10:50:32 -04:00
Darryl L. Miles a77c4906f8 Makefile: fix 'force' target to ensure serialization 2025-07-29 10:50:32 -04:00
Darryl L. Miles 8eb2ec9ead Makefile: allow 'modules' and 'libs' to build in parallel
Removes the shell serialisation `for .. in ..` expression

This provides another significant speed up, after */Depend was made
parallel.  x3+ speedup over -j1.
2025-07-29 10:50:32 -04:00
Darryl L. Miles a81184e205 Makefile: cleanup targets: standard tcl
No need for submake.
2025-07-29 10:50:32 -04:00
Darryl L. Miles bcd17d4f85 Makefile: removed errnous echo message for make.log 2025-07-29 10:50:32 -04:00
Darryl L. Miles f513a0ca3b Makefile: check make depend is parallel 2025-07-29 10:50:32 -04:00
Darryl L. Miles 4aee95e092 autoconf: utilize HAVE_SYS_IOCTL_COMPAT_H HAVE_TERMIO_H 2025-07-29 10:50:32 -04:00
Darryl L. Miles 92b4d6a1f7 configure: autoconf regen (2.69) AC_CHECK_HEADERS sys/ioctl_compat.h sgtty.h 2025-07-29 10:50:32 -04:00
Darryl L. Miles 730d327702 configure.in: AC_CHECK_HEADERS sys/ioctl_compat.h sgtty.h 2025-07-29 10:50:32 -04:00
Darryl L. Miles be6483bf4b GHA: main-macos.yml brew install gnu-sed 2025-07-29 10:50:32 -04:00
Darryl L. Miles 8485820526 GHA: main.yml: emit defs.mak into CI logging 2025-07-29 10:50:32 -04:00
Darryl L. Miles 54bbedfdbb INSTALL_MacOS.md: Update to install gnu-sed
The platform /usr/bin/sed does this:

/usr/bin/sed -e "/#/D" -e "/ \//s/ \/.*\.h//" -e "/  \\\/D" -i Depend$PPID.tmp
sed: -I or -i may not be used with stdin

But a filename was specified, so the error should be file does not exist
2025-07-29 10:50:32 -04:00
Darryl L. Miles b1e2913435 Makefile: sed => ${SED}
This will find GNU make in preference if available on the platform.
2025-07-29 10:50:32 -04:00
Darryl L. Miles f179d1240e Makefile: rm => ${RM} 2025-07-29 10:50:32 -04:00
Darryl L. Miles 6f304318ec Makefile: ln => ${LN} 2025-07-29 10:50:32 -04:00
Darryl L. Miles 6b0bc5bbdc SunOS: FOPEN rename to magicFOPEN due to sys/file.h definition
Example build issue using SunOS Solaris solaris 5.11 11.4.42.111.0 i86pc i386
with gcc version 5.5.0 (GCC).

It turns out the definition is not used by the magic codebase.  So only the
macro name is changed by this commit.

This platform also has a definition for FREAD but the MacOS patch can be used
to rename that.

 In file included from DBio.c:51:0:
 ../utils/magic.h:141:0: warning: "FOPEN" redefined
      #define FOPEN    gzopen
  ^
 In file included from DBio.c:30:0:
 /usr/include/sys/file.h:74:0: note: this is the location of the previous definition
  #define FOPEN  0xffffffff
  ^

 In file included from DBio.c:51:0:
 ../utils/magic.h:144:0: warning: "FREAD" redefined
      #define FREAD(a,b,c,d)    gzread(d,a,b*c)
  ^
 In file included from DBio.c:30:0:
 /usr/include/sys/file.h:75:0: note: this is the location of the previous definition
  #define FREAD  0x01 /* <sys/aiocb.h> LIO_READ must be identical */
  ^
2025-07-29 10:50:32 -04:00
Darryl L. Miles 778201fbc2 DBio.c: HAVE_STRUCT_DIRENT_D_TYPE direct->d_type 2025-07-29 10:50:32 -04:00
Darryl L. Miles c3054f265b configure: autoconf regen (2.69) LIBS 2025-07-29 10:50:32 -04:00
Darryl L. Miles a8f5291bd7 defs.mak.in: restore autoconf LIBS functionality
This is a standard autoconf variable, it was probably disabled due to
how the graphics/Makefile works and the more complex detection taking
place there.

Needed to use it to add -lpthread to some platforms (freebsd/openbsd)
to make it build out the box.
2025-07-29 10:50:32 -04:00
Darryl L. Miles aaa477e44a configure: autoconf regen (2.69) AC_STRUCT_DIRENT_D_TYPE 2025-07-29 10:50:32 -04:00
Darryl L. Miles f45aeb6cee configure.in: AC_STRUCT_DIRENT_D_TYPE 2025-07-29 10:50:32 -04:00
Darryl L. Miles 9f0f5f5b4e configure: autoconf regen (2.69) AC_PATH_PROG(PERL,) AC_SUBST(PERL) 2025-07-29 10:50:32 -04:00
Darryl L. Miles ec7d0fc79a configure.in: AC_PROG_PERL 2025-07-29 10:50:32 -04:00
Darryl L. Miles d2449dc971 configure: autoconf regen (2.69) AC_PROG_SED 2025-07-29 10:50:32 -04:00
Darryl L. Miles e51189911b configure.in: AC_PROG_SED (looking for GNU sed) 2025-07-29 10:50:32 -04:00
Darryl L. Miles 3ca0b616c0 Makefile: toplevel 'make techs' target to process scmos during build
Previously it would only build the 'scmos' subdir when the
'make install' target is running, which is done sudo.  This
would result in a number of files in scmos/cif_template/objs
to be owned by 'root'.

Renamed TECH to TECHS which is inline with the other caregories
MODULES and LIBS.
2025-07-29 10:50:32 -04:00
Darryl L. Miles 412d0570e2 configure: autoconf regen (2.69) ALLOCA NDEBUG DEBUG
also --enable-assertions --enable-debug
also termio.h termios.h sys/ioctl.h
2025-07-29 10:50:32 -04:00
Darryl L. Miles 9f1398dfcb utils/magsgtty.h: detect termio/ioctl headers
Linux is not based on BSD and this file appears to exist to manage
historic BSD conventions concerning termios.
2025-07-29 10:50:32 -04:00
Darryl L. Miles c5ebd7d3c0 makedbh.in _DATABASE_H => _MAGIC__DATABASE__DATABASE_H 2025-07-29 10:50:32 -04:00
Darryl L. Miles 2db18509c5 header file #endif guard middle program once style consistency 2025-07-29 10:50:32 -04:00
Darryl L. Miles d55a2b74ac header file #ifndef guard namespace consistency (global change)
This add an effective namespace prefix to the guard ifndef
2025-07-29 10:50:32 -04:00
Darryl L. Miles 5e17855f31 header file #ifndef guard presence consistency 2025-07-29 10:50:32 -04:00
Darryl L. Miles 3294524111 header file #endif guard trailer comment consistency
oa/magicInit.h
utils/malloc.h
2025-07-29 10:50:32 -04:00
Darryl L. Miles de1b76cb11 niceabort.c: include <time.h> remove preC89 declarations 2025-07-29 10:50:32 -04:00
Darryl L. Miles b6e70f9632 utils/magic_alloca.h: with autoconf AC_FUNC_ALLOCA
Unclear what the correct Copyright header should be on this one,
given most of the lines in the file are from the autoconf
documentation.
2025-07-29 10:50:32 -04:00
Darryl L. Miles f88c7a86cb utils/magic_zlib.h: limit #include <zlib.h> to files that need it
Remove limited use HAVE_ZLIB wrapper API into separate header as
utils.h is used in many places and most source files don't need
to drag in the header file from this external dependency.

Copyright date(s) taken from original source file / git blame.
2025-07-29 10:50:32 -04:00
Darryl L. Miles 4a1da7fe7c utils/magic_assert.h: separate assert.h and ASSERT
This is a low level thing that other lowlevel API (platform shims for
strlen_s() and ctime_r() want to make use of, without any application
global pollution).

Copyright date(s) taken from git blame information for moved lines.
2025-07-29 10:50:32 -04:00
Darryl L. Miles 4d2def46f4 configure.in: whitespace cleanup align --help columns 2025-07-29 10:50:32 -04:00
Darryl L. Miles 49caa3267b configure: --enable-debug make this a user accessible config
This should help with automated CI testing as well, where a suite
can be run and debug enabled and checked, just via a specific
CI setup.
2025-07-29 10:50:32 -04:00
Darryl L. Miles dd49ca21d2 configure: --enable-assertions make this a user accessible config
This should help with automated CI testing as well, where a suite
can be run and assertions enabled and checked, just via a specific
CI setup.
2025-07-29 10:50:32 -04:00
Darryl L. Miles 2a78de8cb9 magic/Makefile: MAGIC_BUILDDATE and inherit values when possible
Went the whole way and make it inherit from toplevel Makefile.
2025-07-29 10:50:32 -04:00
Darryl L. Miles 4e7396162d scripts/configure: autoconf regen (2.69) MAKE_xxxxx generation 2025-07-29 10:50:32 -04:00
Darryl L. Miles d13fa6872e MAKE_xxxxx: to skip building OBJs part of configure 2025-07-29 10:50:32 -04:00
Darryl L. Miles bd541d3e6f rules.mak: fix module Depend and build rules
The ../database/database.h dependency is already described (only when
necessary) inside the Depend file for the specific complication unit.
Not all objects are affected by database.h changes, so it doesn't need
to be forced as a dependency for all OBJS.

Depend itself was never rebuilt when a source file changed.  This now
happens, however technically the superior MAKE process needs to restart
so it includes the new updated copy of Depend file we just updated.
However in practice when developing, modifying #include directives does
not happen often and doing 'make; make' will fix the issue performing
an incremental build both times.  So a minor caveat.

Previously when a single source file was changed the entire module was
recompiled, but we have a Depends file to manage the incremental build
problem and we are not really using it (if we always recompile the entire
module due to any one file change, there would be no need for Depends).

Now when developing, a single *.c file change results in the Depends
being rebuilt, then the single file compiled, then the module relinked.
This is exactly the kind of incremental build speedup having a Depends
file is designed to achieve.

Additionally the use of a direct pipeline to create the file does not
manage error scenarios.  MAKE itself is driven by file existance and
their timestamps for targets, so even if 'make depend' failed, it
would still create an output file that MAKE can not distunguish
between a well formed (possibly empty) Depend file and an incorrectly
created partial.  So building in a *.tmp file first and only if all the
commands are successful then rename to target filename.  This has the
effect of making 'make depend' able to fail now.
2025-07-29 10:50:32 -04:00