I want to remove the hack of the dll export hack in building wxsmith plugin.
# Workaround from msys2: error: definition of static data member 'wxsArrayStringEditorDlg::sm_eventTable' of dllimport'd class
# grep -rl "PLUGIN_EXPORT " src/plugins/contrib/wxSmith | xargs -i sed -i "s/PLUGIN_EXPORT //g" {}
So, I remove the hack above.
Now, I see the build error.
It looks like the dll export declaration is not defined.
But when I checked the build log, I see that:
2024-09-24T11:34:32.2601440Z checking for gcc option to produce PIC... -DDLL_EXPORT -DPIC
2024-09-24T11:34:32.4010899Z checking if gcc PIC flag -DDLL_EXPORT -DPIC works... yes
...
...
...
2024-09-24T12:32:02.1013349Z libtool: compile:  g++ -DHAVE_CONFIG_H -I. -I../../../../../src/include -ID:/msys64/mingw64/lib/wx/include/msw-unicode-3.2 -ID:/msys64/mingw64/include/wx-3.2 -D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXMSW__ -I../../../../../src/include -I../../../../../src/sdk/wxscintilla/include -DCB_AUTOCONF -DPIC -O2 -ffast-math -fPIC -fexceptions -MT wxsfloatproperty.lo -MD -MP -MF .deps/wxsfloatproperty.Tpo -c wxsfloatproperty.cpp  -DDLL_EXPORT -DPIC -o .libs/wxsfloatproperty.o
...
...
build failed!!!
You see, when building every plugin, the "-DDLL_EXPORT -DPIC" is defined.
But my question is: Where is the "DLL_EXPORT" get defined? I search all the C::B code git repo, and I can't find one.
When I check the cbp files, I see there is no "DLL_EXPORT" defined, instead, in the cbp file, another macro named "BUILDING_PLUGIN", this is core point, because in the 
include\cbplugin.h, note this file is included in every cpp file when you need to build a plugin.
#ifdef __WXMSW__
    #ifndef PLUGIN_EXPORT
        #ifdef EXPORT_LIB
            #define PLUGIN_EXPORT __declspec (dllexport)
        #else // !EXPORT_LIB
            #ifdef BUILDING_PLUGIN
                #define PLUGIN_EXPORT __declspec (dllexport)
            #else // !BUILDING_PLUGIN
                #define PLUGIN_EXPORT __declspec (dllimport)
            #endif // BUILDING_PLUGIN
        #endif // EXPORT_LIB
    #endif // PLUGIN_EXPORT
#else
    #define PLUGIN_EXPORT
#endif
So, I think we need to solve this issue.
I even checked the configure.ac file or Makefile.am file, I don't find the DLL_EXPORT definition.
Is this value a predefined string?