Start a developer manual for the project where we will keep policies,
guides and processes for the project in DEVELOPER-MANUAL.md.
Describe the policies for receiving and resolving github issues.
Describe the policy for git commit messages on pull requests and add git
notes for collaborating on a branch.
Describe the policy for commits from maintainers.
Describe how to set up a native windows powershell development
environment and some powershell tips.
Describe the requirements and steps for the current release process.
Replace the CONTRIBUTING section of the README.md with a link to this
manual.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Extract strings from all wx sources, not just the enabled ones.
Ignore comments in the generated pot when checking if it was updated, we
don't care about just changes in line numbers.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
gcc (mingw) does not allow converting a const char*[] to a char**
without -fpermissive. Make some adjustments to the string handling to
execute the cmd.exe command to delete the temp file.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Trying to delete the temp file for the winsparkle dll after unloading
the dll would still produce an access denied error, presumably because
for whatever reason not all resources used by the dll were freed.
Instead of trying to immediately delete the file, start an asynchronous
cmd.exe process to sleep for 2 seconds and delete the file. This gives
the app time to exit, after which the file can be deleted.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
When the feature was added in d93f6350, I did not adequately test for
the normal case when the pot is not updated.
This does not work because the pot has a timestamp in the
POT-Creation-Date: field.
Fix check-pot-update.cmake to ignore the pot timestamp and not report
the pot as changed when it has not been.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Remove po/update_pot.sh and generate the gettext .pot source
automatically in cmake on every build instead.
If the .pot is actually updated, print a loud message at the end of the
build to commit the result and push to transifex.
Fix the gettext tools and package loading block to only run when
ENABLE_NLS is enabled and find the xgettext and msginit binaries in the
Windows case as well. xgettext is used to generate the .pot.
Refactor the SRC_WX/HDR_WX/RES_WX/XRC_SOURCES handling to use only
relative paths and move all generated files into RES_WX. This was
necessary to generate the .pot from cmake.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Fix issues with {sav,load}ing e-Reader `Dot Code`.
If `Dot Code` file is not specified, it tries to continually read it and does not accept input.
In Japanese (very likely other languages as well), the path of `Dot Code` file is garbled
internally due to failing conversion to UTF-8.
Check for UPDATE_APPCAST being set before checking for TAG_RELEASE, as
the UPDATE_APPCAST script may be run in the same build directory where
TAG_RELEASE was just run.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Add the -DUPDATE_APPCAST=TRUE option to invoke the UpdateAppcast.cmake
script, which clones the github pages repo and sets the version in the
appcast.xml to the last tag, presumably made with -DTAG_RELEASE.
The script prints out a final set of instructions to actually push the
change to git.
If the option -DUPDATE_APPCAST=UNDO is used, the clone is removed and no
changes are made.
Also use the correct method of splitting the tag list output into
multiple lines.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Remove snap build status since we are not using that anymore.
Use the png instead of the svg for the snap store badge as it's not as
large.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Default to ON on Windows for x64 or x86.
Set new appcast URL, this will be in the github pages repo.
We will need to get everything ready for the next release.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
vcpkg upgrade is currently broken, see:
https://github.com/microsoft/vcpkg/issues/9916
Use remove followed by install, which does practically the same thing,
as a workaround.
Hopefully fix current appveyor build failures.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Default the linkTimeout ConfigManager variable to 500 (milliseconds.)
Detect if the previous default is set, which 1, and set to 500, to
repair existing configurations.
This may reduce the amount of reports about link being broken, as some
people have certainly not checked this setting, and the default should
not be so wrong.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Add field for the network port to the start link dialog, default is 5738
as before.
The port is stored in the user's options config.
Add TextCtrl support to UIntValidator for this.
Related: #594.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
This doesn't work to pick up changes from changed translations files
though, because git does not store file timestamps.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
We need to use proper documented behaviour when coding the
core, therefore this should be reverted until a proper
solution is done.
This reverts commit ca3b63d64c.
For some versions of the mxe ubuntu repositories, the compiler/ccache
packages have a bug where the compiler a broken symlink to ccache.
Make sure the expected symlink to ccache exists.
Add pre-build instructions to add /usr/lib/mxe/usr/bin to the PATH.
Amend the PATH for the mxe travis jobs as well.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
The current code is very messy as far as GFX goes. There are more
elegant ways of tackling this issue, but they are very difficult with
our current code.
The idea behind this issue is that the backgrounds are not switching
properly for the lcd. So we enable the layers accordingly to
`layerSettings & DISPCNT` on every `CPUUpdateRenderBuffers`.
The bits of `layerSettings` enconde each layer and objs.
We actually only need 2 of these, but I can't do much more here
unsupervised.
- Fix#376.
Search the lib-prefixed names of intl/iconv/charset libraries first to
avoid dlls being linked.
Update toolchain files to include the common source by full path, fixes
using them as toolchains for other projects broken in 3edd9ba7.
Update URL for nasm, use newer jpeg-turbo, tiff and wx.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Use the 3.x wxwidgets mingw package in installdeps.
Add the win64 alias to installdeps for 64 bit mingw builds, like the
win32 alias for 32 bit mingw builds.
Check CROSS_ARCH in Architecture.cmake, set by our mingw toolchains.
Disable LTO by default for all mingw builds, not just amd64, because it
is unfortunately broken on i686 as well now.
Search for heuristically the most appropriate wx-config and set
wxWidgets_CONFIG_EXECUTABLE accordingly in the mingw toolchains.
Refactor the mingw toolchains somewhat, put common code into a common
file, add static toolchains.
For static toolchains, also search for a static zlib and set ZLIB_ROOT.
Change installdeps instructions to use ninja instead of make. Add ninja
to all target dependencies where it was missing, this may be incorrect
in a couple of the rarely used targets, if this is the case the affected
users are free to open an issue.
Also start using ninja on travis instead of make, except for libretro
which uses a GNU Makefile.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Add macro fi_check_done() to set fi_done if leftover contents is empty,
use it in both fi_open_file() and fi_get_next_line().
This fixes the behavior when the opened file is empty and makes the code
cleaner.
Add a usage example to top comment.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Remove LDFLAGS from list of required variables for finding ffmpeg to
succeed. Both main and component LDFLAGS.
Added by f7f424ea.
This is necessary because of platforms lacking pkg-config, like vcpkg +
Visual Studio, no LDFLAGS are found.
Fixes finding ffmpeg in the vcpkg + Visual Studio configuration.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
This is a followup on 93f906e2.
Simplify the FileIterator interface by doing the eof check in
fi_get_next_line().
Add rollback instructions to final instructions message.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Add a TAG_RELEASE cmake variable which engages a cmake script to
generate a signed release commit with changelog entries from git and
signed tag.
The value can be ON/TRUE/1 or a specific next version number, or UNDO to
rollback changes just made with this script.
The script tries to make sure all the preliminaries are in the right
state to do a release, the source is a git clone, on branch master, with
a clean working tree and gpg is available.
Also add a utility script FileIterator.cmake which is an OO-like line
iterator interface for text files, used by the release commit script.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Wrap the main body of code in Set-Toolchain-vcpkg.cmake in the
vcpkg_set_toolchain() function to not pollute the global variable
namespace with helper variables.
VCPKG_ROOT and toolchain variables are set in the cache.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
In order to not overrun the appveyor time limit of one hour, limit vcpkg
port upgrades to only the first port. This way the cache will be rebuilt
gradually instead of all at once, and the job won't fail due to
overrunning the time limit.
Also do a bit of refactoring and code improvements for
Set-Toolchain-vcpkg.cmake.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Although a length check is being performed on the imported GSA Codes file, `len` is both a signed int and attacker controlled.
With a specially crafted GSA Codes file, an attacker could specify a value for `len` that overflows the `int` type, rolling over into a negative number. By doing so, the attacker can bypass the conditional mentioned above.
The `fseek` length parameter is of type `size_t` which is an unsigned int, this will result in `len` being interpreted as a large unsigned int, allowing for a stack based buffed overflow in the desc char array.
By making `len` an unsigned integer, it will prevent the overflow. It ensures that the bounds check works as intended.
For Visual Studio, the static builds now require linking libcharset
explicitly, otherwise an `unresolved external symbol locale_charset`
error is thrown during linking.
This library is sometimes required on other platforms for iconv/gettext,
and checking for it and linking it should be harmless.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
BPS support and fix bug when patching rom.
Add support for BPS patch format (by @ArtiiP ).
Fix crash when patched rom new size is larger than original rom. This was bugged due
to the rom block in memory being less than required after the `realloc` of the patch.
- Fix#549.