David Griffith [Wed, 4 Sep 2019 07:30:11 +0000 (00:30 -0700)]
Update sfrotz manpage to talk about Unicode support.
David Griffith [Wed, 4 Sep 2019 06:56:52 +0000 (23:56 -0700)]
Add some tweaks for FreeBSD; no sound curses interface.
David Griffith [Wed, 4 Sep 2019 02:02:29 +0000 (02:02 +0000)]
Remove extraneous parentheses.
David Griffith [Tue, 3 Sep 2019 07:05:56 +0000 (07:05 +0000)]
Merge branch 'more-pkg-config' into 'master'
More pkg-config fixes for SDL and ncurses
See merge request DavidGriffith/frotz!123
James Le Cuirot [Mon, 2 Sep 2019 21:51:52 +0000 (22:51 +0100)]
Use shell Makefile function to avoid repeatedly calling pkg-config
It was being called many times when using backticks.
James Le Cuirot [Mon, 2 Sep 2019 21:39:03 +0000 (22:39 +0100)]
Use pkg-config to get ncurses(w) flags, falling back to static strings
Using pkg-config ensures that -I/usr/include/ncursesw is added when
necessary. This picks up the correct ncurses.h when both the wide and
non-wide versions are installed.
It also ensures that -ltinfo(w) is added when necessary. Some
distributions such as Gentoo build it as a separate library.
David Griffith [Mon, 2 Sep 2019 01:29:53 +0000 (18:29 -0700)]
Fix mess with defines.
There was an ongoing problem with how I was handling defs.h et al
causing things to be entirely rebuilt or not rebuilt at all without
first doing a "make clean". This fixes those problems that were last
addressed in
03e0c58b2363e5daecc29da44edf27fe4bc4beaa.
David Griffith [Mon, 2 Sep 2019 00:59:17 +0000 (00:59 +0000)]
Merge branch 'toolchain-paths' into 'master'
Don't add $(PREFIX)/include and $(PREFIX)/lib to toolchain paths
See merge request DavidGriffith/frotz!122
David Griffith [Sun, 1 Sep 2019 03:09:01 +0000 (03:09 +0000)]
Merge branch 'pkg-config' into 'master'
Allow building with a specific pkg-config given by PKG_CONFIG
See merge request DavidGriffith/frotz!121
James Le Cuirot [Sat, 31 Aug 2019 13:54:11 +0000 (14:54 +0100)]
Don't add $(PREFIX)/include and $(PREFIX)/lib to toolchain paths
PREFIX is only applicable at install and runtime. The headers and
libraries we're building against may not be in the same location,
particularly if we're cross-compiling. Adding -I/usr/include when
cross-compiling will likely break the build.
It is generally not necessary to add these paths anyway as toolchains
are already configured to look in the appropriate places for system
headers and libraries. There may be exceptions but these can be dealt
with via CFLAGS and LDFLAGS. Perhaps this is necessary for MacPorts
but I'm not familiar with it.
James Le Cuirot [Sat, 31 Aug 2019 13:49:03 +0000 (14:49 +0100)]
Allow building with a specific pkg-config given by PKG_CONFIG
Sometimes wrappers around pkg-config are used for cross-compiling.
David Griffith [Sat, 31 Aug 2019 00:45:56 +0000 (17:45 -0700)]
Remove version.c and put build date back into git_hash.h.
I was never quite satisfied with the way I did version.c. I seem to
recall someone telling me it was improper to put the build date into
git_hash.h. After a couple months of this, I looked again and realized
that I picked an irritating solution -- Frotz will always be rebuilt
when doing "make install". The difference between when version.c is
created and when someone is done monkeying with the build process does
not seem to be of much consequence.
David Griffith [Fri, 30 Aug 2019 22:57:55 +0000 (22:57 +0000)]
Merge branch 'keydelay' into 'master'
Swallow unexpected timeout keycode
See merge request DavidGriffith/frotz!120
David Griffith [Fri, 30 Aug 2019 22:48:26 +0000 (15:48 -0700)]
Remove R from getopt that isn't being used for anything yet.
I just noticed that the -R flag for restricting where sfrotz is allowed
to read and write is not implemented. This feature isn't quite as useful
for the SDL interface as it is for the curses and dumb interfaces, so
I'll give this a 2.46 milestone. If anyone reading this issue feels like
implementing this now, that's great and I'll merge it when you're done.
David Griffith [Fri, 30 Aug 2019 22:39:04 +0000 (15:39 -0700)]
Fix improper way of checking for uninitialized string.
Bill Lash [Fri, 30 Aug 2019 02:52:02 +0000 (21:52 -0500)]
Swallow unexpected timeout keycode
Insted of passing on an timeout event when there is no timeout set,
just skip it.
David Griffith [Thu, 29 Aug 2019 03:30:13 +0000 (03:30 +0000)]
Merge branch 'keydelay' into 'master'
Check to see if a timeout is expected
Closes #136
See merge request DavidGriffith/frotz!119
Bill Lash [Thu, 29 Aug 2019 02:10:16 +0000 (21:10 -0500)]
Check to see if a timeout is expected
When a timeout keycode is received, make sure that it is expected,
otherwise a non-existent timeout routine may be called.
David Griffith [Tue, 27 Aug 2019 22:30:07 +0000 (15:30 -0700)]
Add mention of Unicode by way of UTF-8 in INSTALL.
David Griffith [Mon, 26 Aug 2019 00:39:15 +0000 (17:39 -0700)]
Segfault with -r and no parameter. Add missing colon to zgetopt() call.
David Griffith [Sat, 24 Aug 2019 00:19:19 +0000 (17:19 -0700)]
Move sf_searchfile() from sf_ftype.c to sf_fonts.c.
David Griffith [Fri, 23 Aug 2019 23:44:57 +0000 (16:44 -0700)]
Fix problem with fontdir option in .sfrotzrc not being honored for .bdf fonts.
David Griffith [Tue, 20 Aug 2019 06:19:23 +0000 (23:19 -0700)]
Removed dependency preprocessor stuff that never did anything useful.
These options had the side-effect of forcing the SDL library to be
completely recompiled all the time because build_timestamp in
src/common/version.c is rewritted every time the Makefile is run.
David Griffith [Fri, 16 Aug 2019 04:58:46 +0000 (21:58 -0700)]
Add targets to .PHONY to re-allow partial rebuild.
Somehow when doing
2559eb24b6314939dde07d7bed5927cb37929dda, I neglected
to put $(COMMON_DEFINES) $(CURSES_DEFINES) $(COMMON_STRINGS) $(HASH)
into .PHONY. This had the effect of requiring me to do "make clean ;
make" after altering one file. Otherwise the build would simply report
that blorblib.a is up to date and exit.
David Griffith [Wed, 14 Aug 2019 19:20:16 +0000 (12:20 -0700)]
Fix null trailer problem with Blorb file loading.
David Griffith [Tue, 6 Aug 2019 08:07:10 +0000 (01:07 -0700)]
Ask player if it's okay to overwrite an existing recording file.
David Griffith [Sun, 28 Jul 2019 10:33:32 +0000 (10:33 +0000)]
Merge branch 'sdl_sfrotzrc' into 'master'
Sdl sfrotzrc
See merge request DavidGriffith/frotz!118
Bill Lash [Sun, 28 Jul 2019 03:05:31 +0000 (22:05 -0500)]
Also look for .sfrotzrc in home directory
Bill Lash [Sat, 27 Jul 2019 02:43:36 +0000 (21:43 -0500)]
Merging with upstream
Bill Lash [Sat, 27 Jul 2019 02:41:39 +0000 (21:41 -0500)]
Merge branch 'master' of https://gitlab.com/DavidGriffith/frotz
David Griffith [Tue, 23 Jul 2019 10:42:58 +0000 (03:42 -0700)]
Add stuff needed for NetBSD to build sfrotz. Still messy in sf_ftype.c.
David Griffith [Tue, 23 Jul 2019 10:00:36 +0000 (03:00 -0700)]
Identify host OS as Unix if so. Include unistd.h protected by UNIX define.
David Griffith [Thu, 25 Jul 2019 22:51:20 +0000 (15:51 -0700)]
Add list of packages for sfrotz using NetBSD nomenclature.
David Griffith [Tue, 23 Jul 2019 07:54:47 +0000 (00:54 -0700)]
Remove pointless link to dl library.
David Griffith [Tue, 23 Jul 2019 07:44:25 +0000 (00:44 -0700)]
Add specifics for NetBSD compilation. Remove -ltinfo.
David Griffith [Tue, 23 Jul 2019 06:55:06 +0000 (23:55 -0700)]
Reorder ifdefs to prevent redefinition of wint_t problems in NetBSD.
David Griffith [Mon, 22 Jul 2019 00:38:34 +0000 (17:38 -0700)]
Set h_config and h_flags properly concerning graphics in curses.
I noticed this was being done in the old V6 semi-support for the dumb
interface. For some reason, Alembic didn't see fit to copy it over to
when he submitted his V6 semi-support for the curses interface.
This should probably be done for SDL as well.
David Griffith [Sun, 21 Jul 2019 23:28:27 +0000 (16:28 -0700)]
Added Blorbified V6 semi-support to dumb interface.
David Griffith [Sun, 21 Jul 2019 02:24:02 +0000 (19:24 -0700)]
Add processing of Rect chunks for V6 semi-support.
David Griffith [Thu, 18 Jul 2019 01:06:45 +0000 (18:06 -0700)]
Endian swap not necessary.
David Griffith [Thu, 18 Jul 2019 00:09:23 +0000 (17:09 -0700)]
Update leading comments for Makefiles: for Frotz and GNU make required.
David Griffith [Thu, 18 Jul 2019 00:06:04 +0000 (00:06 +0000)]
Fix problem with an ifdef that should have been ifndef.
David Griffith [Wed, 17 Jul 2019 10:06:14 +0000 (03:06 -0700)]
First stab at V6 semi-support through Blorb in curses. Things are distorted.
Right now, the code detects PNG and JPG images. However, stuff seems to
be done only for Infocom's games and the blorbs made up for them. Even
then, the results are distorted. This may be because rectangle chunks
aren't being processed and the code depends on some chunks that aren't
found in post-Infocom V6 blorbs. Still, here's something to play with.
David Griffith [Mon, 15 Jul 2019 09:42:46 +0000 (02:42 -0700)]
Get the number of CPUs available with Linux. Not doing anything with it yet.
David Griffith [Mon, 15 Jul 2019 09:38:12 +0000 (02:38 -0700)]
Avoid race conditions when doing a parallelized buid.
If the -jX flag is used to indicate that X CPUs should be used to build
Frotz, there is a slight chance that the definitions files:
src/common/defs.h, src/curses/ux_defines.h, and src/common/git_hash.h;
will not be complete before the build process starts on the rest of the
source files. If this happens, the build fails.
David Griffith [Mon, 15 Jul 2019 04:52:56 +0000 (21:52 -0700)]
Fix trouble with wint_t being redefined with NetBSD.
David Griffith [Mon, 15 Jul 2019 04:46:35 +0000 (21:46 -0700)]
Detect NetBSD and add casts to quell complaints with toupper() and isspace().
David Griffith [Mon, 15 Jul 2019 03:53:51 +0000 (20:53 -0700)]
Fix problem with reporting audio enabled when really disabled.
David Griffith [Mon, 15 Jul 2019 03:39:47 +0000 (20:39 -0700)]
Re-add src/common/git_hash.h to .gitignore.
David Griffith [Sun, 14 Jul 2019 09:15:52 +0000 (02:15 -0700)]
Mention CONTRIBUTORS in README.1st.
David Griffith [Sun, 14 Jul 2019 09:14:11 +0000 (02:14 -0700)]
Delete the old and very stale BUGS file.
David Griffith [Sun, 14 Jul 2019 07:53:31 +0000 (00:53 -0700)]
Delete stale link to PDF.
David Griffith [Sun, 14 Jul 2019 00:49:12 +0000 (17:49 -0700)]
Rework lead comments for DOS interface files.
David Griffith [Sun, 14 Jul 2019 00:19:48 +0000 (17:19 -0700)]
Corrected address of the Free Software Foundation.
David Griffith [Sun, 14 Jul 2019 00:16:05 +0000 (17:16 -0700)]
Added README.md for respository use.
David Griffith [Sun, 14 Jul 2019 00:04:51 +0000 (17:04 -0700)]
Some minor edits to README and INSTALL.
David Griffith [Sat, 13 Jul 2019 11:58:16 +0000 (04:58 -0700)]
Merge branch 'fleger1/frotz-story-ids'
David Griffith [Sat, 13 Jul 2019 11:57:46 +0000 (04:57 -0700)]
Indent and space fixes.
David Griffith [Sat, 13 Jul 2019 07:19:52 +0000 (00:19 -0700)]
get_prop_len opcode returns 0 when argument is 0 per Z-machine spec 1.1.
Copied from Windows Frotz.
David Griffith [Sat, 13 Jul 2019 06:55:22 +0000 (23:55 -0700)]
Adding a "nosound" target to build curses interface without audio support.
Previously if you wanted to build Frotz without sound support, you
needed to edit the Makefile.
David Griffith [Fri, 12 Jul 2019 20:55:33 +0000 (13:55 -0700)]
Adding the Praxix tests to test suite.
David Griffith [Fri, 12 Jul 2019 20:53:59 +0000 (20:53 +0000)]
Merge branch 'print_table' into 'master'
Fix @print_table in non-V6 lower window
See merge request DavidGriffith/frotz!117
borg323 [Fri, 12 Jul 2019 14:43:16 +0000 (17:43 +0300)]
Fix @print_table in non-V6 lower window
This is a direct port of commit
7adcf62693ecfc8439260a7abe62c3d5a190c160
from Windows-Frotz:
https://github.com/DavidKinder/Windows-Frotz/commit/
7adcf62693ecfc8439260a7abe62c3d5a190c160
Florian Léger [Fri, 12 Jul 2019 06:57:22 +0000 (08:57 +0200)]
Add a few more story ids for alpha/beta/gamma versions
Some of them come from the WinFrotz source code,
others are from The Obsessively Complete Infocom Catalog.
Florian Léger [Wed, 10 Jul 2019 11:55:17 +0000 (13:55 +0200)]
Add more story ids
David Griffith [Wed, 10 Jul 2019 08:29:58 +0000 (08:29 +0000)]
Merge branch 'resizable' into 'master'
SFROTZ: make window resizable
See merge request DavidGriffith/frotz!114
Florian Léger [Wed, 10 Jul 2019 07:55:04 +0000 (09:55 +0200)]
SFROTZ: make window resizable
David Griffith [Tue, 9 Jul 2019 22:42:59 +0000 (22:42 +0000)]
Merge branch 'win-diff' into 'master'
reduce diff to windows frotz
See merge request DavidGriffith/frotz!113
borg323 [Tue, 9 Jul 2019 14:41:17 +0000 (17:41 +0300)]
remove stale comment
borg323 [Mon, 8 Jul 2019 23:03:53 +0000 (02:03 +0300)]
reduce diff to windows frotz
David Griffith [Mon, 8 Jul 2019 02:13:37 +0000 (19:13 -0700)]
Added another note to the ChangeLog.
David Griffith [Mon, 8 Jul 2019 01:48:37 +0000 (18:48 -0700)]
Add stuff to the ChangeLog.
David Griffith [Mon, 8 Jul 2019 00:08:08 +0000 (00:08 +0000)]
Merge branch 'zchar_cleanup' into 'master'
change os_check_unicode() 2nd argument to zchar
See merge request DavidGriffith/frotz!112
borg323 [Sun, 7 Jul 2019 11:16:04 +0000 (14:16 +0300)]
change os_check_unicode() 2nd argument to zchar
David Griffith [Sat, 6 Jul 2019 02:12:26 +0000 (19:12 -0700)]
Allow for alternative Blorb file at command line for curses, sdl, and dumb.
Doing this for the SDL interface is proved a bit troublesome because
it's not very clear where stuff is being set and where not. After the
audio overhaul release, I want to overhaul the SDL interface code to
make it as closely resemble as feasible that of the curses interface.
David Griffith [Sat, 6 Jul 2019 01:44:35 +0000 (18:44 -0700)]
Merge branch 'welash-audio_repeats'
borg323 [Fri, 5 Jul 2019 22:33:58 +0000 (01:33 +0300)]
curses: filter unicode chars > 0xffff
borg323 [Fri, 5 Jul 2019 16:03:12 +0000 (19:03 +0300)]
scale sdl file dialog with font
borg323 [Fri, 5 Jul 2019 13:48:38 +0000 (16:48 +0300)]
revert sdl to old code when USE_UTF8=no
David Griffith [Fri, 5 Jul 2019 01:15:49 +0000 (18:15 -0700)]
Fix mistake in command line parsing for alternative Blorb.
David Griffith [Fri, 5 Jul 2019 00:56:36 +0000 (00:56 +0000)]
Merge branch 'audio_repeats' into 'master'
First pass at adding repeats for aiff/ogg sounds
See merge request DavidGriffith/frotz!110
David Griffith [Fri, 5 Jul 2019 00:43:12 +0000 (17:43 -0700)]
Allow for alternative Blorb file at command line for dumb and curses.
Doing this for the SDL interface is proving troublesome because it's not
very clear where stuff is being set and where not. After the audio
overhaul release, I want to overhaul the SDL interface code to make it
as closely resemble as feasible that of the curses interface.
borg323 [Fri, 5 Jul 2019 00:19:18 +0000 (03:19 +0300)]
fix sdl file dialog list display
Bill Lash [Thu, 4 Jul 2019 05:59:00 +0000 (00:59 -0500)]
First pass at adding repeats for aiff/ogg sounds
Pass the repeats parameter to load_aiff() and in process_aiff()
if there are repeats try to keep the scratch buffer for the resampler
full.
borg323 [Thu, 4 Jul 2019 12:18:05 +0000 (15:18 +0300)]
improve sdl utf-8 filename entry
David Griffith [Tue, 2 Jul 2019 19:48:01 +0000 (19:48 +0000)]
Merge branch 'issue118' into 'master'
fix sdl char, zchar and zword confusion
See merge request DavidGriffith/frotz!109
borg323 [Tue, 2 Jul 2019 13:34:51 +0000 (16:34 +0300)]
fix sdl char, zchar and zword confusion
David Griffith [Mon, 1 Jul 2019 23:05:02 +0000 (23:05 +0000)]
Merge branch 'issue118' into 'master'
utf-8 input for dumb interface
See merge request DavidGriffith/frotz!108
borg323 [Mon, 1 Jul 2019 15:19:59 +0000 (18:19 +0300)]
utf-8 input for dumb interface
David Griffith [Sun, 30 Jun 2019 01:11:07 +0000 (18:11 -0700)]
Clean up stray trailing whitespace.
David Griffith [Sun, 30 Jun 2019 01:08:41 +0000 (01:08 +0000)]
Merge branch 'fix_wait' into 'master'
Make sure to set the maxwait before each select call
See merge request DavidGriffith/frotz!107
William Lash [Sun, 30 Jun 2019 01:08:41 +0000 (01:08 +0000)]
Make sure to set the maxwait before each select call
On linux at least select will update the timeout value if it returns
before the timeout is up.
It seems that simply moving the ````maxwait.tv_usec=10000;```` statement inside the ````while(1)```` loop significantly reduced CPU usage. We'll keep the timeout at 10 msec until the delay becomes noticable, which so far isn't.
David Griffith [Sat, 29 Jun 2019 00:45:26 +0000 (17:45 -0700)]
Merge branch 'welash/frotz-mac_sema'
Because MacOS lacks support for unnamed POSIX semaphores, this wrapper
code was added. For MacOS, it uses Grand Central Dispatch semaphores,
otherwise standard POSIX unnamed semaphores are used. Currently return
codes are not checked. Eventually this code will be gone over and
turned into a generic drop-in for other projects needing to reconcile
unnamed semaphores with the Apple Way. At that point, structure and
function names will be changed and return codes will be checked.
Because this is intended for later widespread re-use, ux_sema.h is
dual-licensed GPL and MIT.
Bill Lash [Fri, 28 Jun 2019 05:29:04 +0000 (00:29 -0500)]
Check for NULL dispatch semaphore ptr on MAC
Bill Lash [Fri, 28 Jun 2019 03:35:46 +0000 (22:35 -0500)]
Fixing assert due to failure of src_process
Based on discussion with @borg323 src_process was leaving the
input data pointer at an old value if it ran out of input data and
completed the output buffer in the same call. Fixed it by setting
the input data pointer back to the beginning, but since the number
of input frames was set to 0, it wouldn't read any data from it.
Bill Lash [Thu, 27 Jun 2019 04:34:30 +0000 (23:34 -0500)]
Fix a few issues discovered on the MAC
Reduce the max wait from 1 second to 1 msec to prevent pauses
between sounds. Also check the return value of the samplerate
converter src_process() and if there was an error, tell the caller
to try calling again.
Bill Lash [Tue, 25 Jun 2019 02:31:56 +0000 (21:31 -0500)]
Make a try at MACOS unnamed semaphores
David Griffith [Mon, 24 Jun 2019 06:40:42 +0000 (06:40 +0000)]
Merge branch 'typo-fixes' into 'master'
Fix a few typos in docs/comments/strings
See merge request DavidGriffith/frotz!105
David Griffith [Mon, 24 Jun 2019 02:42:57 +0000 (19:42 -0700)]
Get rid of some leftovers from audio overhaul.
David Griffith [Mon, 24 Jun 2019 00:25:56 +0000 (00:25 +0000)]
Merge branch 'successivesounds' into 'master'
Change ux_input to periodically call os_tick()
See merge request DavidGriffith/frotz!104