47 Commits
Author SHA1 Message Date
Cody Boone Ferguson 8eca5d216d Correct comment in Makefiles for CUNKNOWN
It is actually used to silence the unknown warning option, not unknown
warnings.
2024-09-25 09:32:00 -07:00
Landon Curt Noll 96e0f2b966 move some rules into 1337.mk
A number of rules have been moved from entry `Makefile`s into the
`1337.mk` include file to make it easier for these common rules to be
updated or modified globally (by modifying the `1337.mk` include file).

The entry level `Makefile`s are now similar in form to the
/Makefile.example](https://github.com/ioccc-src/mkiocccentry/blob/master/Makefile.example)
file from the other repo.

The following make rules were moved into the `1337.mk` include file:

- `make indent.c`
- `make install`
- `make diff_orig_prog`
- `make diff_prog_orig`
- `make diff_alt_prog`
- `make diff_prog_alt`

This simplifies the entry level `Makefile`s so that they mostly reflect
the specifics of the particular entry.

Mentioned in FAQ 4.2, that the make diff rules are in the `1337.mk` include file.

Fixed invalid TAB character in `faq.md`.

Removed `make clean` directives that removed `indent.c`.  This file is now
removed via `make indent_clean`, a clean rule that also removes `indent.c`.

Removed `make clobber` directives that removed sandwich,  This file is now
removed via `make indent_clobber`, a clean rule that also removes `sandwich`.

Added `make indent_clean` and `make indent_clobber` rules into the top level
`Makefile` and the year level `YYYY/Makefile`.

Performed `make quick_www` to accomplish the above and to test under macOS.
2024-08-21 23:42:28 -07:00
Landon Curt Noll dbf6921b3a use include 1337.mk to hold 1337 hacker rulz
Updated 1337 hacker rulz to version 7.

Added `1337.mk` to contain the updated 1337 hacker rulz (v7).

We use an optional include of `1337.mk` (or `../1337.mk`,
or `../../1337.mk`) to include the 1337 hacker rulz.

Changed `make deep_magic` to `make more_magic`.

Changed `bin/tar-entry.sh` VERSION from "1.3.7 2024-07-22"
to "1.3.8 2024-07-23".

Changed `bin/tar-year.sh` VERSION from "1.2.5 2024-07-22"
to "1.2.6 2024-07-23".

Add `make new_entry` to `YYYY/Makefile` and `template/Makefile.year`.

Change `make new_year` to use `sort -n -u`.

Made minor debug message fixes to `bin/new-year.sh`.

Changed `bin/new-year.sh` VERSION from "1.3 2024-07-23"
to "1.3.1 2024-07-23".

Improved `bin/add-dir.sh` to update `YYYY/Makefile` with
the new entry directory name.

Changed `bin/add-dir.sh` VERSION from "1.0 2024-07-21"
to "1.1 2024-07-23".

Performed `make www` to accomplish the above and to test under macOS.
2024-07-23 22:45:16 -07:00
Landon Curt Noll 50a2a6293c add CUNKNOWN make variables to entry Makefiles 2024-06-30 21:29:27 -07:00
Landon Curt Noll e9808ca45d silence compiler warnings for macOS
After silencing compiler warnings for RHEL 9 Linux,
we silence the result on macOS for
Apple clang version 15.0.0 (clang-1500.3.9.4).
2024-03-13 00:38:46 -07:00
Landon Curt Noll 61172e5f88 silence compiler warnings for RHEL 9 Linux
We updated ${CSILENCE} Makefile variables for entries in an attempt to
minimize compiler warnings.  This was tested using
gcc version 11.4.1 20230605 (Red Hat 11.4.1-2) (GCC).

TODO: Recheck macOS clang to see if any new warnings have occur
      under macOS clang.
2024-03-12 23:35:24 -07:00
Landon Curt Noll a86786130f silence most warnings under macOS
For macOS Apple clang version 15.0.0 (clang-1500.3.9.4)
compiler, we have silenced the warnings that can be silenced.

We also updated `.gitignore` for `2014/maffiodo2` and `1995/vanschnitz`.
2024-03-11 10:42:32 -07:00
Landon Curt Noll 2b92c89be8 fix and improve links within the web site
Entry source is now prog.c for IOCCC years 2014 thru 2020,
or is now dirname.c IOCCC years 1984 thru 2013.

To achieve this state, we renamed the following:

renamed:    2004/hibachi/src/hibachi.c -> 2004/hibachi/hibachi.c
renamed:    2012/omoikane/nyaruko.alt.c -> 2012/omoikane/omoikane.alt.c
renamed:    2012/omoikane/nyaruko.alt2.c -> 2012/omoikane/omoikane.alt2.c
renamed:    2012/omoikane/nyaruko.c -> 2012/omoikane/omoikane.c
renamed:    2012/omoikane/nyaruko.orig.c -> 2012/omoikane/omoikane.orig.c

Modified `bin/subst.entry-index.sh` to add to entry `index.html` file,
links to the `Makefile` and the _C code_ to the top navigation bar.
Changed `bin/subst.entry-index.sh` VERSION from "1.2.2 2024-02-25"
to "1.3 2024-03-02".

Moved printing the Inventory link in the top navigation bar
from `bin/subst.entry-navbar.awk` to `bin/subst.entry-index.sh`.
Changed `bin/subst.entry-navbar.awk` VERSION from "1.0.1 2024-02-23"
to "1.1 2024-03-02".

Moved printing the Inventory link in the top navigation bar
from `bin/subst.year-navbar.awk` to `bin/subst.year-index.sh`.
Changed `bin/subst.year-index.sh` VERSION from "1.0 2024-02-11"
to "1.1 2024-03-02".
Changed `bin/subst.year-navbar.awk` VERSION from "1.0 2024-02-11"
to "1.1 2024-03-02".

Added location names (both default and common) to `author.html`.
Changed `tmp/gen_author_json.sh` VERSION from "1.0 2023-06-06"
to "1.1 2024-03-04".

Added location names (both default and common) to `author.html`.
Changed `bin/gen-authors.sh` VERSION from "1.2 2024-03-09"
to "1.3 2024-03-04".

The manifest and the resulting `.entry.json` files have been changed
for `2004/hibachi` and `2012/omoikane`.

The Makefiles for  `2004/hibachi` and `2012/omoikane` copy the
source file into the "previously used location".  The `make clobber`
rule removes the copied source.  The `.gitignore` files have been
updated accordingly.

Improved how the concept of IOCCC terms _entry_, _author_ and _submission_ are
used in markdown files.

Links to markdown files (files ending in .md) within the repo were
changed to link to HTML files (files ending in .html).  Special cases
where `README.md` became `index.html` were modified accordingly.

Fixed URL for `bugs.html` in Makefile comments.

Fixed name of `bin/sgi.sh` referenced in comments in `.gitignore` files.

Links to locations within the repo are now relative.  For example a
link to `/contact.html` may become `../contact.html' or '../../contact.html`
depending on the directory level of the markdown file.

Nearly all links with absolute URLs under _https://www.ioccc.org_
or `https://ioccc-src.github.io/temp-test-ioccc_ have been changed to
relative paths within the repo.  Some exceptions to this (such as
referring to a GitHub repo) were preserved.

Fixed a number of inside `faq.md` and `bugs.md`.

Added HTML name tags (in the form of an _entry_id_) for each entry
referenced in `bugs.md`.  Fixed links from outside of `bugs.html`
into `bugs.html` accordingly.

Where FAQ entries are referenced, a named tag is used so that if a
FAQ is ever renumbered, links outside of `faq.html` will still work.

Changed the _inventory_order_ of a compressed tarball from _300_
to _100000_.  While this may have been done for the manifest,
this changed had not yet been propagated into the `.entry.json` files.

Links to web sites that were in the for <URL> are now [URL](URL).

Performed `name www` to process all of the above.

Improved format of `authors.html`.  Full names are now bold.
Location codes are now links back into `location.html` and
location names (both default and common) are now italics.
Added _author_handle_ each author.

Changed `bin/gen-authors.sh` VERSION from "1.1 2024-02-25"
to "1.2 2024-03-09".

Improved format of `location.html` as location codes are now bold,
author counts in a given location are now bold, and location names
(both default and common) are now italics.

Changed `bin/gen-location.sh` VERSION from "1.0.1 2024-02-23"
to "1.1 2024-03-04".

Added italic location name after location code in entry
`index.html` files.

Changed `bin/output-index-author.sh` VERSION from "1.4.1 2024-02-23"
to "1.5 2024-03-04".

Added _Location of authors_ to the sidebar as a link to `location.html`.

TODO: While nearly all of the above mentioned changes are likely correct,
      they likely introduced a few errors that need correcting.
2024-03-04 23:45:28 -08:00
Cody Boone Ferguson 205fa25ced Change references of many terms to new names
This is a HUGE commit and this task is not done. There are still some
changes that might need to be discussed and since so much is done here I
think it's better to let this go through and then make sure everything
is okay. When the remaining references are discussed they can also be
changed.

I did NOT include changes in the tmp/OLD_manifest directory.

Some of the changes in this commit (it might be exhaustive but it might
not be - not sure):

- In the Makefiles the WINNERS was renamed AUTHORS.
- References to winners.html were changed to authors.html.
- The FAQ named anchor 'fix_a_winner' was renamed 'fix_an_entry'.
- The JSON fields (or whatever they're called) 'winner_id' and
'winner_JSON_format_version' were changed so that 'winner' is 'entry'.
- In scripts for entries 'IOCCC winner' was changed to 'IOCCC entry'.
- 'winners_text' is now 'entries_text'. It might be better to be
'entry_text' as it's per entry but this was not noticed at first. Since
this is easy to fix I am holding off on this for the meantime.
- The script tmp/update-manifest.sh now has the commit log messages
changed to the correct terms as well.

The index.html files were updated as well with any of the above
changes.

There are some references that should NOT be updated. Two examples
caught (and maybe more have slipped through that will have to be changed
back): in 1984/anonymous/README.md the author wrote back to Landon after
being told about the famous tattoo and they used the words:

    .. my entry will be the first IOCCC winner ..

but since this comes from the author it should remain so.

The other one is that winners.html should still refer to winners.html as
it informs people that it's been moved to authors.html (it does redirect
too but even so if it was changed it would defeat the purpose of the
message).

With paths like authors.html I tried to copy paste so that hopefully
there are no typos. It is possible that I did not end up doing this with
all but these can be fixed when discovered.
2024-02-13 07:31:36 -08:00
Cody Boone Ferguson 801f3fe90c Add missing comment in all Makefiles
The comment for the rule diff_alt_orig was missing. It was added like:

    sgit -e '/diff_alt_orig:/i \
    # diff alt and orig' '*Makefile'
2023-12-26 09:00:03 -08:00
Cody Boone Ferguson d1d7faecfc Add 2018/bellard alt code + format/typo checks
The alt code should work for Windows, based on the author's remarks.

Format and typo check README.md file.

I believe this completes this entry's review.
2023-12-11 12:34:51 -08:00
Landon Curt Noll 1e1f962c30 add to make clobber, removal of *.dSYM 2023-12-05 02:22:49 -08:00
Cody Boone Ferguson 30c59761df Mass fix Makefiles: $(MAKE) -> ${MAKE} 2023-11-19 06:31:28 -08:00
Cody Boone Ferguson bc35c37748 Improve how gcc/clang is detected in Makefiles
Rather than check if $(CC) IS gcc or IS clang check for $(CC) containing
gcc or clang. This is because in some systems or conditions the compiler
might not be called JUST gcc or JUST clang. For instance gcc in MacPorts
is called gcc-mp-13 (for example) but without this change one would have
to symlink gcc to gcc-mp-13 or copy it to gcc.

The FAQ has been updated to address this.
2023-11-18 06:10:02 -08:00
Cody Boone Ferguson 5041a0d592 Typo fix in all entry Makefiles
Change the comment

    # Special flags for this entry

to

    # Special Makefile variables for this entry

because these are actually variables and not flags.
2023-11-01 03:36:29 -07:00
Landon Curt Noll 00c9d60266 improve diff files
We now have 6 diff rules:

    diff_orig_prog
    diff_prog_orig
    diff_alt_prog
    diff_prog_alt
    diff_orig_alt
    diff_alt_orig

The FAQ for these diffs needs to be updated
as we have 6 types of diffs now.
2023-10-23 10:18:20 -07:00
Landon Curt Noll 71f1463547 Rename diff Makefile commands
Renamed these Makefile rules:

    orig_prog_diff ==> diff_orig_prog
    alt_prog_diff ==> diff_alt_prog

Updated thanks-for-fixes.md and faq.md accordingly.
2023-10-22 17:26:22 -07:00
Landon Curt Noll 8471e805ed add orig_prog_diff and alt_prog_diff rules to Makefiles 2023-10-18 17:00:02 -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 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 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
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
Cody Boone Ferguson 8e1112bea0 Add -lm to 2018/bellard/Makefile
Not all systems implicitly link in libm so this is necessary for those
systems.
2023-07-06 10:41:29 -07:00
Cody Boone Ferguson e09f677b37 Mass typo fix (all README.md and Makefiles)
As in

    sgit -e 's/the terms this license/the terms of this license/g' '*/Makefile' '*/README.md'
2023-04-02 09:27:13 -07:00
Landon Curt Noll 350da723cc improve architecture and Optimization comments in Makefiles 2023-03-26 22:13:13 -07:00
Landon Curt Noll 1ce40b273d fix alt rules in Makefiles
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.
2023-03-26 21:48:48 -07:00
Landon Curt Noll 1c35dc3b47 make everything true :-)
Add @${TRUE} as an action for the everything rule in Makefiles.
2023-03-26 20:47:04 -07:00
Landon Curt Noll e42d7484cd trim comments and update 133t hacker rulz in Makefiles 2023-03-26 20:24:16 -07:00
Landon Curt Noll ea1806abdb change Makefiles to look under X11_INCDIR and X11_INCDIR/X11 2023-03-26 02:22:49 -07:00
Landon Curt Noll 5fc2d72dd1 change use of ${HOMEBREW_PREFIX} with ${SDL2_CONFIG} 2023-03-26 02:19:18 -07:00
Landon Curt Noll 8cd2aa85c1 clean up and improve end of Makefile rules 2023-03-26 02:02:31 -07:00
Landon Curt Noll d04e6d8f03 remove X11_LIBDIR and X11_INCDIR setting from Makefiles
The X11_LIBDIR and X11_INCDIR values are now set in the
top level `var.mk` file.
2023-03-26 00:50:47 -07:00
Landon Curt Noll bbd18a20df improve Makefile headers
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.
2023-03-25 23:51:14 -07:00
Landon Curt Noll bf3863a29c fix Makefile header for 2018/bellard 2023-03-25 21:50:40 -07:00
Landon Curt Noll 2f89f5769b fix .gitignore, Makefile and README.md for 2018/bellard
Add Lenna.png from Wikipedia.
2023-03-24 22:06:53 -07:00
Landon Curt Noll 3947de42cd changed recently updated Makefiles to use -std=gnu17 2023-03-07 18:38:02 -08:00
Landon Curt Noll a50a997e30 remove orig code from 2018/bellard 2023-03-07 17:58:10 -08:00
Landon Curt Noll f615bba21e undo intermediate Makefile changes of 1996 to 2020
The commit 00ae59cd47 had a
mistake that introduces changes to Makefiles for 1996 thru 2020
that should not have been included.

This change reverses these intermediate changes until
the given year's Makefiles are ready.
2023-02-26 23:31:00 -08:00
Landon Curt Noll 00ae59cd47 fix 1995 Makefile comment line 2023-02-26 21:52:15 -08:00
Landon Curt Noll ab9b77b1c9 reverse bad commit 223b1a3f94
The commit 223b1a3f94 was a mistake,
so we reverse both commit 5f7cf0b60d
and commit 223b1a3f94 for now.
2023-02-26 17:21:30 -08:00
Landon Curt Noll 223b1a3f94 update 1992 Makefile variable set 2023-02-26 17:05:50 -08:00
Landon Curt Noll d947bb024f fixed issue of make pluto echo 2023-02-12 22:26:59 -08:00
Landon Curt Noll bfa2a886c5 change SHELL value
Use:

```make
SHELL= bash
```

Do not specify a SHELL path.
2023-02-12 21:59:59 -08:00
Landon Curt Noll c0663537cb Add preview of 1984-2019
The 2020 winners are hinted it, but the source code is not there,
nor are the hints. Someone could look into the HTML and
see what was commented out, but that is not a problem because
WHO won is known and the name of their AWARD is known already.
Moreover a number of the winners have talked about what their
entirs do, so the commented out spoiler text is not a bit problem.

One will find HTML commented out with:

    <!-- XXX remove when 2020 is ready
    2020 links here
    XXX remove when 2020 is ready -->

The "XXX remove when 2020 is ready" string is found at the
start and end comment blocks.  Again, soneone could read
what was commented out, but that is OK since most of that
information is known or can be known.  The following files
have such HTML comment blocks in them.

    ./winners.html
    ./years-spoiler.html
    ./years.html

In addition, ./all/summary.txt was modified to not
include the 2020 entries for the momemt.

The 2020 winner code AND write-ups are NOT part of this set.

p.s. The all/all.tar.bz2 does not contain the 2020 source code (yet?).
2020-12-30 16:57:03 -08:00