Checksum Craziness

Discussion of hardware and software development for Super NES and Super Famicom.

Moderator: Moderators

Forum rules
  • For making cartridges of your Super NES games, see Reproduction.
tepples
Posts: 21748
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Checksum Craziness

Post by tepples » Fri Jan 01, 2016 11:07 am

Thanks. Do you plan on putting the source code under a free software or open source license? If you need help choosing one, the GNU project has an article about Apache, LGPL, and GPL.

Pokun
Posts: 1269
Joined: Tue May 28, 2013 5:49 am
Location: Hokkaido, Japan

Re: Checksum Craziness

Post by Pokun » Fri Jan 01, 2016 11:26 am

elseyf wrote:
Pokun wrote:Is it possible to distribute this as a standalone executable? I tried making a SNES checksum fixer in C++ a while ago that I could use as part of the tool chain when assembling (ucon64 is a bit much for this indeed), but I ran into some weird problems I couldn't figure out and put it on hold.
Here you go. I included the source, maybe its useful. I actually used ucon64 all the time before reading this post to fix the checksum of my programs and had no problems, but i guess it doesnt hurt to have my own program do it :).
I tested it with 4mbit, 32mbit and 48mbit ROMs, and had positive results. If there is a bug let me know.
Oh thanks a lot!
Did you link the library? It says I'm missing dlls when trying to start the included exe. I tried to compile it myself with static linking but Codeblocks just decied to refuse doing anything I tell it. :(

User avatar
elseyf
Posts: 70
Joined: Sat Dec 01, 2012 4:10 am

Re: Checksum Craziness

Post by elseyf » Fri Jan 01, 2016 12:39 pm

tepples wrote:Thanks. Do you plan on putting the source code under a free software or open source license? If you need help choosing one, the GNU project has an article about Apache, LGPL, and GPL.
Thanks for the suggestion. After reading the article a bit, the APACHE License seemed appropriate.
I actually never used a license before to publish some code.
Pokun wrote: Oh thanks a lot!
Did you link the library? It says I'm missing dlls when trying to start the included exe. I tried to compile it myself with static linking but Codeblocks just decied to refuse doing anything I tell it. :(
I used Code Lite to compile the code. I assumed it statically link the libraries so only the executeable would be required to work. I recompiled sns_chk, this time i explicitly stated the -static flag, so it would include the libraries statically.
Here are the switches used by Code lite to run g++ (c++ compiler):

Code: Select all

-O2 -Wall -static -static-libgcc -DNDEBUG  -o ./Release/sns_chk.cpp.o -I. -I.
Please try the updated zip and report.

Pokun
Posts: 1269
Joined: Tue May 28, 2013 5:49 am
Location: Hokkaido, Japan

Re: Checksum Craziness

Post by Pokun » Fri Jan 01, 2016 4:11 pm

Still doesn't work. "The program can't start because libgcc_s_dw2-1.dll is missing..."

Maybe try add "-static-libstdc++" in addition to the other flags.


Edit: Now it works perfectly! Thanks again!

Optiroc
Posts: 129
Joined: Thu Feb 07, 2013 1:15 am
Location: Sweden

Re: Checksum Craziness

Post by Optiroc » Sun Jan 10, 2016 2:23 pm

This thread made me put some polish to the small tool I've used for setting checksums on my own builds... I just uploaded it to GitHub: SuperFamicheck

It was a pretty interesting, however useless, detour! It should display info and optionally fix most ROMs without too many false positives (at least on even the most exotic stuff I've tested).

User avatar
nicklausw
Posts: 371
Joined: Sat Jan 03, 2015 5:58 pm
Location: ...
Contact:

Re: Checksum Craziness

Post by nicklausw » Sun Jan 10, 2016 3:32 pm

Jeez, there's so many of these programs around apparently yet I wasn't able to find any without asking...about a year ago (I've been a member for a year now!), tepples mentioned that we need to gather and organize all the SNES development tools out there because of how scattered they are, and this is making me want to attempt that.

Post Reply