323 Commits
Author SHA1 Message Date
Landon Curt Noll 77856010b9 improve 1986/stein/README.md "To run" text 2023-10-18 16:13:22 -07:00
Landon Curt Noll f9750f114a fix improper use of whitespace in README.md files
The use of the markdown trailing whitespace to indicate
line break should NOT be done when the following line is empty.

This removes such improper use of whitespace in README.md files.
2023-10-18 15:33:10 -07:00
Cody Boone Ferguson b26aaccd08 Improve how 1986/wall alt code is built
Add explicit rule to compile alt code and update CFLAGS to include (if
CC is gcc) -traditional-cpp. Clang does not support it. If CC is cc it
might support it depending on the system (macOS gcc is actually clang so
it won't but linux it will). This allows just running instead of:

    make CFLAGS+="-traditional-cpp" alt

to do:

    make CC=gcc alt

but still allowing for the former which might be necessary if CC is not
defined to be gcc.

The README.md points out that in macOS gcc is clang.

Improve the command (in the thanks file) of how to see the difference
between the -traditional-cpp version and the fixed version so that it
doesn't need git but rather just diff (as git diff is unnecessary here).
Note that there is discussion about new make rules that will make this
type of thing not needed so the thanks file would be updated at this
point for that to just refer to the FAQ (or not say anything about it at
all).
2023-10-18 07:49:39 -07:00
Cody Boone Ferguson 70cee412ac Fix 1986/pawka/Makefile
The flag -Wno-strict-prototypes was put in the CDEFINE variable,
suggesting that it might need a -D flag when it of course does not. This
is not strictly an error but it's also not strictly correct so I
strictly decided to make it correct.

At the same time I added to CSILENCE -Wno-implicit-int, a warning that
has shown up in macOS recently, very possibly with macOS Sonoma, and so
might have to be added to many Makefiles.
2023-10-17 10:24:31 -07:00
Cody Boone Ferguson b094d5cd48 Format/typo check 1986/wall/README.md 2023-10-17 10:23:31 -07:00
Cody Boone Ferguson fbb4e51310 Format/typo check 1986/stein/README.md 2023-10-17 10:13:29 -07:00
Cody Boone Ferguson 40f27797b1 Format/typo check 1986/pawka/README.md 2023-10-17 10:00:43 -07:00
Cody Boone Ferguson 9cb85e0f18 Update 1986/marshall/README.md
Reworded the explanation of the funny opposite/conflicting problems with
gcc and clang depending on if the optimiser is disabled or enabled, that
I fixed and added alt code to demonstrate it.
2023-10-17 09:55:35 -07:00
Cody Boone Ferguson 846339262f Format/typo check 1986/holloway/README.md 2023-10-17 09:54:04 -07:00
Cody Boone Ferguson aa131914ed Format/typo check 1986/hague/README.md 2023-10-17 09:53:44 -07:00
Cody Boone Ferguson a70db3f93a Format/typo check 1986/bright/README.md 2023-10-17 09:53:28 -07:00
Cody Boone Ferguson 5e3801e7cf Format/typo check 1986/august/README.md 2023-10-17 09:53:14 -07:00
Cody Boone Ferguson 38fed3b341 Typo/format check 1986/applin/README.md 2023-10-17 09:52:58 -07:00
Cody Boone Ferguson 0942f4e6b2 Mass typo fix in Makefiles
There was a comment in the form of:

    ... the liked/allowed ...

which should instead be:

    ... liked/allowed ...

and this was fixed with my sgit tool like:

    sgit -e 's,the \(liked/allowed or compile\),\1,g' '*Makefile'
2023-10-16 10:35:34 -07:00
Cody Boone Ferguson ffdf581218 Mass typo fix in Makefiles
With the make indent rule there was a typo for indent as 'intent'. This
was fixed with my sgit tool like:

    sgit -e 's/no intent\( tool found\)/no indent\1/g' '*Makefile'
2023-10-15 12:18:34 -07:00
Cody Boone Ferguson add7268842 Format fix 1980s and 1990s README.md files
I also updated the todo.md file as I left some things out that have to
be done. I only explicitly named one thing but when I go over them as a
final pass I will address the things in question (some will require
discussion).
2023-10-10 06:24:13 -07:00
Cody Boone Ferguson b99bd2f6fb Add 2>/dev/null to try in 1986/hague
Until such a time that the alt code can become the main code, to be
safer and more importantly to prevent obnoxious warnings that are shown
at runtime, the 2>/dev/null will prevent the runtime warning from
showing up; this is particularly 'necessary' for macOS as it is the one
that shows the warning and this entry is more complicated to set up
fgets() though I do have some ideas on how it might be done but 'might'
is a somewhat big if: it's probably in this case going to be tampering
too much with the entry when the benefit is not that worth it since we
can redirect the warning to /dev/null. This is TBD later.
2023-10-08 04:04:37 -07:00
Cody Boone Ferguson 81c606bab1 Restore 1986/hague to original
By accident the hague.alt.c was copied to hague.c.
2023-10-08 03:59:46 -07:00
Cody Boone Ferguson ef456bfb1e Mass typo fixes
This is a HUGE commit:

    417 files changed, 874 insertions(+), 874 deletions(-)

As the IOCCC website now is https enabled I have updated the
'http://www.ioccc' to 'https://www.ioccc'.

There was also a typo in Makefiles where it said 'for VERY WELCOME' when
it should be 'are VERY WELCOME'.

Finally slashdot.org is also https enabled so references to
'http://slashdot' were changed to 'https://slashdot'.

This was done by my sgit tool (see https://github.com/xexyl/sgit)
like:

    sgit -e 's,http://www.ioccc,https://www.ioccc,g' -e 's/for VERY WELCOME/are VERY WELCOME/g' -e  .

but because I didn't have a list of files that should be modified I had
to be careful which files to commit as I had files that were changed but
not ready to be committed. Since I did it in steps, finding typos as I
went along, I actually ran sgit three times but to simplify the above
(and to show that it's possible to do more than one sed command) I made
it all as one. Since I did not have a list of files ahead of time I had
to determine what files to commit, first going through them like:

    for j in $(for i in $(git status|grep modified|cut -d: -f2); do \
	git grep 'https://www.ioccc' "$i"; done|cut -d: -f1|sort|uniq); \
	do git diff "$j"; done|less -r

(I had to pipe through less because of a strange problem with the git
diff which appears to be because of a terminal problem maybe due to the
command above but it was all I could come up with in a very tired head.)

The above and

    git status | grep modified:

showed that some C files had been modified which obviously should not be
done so I had to do:

    git co '*c'

to undo those changes.

Finally to commit the correct files I did:

    for i in $(git status|grep modified|cut -d: -f2); do \
	git grep -E 'https://www.ioccc|https://slashdot|are VERY WELCOME' "$i"; \
	done |cut -d: -f1|sort|uniq|xargs git commit -v

or so (with any formatting issues or typos here due to typos in the log
due to the terminal (in)sanity issue described).
2023-10-07 04:35:47 -07:00
Cody Boone Ferguson c1c8197c34 Add alt code to 1986/hague - fgets()
The reason it is in alt code is because one of the forms of input (see
below) will, although print out correct output, segfault after
outputting the text. That is when one does something like:

    echo foo | ./hague.alt

Whether it might be worth making it the entry itself with a note in the
Makefile and README.md and bugs.md (because it does print out correct
output) can be determined later - or not.

This change required several files to be updated besides the new file
hague.alt.c.
2023-10-04 04:09:38 -07:00
Cody Boone Ferguson 1a907f1360 Minor clarifications in 1986/marshall/README.md
...about the strange problems that prevented this entry from working,
depending on whether the optimiser was enabled or not (different
problems) that I fixed. This was documented at the idea of Landon as it
is rather interesting and amusing.
2023-09-26 08:28:20 -07:00
Cody Boone Ferguson 6fe49bb778 Minor fixes in 1986/wall/README.md 2023-09-07 08:53:54 -07:00
Cody Boone Ferguson a8f860afba Minor format fixes in 1986/hague/README.md 2023-09-07 08:52:37 -07:00
Cody Boone Ferguson d792fbf437 Add alt code to 1986/marshall
Add the code before the fixes to the entry that prevented it from
working right depending on the compiler and optimiser (where having the
optimiser with one compiler would let it work with one and not work with
the other but having it disabled would reverse this in the same way) and
documented the ways the compilers conflicted for instructional value and
entertainment.

Updated .gitignore.
2023-07-15 09:31:02 -07:00
Cody Boone Ferguson affb0159ff Fix 1986/marshall for linux
Choo choo! :-)

There was a problem in linux where it either segfaulted or entered an
infinite loop depending on compiler / flags. This was caused by a for
loop that had an empty condition and the call to _exit().

A game of cat and mouse occurred where fixing it for one compiler caused
the program to segfault with the other compiler. Unfortunately the
formatting did have to change a bit but it still mostly looks like a
train even if not quite as pretty.
2023-07-12 11:42:15 -07:00
Cody Boone Ferguson 1d86daf19a Change LIBS to LDFLAGS in Makefiles
This is to make it more standard which further allows one to run make on
some other source code, say because they want to try and fix an entry
but forget to update the Makefile. Or if they're the author they can not
worry about it in some cases. But since LDFLAGS is the standard way it
seems better to have the LIBS variable in the Makefile be LDFLAGS.

Maybe there is a reason to not have this and I'm happy to close this in
that case but it does seem better this way so I'm doing this commit.
2023-07-10 03:33:53 -07:00
Cody Boone Ferguson b6330673cc Restore silencing warnings in macOS
As besides the entries that are not supposed to compile/cannot compile
due to architectural limitations all the entries can compile in macOS
(though some do not work - yet(? I have plans to work on more later)) it
was not necessary to not silence the warnings after all as the entries
that don't work will be easy to identify ('they don't work' :-) ) so I
can just do make CSILENCE= all in the directory of those entries which
solves the problem I had originally thought of.

Some of the Makefiles have retained other changes I had to make
yesterday to get the entries to work with clang in linux but most of
them were either not changed or were made better with the rollback of
the commit that originally silenced warnings.

Now work on silencing warnings for linux can be done.
2023-07-08 05:05:50 -07:00
Cody Boone Ferguson d89305ef3b Mass .gitignore update for .orig.c files
Due to the fact we now have .orig.c files and thus the possibility of
winner.orig or prog.orig being built I have updated all the .gitignore
files so that these files ignored. This was done with the following
shell commands, for reference:

    for i in $(find 19* 200* 201[0123] -mindepth 2 -maxdepth 2 -name .gitignore) ; do echo $(dirname "$i"|sed -e 's,[0-9]\{4\}/,,g').orig >> "$i"; done
    for i in $(find 201[4-9] 2020 -mindepth 2 -maxdepth 2 -name .gitignore) ; do echo prog.orig >> "$i"; done

and the two commands is because it was only in 2014 that the winning
entries were renamed to prog so prog.orig is the correct glob.
2023-07-08 04:39:42 -07:00
Landon Curt Noll 2aa99f0644 revert commit d8425bb767 2023-07-07 05:36:08 -07:00
Landon Curt Noll d8425bb767 silence warnings under macOS for cc, clang and gcc
Used the following script to check for warnings
not silenced via ${CSILENCE}:

```sh
find ???? -mindepth 1 -maxdepth 1 -type d | while read dir; do
(cd "$dir"; echo =-=-= "$dir" =-=-= ; csilence -v 1 clobber all ; echo ; csilence -v 1 clobber alt)
done 2>&1 | less
```
2023-07-07 01:11:22 -07:00
Landon Curt Noll 2ba12ecc3c restore *.orig.c to each entry
Under each yyyy/dir there is a file of the form '*.orig.c'
containing the original source code, or as close as we can
get to the original source code.
2023-07-06 21:49:38 -07:00
Cody Boone Ferguson a981cacbee Begin centralising thank yous to a single file
NOTE: this is just one way to fix the problem described below but it can
be modified - perhaps greatly changed - or rejected and done
differently. That being said it does isolate the entries that can be
modified except for the one by Simon Cooper as I had intended to do all
entries before a commit but I am too tired to continue and there are
more important things to be done for the IOCCC (hopefully later today).
I don't mind but I wanted to save Landon some of the work as I started
the problem even though all with good intention after Landon noted he
wanted to thank those in the README.md files.

First I would like to also apologise to any previous winners if there
was upset or concern; this was all done with the best intentions and I
know that it was a fine line but the judges' goal is to make it so
previous entries do work in modern systems so that everyone can enjoy
them. Still I am sorry if I caused any offence or anything else! I
actually agree with the situation and I had been wondering about how to
go about it too. Now for the rationale behind this update.

A couple previous winners have voiced concern about the way the thank
you notes are displayed in the README.md files I have started the work
to save Landon some of the trouble as although it was with good
intentions (and based on the note that Landon wanted to thank those who
fixed an entry) I started the problem so it seems only right that I help
rectify it. I also agree with the problem and had thought of it before,
even thinking that in some entries it needs not have any reference to
anyone but the winner! This commit has removed the thank you notes from
several entries and added a THANKS.md file.

The THANKS.md file has the rest of the entries that were fixed as well
which should if nothing else help isolate the entries that need to be
modified. Some entries actually referred to me but were not a thank you
note due to a fix; some were from winners themselves for instance.

Note that I did not update the bugs.md file or any other file that might
refer to these things in the README.md files. The bugs.md for instance
refers to adding credits to those who fix problems or provide missing
links or files to the respective README.md files and this will have to
change once the way this is done is finalised. But hopefully this is a
help to Landon so that he may also focus on the important jprint tool in
the mkiocccentry repo.
2023-06-06 04:50:41 -07:00
Cody Boone Ferguson c6de11e83e Fix 1986/marshall/Makefile about compilers
I got the entry to work with clang quite a while back but I never
removed the comment saying that the entry might have problems with some
compilers. I suppose some might still but clang is pretty strict so it
probably is okay.
2023-05-15 09:08:05 -07:00
Cody Boone Ferguson d235b565df Fix consistency of award titles
This was done quite easily with a bit of thought. I generated a script
that could be modified in vim if necessary (as it turned out to be
though some of it could have been generated too but I did not think of
everything at once and it is a hack).

This is how I generated it:

    echo '#!/bin/bash' > bin/check_awards.sh ; ( while read -r g ; do echo grep "$g"; done < <(sed -e 's,_,/,g' -e 's/"/\\"/g' tmp/year-auth-prize.csv | awk -F, '{print grep "\x22" $2 "\x22" " " $1 "/" "README.md"}' ); ) >> bin/check_awards.sh

Then I I modified the file (again this was a hack to make it easier and
quicker and better for being tired too) in vim to make the grep use -Hc
so I could pipe it to 'grep :0'. This found the files without the right
award. So the final command was:

    sh bin/check_awards.sh |grep :0

though I did have to edit some files several times.

For reference the script has been added to the repo too but with +x
permissions.

This change also required updating the CSV file in tmp/.
2023-05-13 07:02:07 -07:00
Landon Curt Noll 5927927e51 Add .id to all winning entries 2023-05-13 11:45:33 +10:00
Landon Curt Noll c69445d067 Add .top and .year files
This will be used by tools that will build the web site
and tools that form JSON files (such as `.winner.json').
2023-05-12 20:10:38 +10:00
Cody Boone Ferguson 7b3390ba11 Fix Jack Applin URL 2023-05-09 10:31:45 -07:00
Cody Boone Ferguson ecc6456bc7 Format fix 1986/README.md
I also added links and expanded the BOF to say what Usenix BOF was.
2023-04-30 06:46:27 -07:00
Cody Boone Ferguson 7591ae8a1c Update Larry Wall address and country code 2023-04-22 04:29:11 -07:00
Cody Boone Ferguson 66231b2150 Remove 'America' (A) from 'USA' :-)
This to make the country code consistent with mkiocccentry (and I guess
international standard country codes).

This affects many README.md files and (for one line) winners.csv.
2023-04-22 04:21:38 -07:00
Cody Boone Ferguson d516632563 Update address and CC of Eric Marshall 2023-04-22 04:08:59 -07:00
Cody Boone Ferguson df1310532a Update address and country code of Bruce Holloway 2023-04-22 04:07:10 -07:00
Cody Boone Ferguson 90b5be6a62 Update address(es) of Jim Hague
Remove address (or the part of it - at university), add country to
winners.csv and update email in winners.csv (the latter according to
winners.html).
2023-04-22 04:04:33 -07:00
Cody Boone Ferguson 929cb7cd72 Remove address from 1986/applin/README.md
For similar reasons as commit 55575a126e:
it doesn't seem useful now and it's very likely out of date. As well the
json files won't have addresses and it's been years since the contest
has asked for the addresses of winners.
2023-04-22 03:59:45 -07:00
Cody Boone Ferguson 55575a126e Fix Lennart Augustsson URL, remove address
This will likely be the first of a series of commits where URLs are
checked (until I get tired of doing this of course) and more importantly
addresses are removed as these seem unneeded now and the odds are they
are no longer valid.
2023-04-22 03:51:10 -07:00
Cody Boone Ferguson 951f3cc2e2 Update 1986 winning entries' README.md files
Format and typo fixes.
2023-04-14 06:17:26 -07:00
Cody Boone Ferguson d8e876794e Format and URL fixes in 198[568]/applin/README.md
Format fixes.

Dead link discovered. Use Internet Wayback Machine instead.
2023-04-14 06:03:57 -07:00
Cody Boone Ferguson 4bf3f302cb 'comments' -> 'remarks' in all README.md files
As in

    sgit -e 's/\([Aa]uthor.*\)comments/\1remarks/g' -e 's/\([Jj]udge.*\)comments/\1remarks/g' '*README.md'
2023-04-10 11:01:39 -07:00
Cody Boone Ferguson c1a953b4c5 Add note about 1986/wall.alt.c
It was added so one can see just how different the C language was at the
time. Well see without having to look at the archive.
2023-04-07 10:53:48 -07:00
Cody Boone Ferguson 025c7a1e1e Add to 1986/wall/README.md
Just noted what the previous fix (for gcc) did.
2023-04-04 12:45:15 -07:00