This was also a lot of fun to fix. It took a fair bit of tinkering but
it was a lot of fun to figure out and now it works like it does with
-traditional-cpp!
Removed this entry from the bugs.md file as it now works.
Also added to the bugs.md a minor clarification about another entry
that is in status INABIAF (about warnings).
Add -include stdio.h -include unistd.h for gets(3) (I do intend to
change it to use fgets(3) but this will probably not happen for a while)
and write(2).
There were many many README.md files with the wrong heading level for
different sections. These have been changed.
To help go through the changes it should be noted I used sgit and also
here is what is changed:
The 'Try', 'To build' and 'To run' lines have two '#'s. Some had one and
others had three.
An exception is that in 1984/anonymous/README.md for the alternative
code that had three '#'s. This is not consistent yet and it might be
that only two are desired. But for now that one at least has three.
For Makefiles that have alt related rules, moved
the related rules under the alt rule section.
In some cases where there is no alt code,
removed alt rules and/or targets.
Changed the position of the everything Makefile rule
in select Makefiles to be consistent with other makefiles.
Fixed Makefile for 1986/stein where everything was not
everything (did not depend on alt).
Simply the Makefile header.
Refer to the //www.ioccc.org/bugs.md URL (that will eventually exist).
Now using CC BY-SA 4.0 License to how you may share and adapt the
Makefile.
In some files changed the formatting was fixed to be a proper markdown
file.
There were some typos including that some README.md files that linked to
/winners.html#Cody_Boone_Ferguson actually linked to the non-existent
file /years which obviously would not work.
I also added links to the rest of the places I have fixed entries (but
see below) and I did the same for Yusuke Endoh's fixes.
As well apparently one entry I thought he fixed to compile under modern
systems does not seem to so that entry will have to be revisited another
time. That entry was 1993/jonth.
Those are the main changes here if not all of them.
Some of the files modified include some of the files modified yesterday;
others were not modified yesterday. I backtracked as I noticed some
sections are missing in earlier README.md files. However more have to be
checked in earlier years. I'm committing now as I have to do other
things and am likely done for the day.
As I described in the README.md the problem was that clang is more
strict about the second (also third but this is not used) arg type being
char **. However changing its type to char ** and updating *s to be **s
resulted in a core dump (segfault); and not doing that caused other
problems. The fix was to do a char *t = s; and then update in the code
the references to s to be t (including passing it to main()). This makes
it compile and run successfully with both clang and gcc.
The years 1984, 1985 and 1986 have had all winning entry README.md files
updated. This includes formatting, adding author's comments (which in
these years means nothing but still have the section there to indicate
that there were no comments) and possibly other things.
I have updated some - not all - of the 1987 winning entry README.md
files. I have to do other things now but I want these committed. I will
work on the other README.md files another time.
Although under linux it compiled (as long as the compiler supports
-traditional-cpp) it did not function correctly. We used a patch from
Yusuke Endoh. Thank you Yusuke!
Choo choo!
This did not take much that work but it required some casts because the
third arg to main() was an int and now it's a char **. I tried to keep
the layout as close to the original. The line lengths are the same as
the original but some spaces are now non-spaces. I noted this in the
README.md.
As well in the README.md I have added an author's comments section.
Still working on other README.md files for this. However I might try and
get some entries to compile that previously did not. There was another
entry in 1986 that this was not so simple to do so I moved on. Maybe I
will revisit that another time (1986/holloway).
This is a subtle thing that I brought up on GitHub. Landon made the
change in many files but missed some in 1986 through 1989. I am aware of
a mass typo in the Makefiles but since some Makefiles are pending
changes I'm not doing that yet.
1986/wall will not compile under the default gcc (as it's actually
clang) with macOS as it requires -traditional-cpp which unfortunately
clang does not support.
Also fixed many of the README.md files.
Removed 1986/bright/bright.orig.c (probably because it won't compile on
modern systems but maybe not; I did that change a while back but didn't
finish working on 1986 until just now).
Yes this is on the guidelines branch but I forgot about the html files
(briefly) when on that branch and I don't want to go back to the other
branch and then checkout another branch that does not have these
changes. Maybe they should have both been on the same branch but I want
to avoid problems with conflicts (even though these should be fine).