When macOS bundled application is launched from Finder, MacOS assigns it a unique process serial number (PSN) and passes it to application as a command line argument, for example "-psn_0_8423432" (see description on stack overflow). When cxxopts tries to parse command line with psn argument it throws OptionException "Argument ‘-psn_0_8423432’ starts with a - but has incorrect syntax". When application is started from Terminal by full path to executable inside bundle it works normally because there is no psn argument in command line options.
When macOS bundled application is launched from Finder, MacOS assigns it a unique process serial number (PSN) and passes it to application as a command line argument, for example "-psn_0_8423432" (see description on stack overflow). When cxxopts tries to parse command line with psn argument it throws OptionException "Argument ‘-psn_0_8423432’ starts with a - but has incorrect syntax". When application is started from Terminal by full path to executable inside bundle it works normally because there is no psn argument in command line options.
Related issue created on cxxopts project: https://github.com/jarro2783/cxxopts/issues/171