Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ jobs:
arch: arm64
target_distro: debian
target_base: '12'
target_ruby: system
target_ruby: latest
- os: ubuntu-24.04
arch: x86_64
target_distro: arch
Expand Down Expand Up @@ -104,12 +104,12 @@ jobs:
- os: ubuntu-24.04
arch: x86_64
target_distro: debian
target_base: 'latest'
target_ruby: latest
target_base: '13'
target_ruby: system
- os: ubuntu-24.04-arm
arch: arm64
target_distro: fedora
target_base: '43'
target_base: '44'
target_ruby: system
- os: ubuntu-24.04-arm
arch: arm64
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/linux-master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
gtk_version: 3
CC: gcc
CXX: g++
ruby: '3.2'
ruby: '3.4'
wxWidgets: 'master'
swig: '4'
use_xvfb: true
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
gtk_version: 3
CC: gcc
CXX: g++
ruby: '3.0'
ruby: '3.4'
swig: '4'
use_xvfb: true
configure_flags: --disable-webview
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/mac-master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
runner: macos-15-intel
arch: x86_64
wxWidgets: 'master'
ruby: '3.0'
ruby: '3.4'
swig: '4'
configure_flags: --disable-sys-libs --enable-webview
wxw_type: develop
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/msw-master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
- os: windows-2022
platform: 'x64'
CXX: g++-12
ruby: '3.2'
ruby: '3.4'
wxWidgets: 'master'
swig: '4'
configure_flags: --enable-webview
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/msw.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ jobs:
- os: windows-2022
platform: 'x64'
CXX: g++-12
ruby: '3.0'
ruby: '3.4'
swig: '4'
configure_flags: --enable-webview
wxw_type: embed
Expand All @@ -67,7 +67,7 @@ jobs:
- os: windows-2022
platform: 'x64'
CXX: g++-12
ruby: '3.1'
ruby: '3.4'
swig: '4'
configure_flags: --enable-webview
wxw_type: embed
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -314,12 +314,12 @@ jobs:
- os: ubuntu-24.04-arm
arch: arm64
target_distro: fedora
target_base: '44'
target_base: '45'
target_ruby: 'system'
- os: ubuntu-24.04
arch: x86_64
target_distro: fedora
target_base: '44'
target_base: '45'
target_ruby: 'system'
- os: ubuntu-24.04-arm
arch: arm64
Expand Down
30 changes: 20 additions & 10 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ should always result in a successfully installed wxRuby3 version.
> like [ruby-install](https://github.com/postmodern/ruby-install) or [RVM](https://rvm.io) (only user installations
> supported) or [rbenv](https://rbenv.org).

> **NOTE**<br>
> Be aware that [Homebrew](https://brew.sh/) has discontinued support for MacOS on Intel CPU and does not update
> packages for that platform anymore. Users of MacOS on Intel CPU should switch to [MacPorts](https://www.macports.org/) instead.

[Below](INSTALL.md#installing-software-requirements) more details regarding the software requirements for wxRuby3, the
setup procedure and various options to tweak and customize the installation (including platform specific details for
Linux, Windows and MacOSX) are described.
Expand Down Expand Up @@ -77,10 +81,12 @@ The following tables lists the packages provided by the current wxRuby3 release
| Linux | Fedora (at least latest stable) | x86_64 <b>and</b> ARM64 | Distro provided Ruby <b>and</b> Latest stable Ruby |
| Linux | Debian (at least latest stable) | x86_64 <b>and</b> ARM64 | Distro provided Ruby <b>and</b> Latest stable Ruby |
| Linux | Ubuntu (at least latest stable) | x86_64 <b>and</b> ARM64 | Distro provided Ruby <b>and</b> Latest stable Ruby |
| Linux | Mint (latest stable) | x86_64 | Distro provided Ruby <b>and</b> Latest stable Ruby |
| Windows | NA | x86_64 | Latest stable Ruby |
| OSX | MacOS 14 | ARM64 | Latest stable Ruby |
| OSX | MacOS 15 | x86_64 <b>and</b> ARM64 | Latest stable Ruby |
| OSX | MacOS 26 | x86_64 <b>and</b> ARM64 | Latest stable Ruby |
| OSX | MacOS 15 | x86_64 [**1**] <b>and</b> ARM64 | Latest stable Ruby |
| OSX | MacOS 26 | x86_64 [**1**] <b>and</b> ARM64 | Latest stable Ruby |

[**1**] Please be aware that Apple has dropped support for MacOS on Intel CPU for versions > 26.

### Additional packages

Expand All @@ -106,11 +112,11 @@ Both files are required for installation and should be located at the same path
The software requirements for setting up a wxRuby3 runtime environment are:

| Sofware | Notes |
|-----------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Ruby >= 3.0 | A supported version of the Ruby interpreter needs to be installed. This is an absolute requirement for any installation as one cannot install gems without Ruby and building from source requires Ruby to drive the build process. |
| C++ compiler<br>(incl. dev tools like `make`) | Required for a source based installation to build wxWidgets (optionally) and the wxRuby extension libraries.<br/>On linux a recent version of the GNU C++ compiler (with c++-14 support) is required.<br>On Windows the RubyInstaller MSYS2-Devkit would be required.<br>On MacOS XCode with commandline tools would be required. |
|-----------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Ruby >= 3.2 | A supported version of the Ruby interpreter needs to be installed. This is an absolute requirement for any installation as one cannot install gems without Ruby and building from source requires Ruby to drive the build process. |
| C++ compiler<br>(incl. dev tools like `make`) | Required for a source based installation to build wxWidgets (optionally) and the wxRuby extension libraries.<br/>On linux a recent version of the GNU C++ compiler (with c++-14 support) is required.<br>On Windows the RubyInstaller MSYS2-Devkit would be required.<br>On MacOS XCode with commandline tools would be required.|
| Git version control toolkit | Required for a source based installation in to (possibly) clone a copy of the wxWidgets Github repository or to clone the Github repository of wxRuby3 itself for a fully source based installation. |
| Doxygen (>= 1.9.1) | Required for building the wxRuby3 extension libraries for a source based installation. [**1**] |
| Doxygen (>= 1.9.1; < 1.18.0 on MacOS) | Required for building the wxRuby3 extension libraries for a source based installation. [**1**] |
| SWIG >= 3.0.12 | Required for building the wxRuby3 extension libraries for a source based installation. [**2**] |
| Patchelf (Linux) or install_name_tool (OSX) | Required for setting up embedded wxWidgets libraries. [**3**] |
| wxWidgets (>= 3.2) | Runtime libraries required for any wxRuby3 installation (either from embedded wxWidgets installation or a system or user installation; see below). |
Expand Down Expand Up @@ -217,9 +223,9 @@ This command only fails when:
>
> Run 'wxruby -h' to see information on the available commands.
>
> Successfully installed wxruby3-0.9.8
> Parsing documentation for wxruby3-0.9.8
> Installing ri documentation for wxruby3-0.9.8
> Successfully installed wxruby3-2.0.0
> Parsing documentation for wxruby3-2.0.0
> Installing ri documentation for wxruby3-2.0.0
> Done installing documentation for wxruby3 after 2 seconds
> 1 gem installed
> ```
Expand Down Expand Up @@ -283,6 +289,10 @@ If any required software needs to be added the setup procedure will ask consent
install the missing software using appropriate tooling for the platform (on Linux standard distribution installers which
may require a 'sudo' password and on MacOSX using either [MacPorts](https://www.macports.org/) or [Homebrew](https://brew.sh/)).

> **NOTE**<br>
> Be aware that [Homebrew](https://brew.sh/) has discontinued support for MacOS on Intel CPU and does not update
> packages for that platform anymore. Users of MacOS on Intel CPU should switch to [MacPorts](https://www.macports.org/) instead.

> Running the setup command will look something like this:
> ```
> $ wxruby setup
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,9 @@ Currently, the following are fully supported:

| Platform | Ruby version(s) | wxWidgets version(s) |
|--------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------|----------------------|
| Windows >= 10 | Ruby >= 3.0<br>(RubyInstaller MSYS2-DevKit) | wxWidgets >= 3.2 |
| Linux (tested; all major AMD64 and ARM64 distributions: Ubuntu, Debian, Fedora, OpenSuSE, LinuxMint, Manjaro and ArchLinux)<br>(most likely also i686) | Ruby >= 3.0 | wxWidgets >= 3.2 |
| MacOS >= 14 (MacOS 13 most likely also works) using Cocoa (tested on AMD64 and ARM64 M1/M2 Chip) | Ruby >= 3.0 (MacPorts, Homebrew, ruby-install, RVM, Rbenv) | wxWidgets >= 3.2 |
| Windows >= 10 | Ruby >= 3.2<br>(RubyInstaller MSYS2-DevKit) | wxWidgets >= 3.2 |
| Linux (tested; all major AMD64 and ARM64 distributions: Ubuntu, Debian, Fedora, OpenSuSE, LinuxMint, Manjaro and ArchLinux)<br>(most likely also i686) | Ruby >= 3.2 | wxWidgets >= 3.2 |
| MacOS >= 15 (MacOS 14 might still work) using Cocoa (tested on AMD64 and ARM64 M1/M2 Chip) | Ruby >= 3.2 (MacPorts, Homebrew, ruby-install, RVM, Rbenv) | wxWidgets >= 3.2 |

Support for other platforms is not being actively developed at present,
but patches are welcome. It is likely to be much simpler to get wxRuby
Expand Down
13 changes: 3 additions & 10 deletions lib/wx/core/file_dialog.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,9 @@ class FileDialog
class FileDialogCustomizeHook

# prevent construction of abstract base
if (RUBY_VERSION.split('.').collect {|v| v.to_i} <=> [2,7,0]) < 0
def self.new(*)
raise NotImplementedError, 'Wx::FileDialogCustomizeHook is an abstract class.' if self == Wx::FileDialogCustomizeHook
super
end
else
def self.new(*, **)
raise NotImplementedError, 'Wx::FileDialogCustomizeHook is an abstract class.' if self == Wx::FileDialogCustomizeHook
super
end
def self.new(*, **)
raise NotImplementedError, 'Wx::FileDialogCustomizeHook is an abstract class.' if self == Wx::FileDialogCustomizeHook
super
end

# provide default no-ops
Expand Down
16 changes: 3 additions & 13 deletions lib/wx/keyword_ctors.rb
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,7 @@ module KeywordConstructor
# by the Rails #class_attribute method.
module ParamSpec

if (RUBY_VERSION.split('.').collect {|v| v.to_i} <=> [2,7,0]) < 0
PARAM_SPEC_ARG = [:param_spec]
else
PARAM_SPEC_ARG = [:param_spec, false]
end
PARAM_SPEC_ARG = [:param_spec, false]

def self.included(mod)
mod.class_eval do
Expand Down Expand Up @@ -164,14 +160,8 @@ def wx_ctor_params(*params)
end
end

if (RUBY_VERSION.split('.').collect {|v| v.to_i} <=> [3,0,0]) <= 0
def args_as_list(*mixed_args)
Wx::args_as_list(param_spec, *mixed_args)
end
else
def args_as_list(*args, **kwargs)
Wx::args_as_list(param_spec, *args, **kwargs)
end
def args_as_list(*args, **kwargs)
Wx::args_as_list(param_spec, *args, **kwargs)
end

def describe_constructor(txt = '')
Expand Down
6 changes: 3 additions & 3 deletions rakelib/lib/config.rb
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,10 @@ module WXRuby3
CONFIG['wxversion'] = ENV['WXRUBY_WXVERSION'] if ENV['WXRUBY_WXVERSION']
BUILD_CFG = '.wxconfig'

# Ruby 2.7 is the minimum version for wxRuby3
# Ruby 3.2 is the minimum version for wxRuby3
__rb_ver = RUBY_VERSION.split('.').collect {|v| v.to_i}
if (__rb_major = __rb_ver.shift) < 2 || (__rb_major == 2 && __rb_ver.shift < 7)
$stderr.puts 'ERROR: wxRuby3 requires Ruby >= 2.7.0!'
if (__rb_major = __rb_ver.shift) < 3 || (__rb_major == 3 && __rb_ver.shift < 2)
$stderr.puts 'ERROR: wxRuby3 requires Ruby >= 3.2.0!'
exit(1)
end

Expand Down
Loading