* Enable ffmpeg by default only on linux and msys2, it will be disabled
for normal windows builds and on mac.
* Set SFML_STATIC_LIBRARIES only for normal non-msys2 windows builds,
because msys2 does not currently have static versions of the SFML
sub-libraries, e.g. system, network, etc.. Dynamic linking works fine
for now.
* Fix quoting for -DLOCALEDIR, on windows spaces were causing errors in
make on msys2.
* Update to upstream FindSFML.cmake .
* Add an ./installdeps-msys2 script to install all necessary tools and
libraries on msys2 for building both 64 and 32 bit windows Wx binaries.
* Add the dependencies/mingw-xaudio/include directory to
INCLUDE_DIRECTORIES so that XAudio compiles on msys2, as mingw-w64 does
not currently have XAudio headers. Also check that the user pulled the
git submodule in the process (the ./installdeps-msys2 script does this
for you.)
TODO:
* Generalize ./installdeps to work on more platforms.
* Make console Wx app in debug mode so that debug prints will work.
* Fix game keyboard input for msys2 builds.
* Add HiDPI support for Windows.
* Fix the -D*DIR defines to have the correct paths on windows.
Add GetRealPixelClientSize() method to HiDPIAware and implement using
wx GetClientSize() in panel.cpp for the generic version, and using
convertSizeToBacking: in macsupport.mm .
Add an AdjustViewport() method to GLDrawingPanel that sets glViewport()
using GetRealPixelClientSize(), and call it for the SIZE event. Debug
print the viewport size here instead of in DrawingPanelInit().
Build improvements:
* default to Cairo off for all platforms, currently libcairo2-dev does
not install on Ubuntu
* default to ON for ENABLE_LINK and ENABLE_FFMPEG (for game recording),
this will allow for more fully-featured default builds
* do not set SFML_STATIC_LIBRARIES on Mac because this is currently
broken
* fix the Mac bundling/linking script to deal with links in dependent
libs that already use @rpath (very minor change.)
Move Objective-C++ Mac code for Wx into macsupport.mm with stub methods
in panel.cpp, and stop compiling all C++ as Objective-C++.
cmake -G Xcode # now works fine
Move closer to allowing an "out of the box" distributable build for Mac:
* fix the icon for the .app
* link SDL2 statically, a PR has been sent to the original repo here:
https://github.com/tcbrindle/sdl2-cmake-scripts/pull/9
* link SFML statically
TODO:
For a releasable build on OS X, system libs must be linked
dynamically while third party libs are linked statically or bundled. The
goal is to link them statically.
The two remaining libs that need static linking are PNG and wX.
For PNG a similar approach to the one used for SDL2 using pkg-config
should work fine and be simple to implement.
For wX things are more complicated. The default build of wX does not
include static libs, I will need to submit a PR for Homebrew to change
the default build to include both dynamic and static versions.
Use a high-res surface on HiDPI (e.g. retina) Macs for the OpenGL
renderer, and scale window accordingly. Also fix fullscreen toggle not
working in HiDPI mode. And some other stuff.
Aside from the .app not being linked statically, the app is now fully
functional on Mac and ready to ship.
Full change details:
* add -DDEBUG or -DNDEBUG based on CMAKE_BUILD_TYPE (-DNDEBUG for
Release and -DDEBUG for Debug)
* properly search for homebrew/macports/fink directories, and only add
them if they exist
* fix building with wx debug support, when available
* use explicit OpenGL context on Mac too for new versions of wx
* add main_frame pointer in GameArea back to MainFrame, and a
SetMainFrame(MainFrame* parent) public method to set it in guinit
* add full support for reading and writing double value config options
(the GUI still needs to be updated for options that can take doubles,
such as video_scale)
* change video_scale option (Display/Scale) to a double, putting a
double value such as 3.6 in the config file works correctly
* add a HiDPIAware mixin class for GameArea and DrawingPanel, with the
method HiDPIScaleFactor which returns the current window's
backingScaleFactor
* change the GameArea sizing methods (DelBorder(), AdjustMinSize() and
AdjustSize()) to divide the window size by the
HiDPIAware::HiDPIScaleFactor so that the window is scaled properly
* change GameArea::ShowFullScreen to ignore fullscreen events for a
maximized window on Mac, because maximized windows on OS X are
actually native fullscreen windows
* change scale variables to double from int, and use std::ceil() to
round scaled pixel or memory size values
* make a default base class DrawingPane::DrawingPanelInit() virtual
method, call by all concrete class constructors based on the did_init
flag
* call setWantsBestResolutionOpenGLSurface:YES on the view backing the
wxGLCanvas for the OpenGL renderer (GLDrawingPanel) to get a high res
OpenGL surface in HiDPI mode
* remove GLDrawingPanel::OnSize event, the OpenGL viewport resizes
automatically without the need to call glViewport()
* do not hide the mouse pointer if the main frame has menus or dialogs
open
* add variadic vbamDebug(const char* format, ...) function, active only
#ifdef DEBUG, which sets the wx log target to STDERR and logs a
message to it
* use full name of app "visualboyadvance-m" instead of "vbam" when
getting configuration paths, this way the config is saved to
~/Library/Application Support/visualboyadvance-m rather than
~/Library/Application Support/vbam
* listen to the MENU_HIGHLIGHT_ALL event as well, as an extra way to
check when the menus are open
* add public MainFrame::SetMenusOpened(bool state) method to force the
main frame to change the internal menus_opened state, this is
necessary because in HiDPI mode on Mac the keyboard accelerator for
toggle fullscreen sends a menu open event, but not a menu close event,
so on switch to fullscreen the state is changed to menus closed and
the emu is unpaused
TODO:
* GUI option to change toggle fullscreen behavior between native and
non-native fullscreen on Mac
* GUI support for double config values like Display/Scale
* add HiDPI support to simple renderer
* fix SDL sound, or disable the option
* fix Cairo suport on Mac, or disable the option
* use dynamic_cast<> to implement GetWindow() for DrawingPanel instead
of pure virtual method, likewise for Delete()
* link .app statically by default so it can be shipped
* add Homebrew formula
Currently, the build is broken on Linux as fixed width integers (for
example uint32) are used via <cstdint> without a namespace. This is only
allowed in C++11 and later.
See http://en.cppreference.com/w/cpp/types/integer for details.
Add Homebrew and MacPorts paths for findings headers and libraries.
Add -x objective-c++ to the C++ compile command so that conditionally
compiled ObjectiveC code for OS X can be supported.
Throw a fatal error if the user tries to enable ENABLE_ASM_CORE,
ENABLE_ASM_SCALERS or ENABLE_MMX on AMD64, as this is not supported yet.
If ENABLE_ASM_SCALERS is enabled, try to find a Homebrew or MacPorts
nasm before using the outdated XCode nasm.
For the future, if the user has only the old XCode nasm which does not
support 64 bit objects and the build is 64 bit, throw a fatal error.
For 32 bit builds with the old XCode nasm, use -f macho instead of -f
macho32, which is used if the version of nasm is > 2.0 .
Pass -DMACHO instead of -DELF and, on AMD64 (for the future) -D__AMD64__
for nasm on OS X.
Pass -D__AMD64__ to C++ compilation as well on AMD64, this will help
when we support AMD64 inline assembly.
Add support for automatically linking Homebrew keg-only gettext from
/usr/local/opt/gettext for ENABLE_NLS.
Fix copying Info.plist and vbam.icns to the .app bundle.
Add a key to the Info.plist to support sharp text on retina displays, as
per:
https://wiki.wxwidgets.org/WxMac-specific_topics#Retina_display_support
Set wxWidgets_USE_DEBUG to ON if CMAKE_BUILD_TYPE is "Debug". I'm not
sure this does anything or if I'm doing this correctly though.
Also set wxWidgets_USE_UNICODE to ON. Again, I'm not sure this does
anything or is in the right place.
Fix a bug in the config dir finding code in
wxvbamApp::GetConfigurationPath() updated in 8b8f2f7 to only use the
more top level dirs if there is a vbam.ini in them, not if they are
writable as well, and use the reverse order (starting with user local
dirs) to check for writable dirs and their writable parents. This fixes
a problem with the vbam.ini being written to the Plugins directory of
the .app bundle if it's writable instead of ~/Library/Application
Support/vbam as was intended.
This allows breakpoints, memory views and watches to be controlled from the GDB interface. The VBA-SDL-H2 commands can be entered via the GDB monitor (type "help" into the monitor for a list of commands). Made minor changes to the GDB interface so that the GDB port does not need to be entered every session. A "Break on Load" option has been added allowing GDB to be connected before the ROM starts executing.
VBA-SDL-H2 credits: Labmaster, kenobi, DevZ, richq, JPAN, Griever
One thing it does, is correct any raw files scanned, if they are correctable. (usually, uncorrectable raw files come up with a read error.) There is also bin support included as well. (Note, if you open a valid dotcode bin, it will encode it to raw, and save the freshly encoded raw file if it has been set in the menu. If the dotcode save file has not been set, the bin will still load.)
Currently, part of the GBA emulation breaks the E-Reader scan code. The reader always returns a Region Error.
The changes are :
- debian/control: Build-Depends now include nasm for i386 and amd64
- debian/control: Architecture is now "any"
- debian/rules: Less verbosity when DH_VERBOSE is not set
- debian/rules: -DUSE_ARM_SCALERS=ON -DUSE_ARM_CORE=ON on i386 and amd64
architectures
- CMakeLists.txt: Out-of-source builds using USE_ARM_SCALERS is now
working
- Changed the config file location to follow the freedesktop.org XDG Base Directory Specification. There is no point to be compatible with the old location since we haven't made a release yet.
- Renamed the configuration file to vbam.cfg to avoid conflict with the original VBA (thanks to tttttttttanaka for the patch)
- Changed the window title to VBA-M
- The expression parser/lexer is SDL specific, moved it to the sdl folder
- Readded the flex/bison source files from VBA's CVS
- Rebuilt the parser/lexer from source
- You can now choose if you want to build the GTK frontend, the SDL frontend, or both
- It is now possible to use the ASM core
- Added a bit of documentation at the beginning of the file
- Improved the CMake script
- Removed some leftover debug code
- Simplified the menu appearance
- Made the debian packaging scripts use the cmake build system
- Added the GTK build to the debian package