• Hello MLAers! We've re-enabled auto-approval for accounts. If you are still waiting on account approval, please check this thread for more information.

Working Version of MacHttp2 MCP files?

K55

6502
Hi all, getting back into classic mac development after a few years of grinding it out professionally (cant feed myself with dead scsi drives sadly).
Looking to add some file support to the ol' macHttp2 server but I cant for the life of me get the source extracted in a way that preserves the binary nature of the .mcp file.
Assuming this is because it was zipped and not stuffed so the resource fork is borked :(.
I'll try and reach out to Chuck to see if he has the source somewhere else but if anyone has it lying around im all ears.
Otherwise I'll just probably end up making the project file from scratch.
1749398570821.png
Linkerino
 
If the zip file was created on a Mac then it would have preserved the resource forks and HFS metadata.

The zip file appears to contain AppleSingle encoded files. They can be converted to proper resource files:

Code:
sourcedir="/Volumes/Storage/Downloads/machttp"
extracts="/Volumes/Storage/Downloads/machttpextracts"
mkdir -p "$extracts"

IFS=$'\n'
for thefile in $(find "$sourcedir" -type f -not -name '.DS_Store'); do
	if applesingle probe "$thefile" 2> /dev/null ; then
		printf "Extracting AppleSingle \"$thefile\"\n"
		applesingle decode "$thefile" -o "$extracts/$(basename "$thefile")"
		mv -f "$extracts/$(basename "$thefile")" "$(dirname "$thefile")"/
	fi
done

Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/Licensing Info"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/MacHTTP Software and Docs/MacHTTP Settings"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/MacHTTP Software and Docs/MacHTTP.config"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/MacHTTP Software and Docs/Tutorials/Examples/HyperCard CGI demo/CGI Demo Stack"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/MacHTTP Software and Docs/Tutorials/Examples/map.cgi"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/MacHTTP Software and Docs/Tutorials/Examples/map.script"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/MacHTTP Software and Docs/Tutorials/Examples/newtest.acgi"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/MacHTTP Software and Docs/Tutorials/Examples/test.cgi"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/MacHTTP Software and Docs/Tutorials/Examples/test.script"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/MacHTTP Software and Docs/Tutorials/Extending MacHTTP Scripts/README"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/MacHTTP Software and Docs/Tutorials/Extending MacHTTP Scripts/Script1.cgi"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/Ordering Info"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/Quick Start Guide"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/distribution/README"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/MacHTTP.config"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/MacHTTP.mcp"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/source/resource/PW_UI.rsrc"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/machttp_server/source/resource/Template.rsrc"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/plugins/x10tools_i/X10Tools_release/MacHTTP.config"
Extracting AppleSingle "/Volumes/Storage/Downloads/machttp/other/machttp/plugins/x10tools_i/X10Tools_release/Read Me First!"

For source files (.c, .h, etc.), you'll want to set the file type to TEXT and creator to CWIE using the SetFile command.

You should use UNIX linefeeds which is preferable for GitHub source control.

CodeWarrior requires MacRoman encoding but GitHub prefers UTF-8 encoding, so you should make sure your text files are limited to ASCII which is common to both MacRoman and UTF-8. Grep for [^ -~\n\t\r]
 
Thanks!
I followed though with this and everything worked well until I had to transfer the files from my mac osx machine to my g4.
However they show up as generic files still.
This may have been made on a windows pc but who knows, if you get a chance can you bundle the files into a .sit and send them over?
 
What version of Mac OS X was the OS X machine? I think it needs to be Leopard or earlier to be able to serve files to Mac OS 9. I think connecting with AFP should work.
 
Back
Top