Skip to content

StringUtils.cpp redefinition of "bool wxm::StartsWithChar" and "bool wxm::EndsWithChar" #2012

@atoussaint76

Description

@atoussaint76

Upon compiling wxmaxima on a Linux From Scratch development release, I get the following errors:

/home/alain/maxima_compile/wxmaxima/src/StringUtils.cpp:73:8: erreur: redéfinition de « bool wxm::StartsWithChar(const wxString&, char) »
73 | bool StartsWithChar(const wxString &str, char ch) {
| ^~~~~~~~~~~~~~
/home/alain/maxima_compile/wxmaxima/src/StringUtils.cpp:69:8: note: « bool wxm::StartsWithChar(const wxString&, wxStringCharType) » précédemment défini ici
69 | bool StartsWithChar(const wxString &str, wxStringCharType ch) {
| ^~~~~~~~~~~~~~
/home/alain/maxima_compile/wxmaxima/src/StringUtils.cpp:85:8: erreur: redéfinition de « bool wxm::EndsWithChar(const wxString&, char) »
85 | bool EndsWithChar(const wxString &str, char ch) {
| ^~~~~~~~~~~~
/home/alain/maxima_compile/wxmaxima/src/StringUtils.cpp:81:8: note: « bool wxm::EndsWithChar(const wxString&, wxStringCharType) » précédemment défini ici
81 | bool EndsWithChar(const wxString &str, wxStringCharType ch) {
| ^~~~~~~~~~~~
make[2]: *** [src/CMakeFiles/wxmaxima.dir/build.make:446: src/CMakeFiles/wxmaxima.dir/StringUtils.cpp.o] Error 1

Excuse the French language error messages but even setting LC_ALL=en_CA.UTF-8 on the command line of cmake and make does not display the error messages in English. Basically, both "bool wxm::StartsWithChar" and "bool wxm::EndsWithChar" get redefined on lines 73 (previous definition on line 69) and 85 (previous definition on 81) in version 24.05.0

I don't know if this has to do with wxWidgets being compiled with utf-8 support (not enabled by default on my build but I did enable utf-8 support) or anything else but I did test 25.01.0, 24.11.0 and this one version 24.05.0. All of them fails.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions