Page 2 of 2

Re: Linking error: undefined reference BoyScoutUpdateSong()

Posted: Thu Feb 01, 2024 12:48 am
by WinterMute
It looks like you're probably running a cmd shell. This is the environment I end up with using the msys2 shell via vscode.

Code: Select all

ProgramFiles(x86)=C:\Program Files (x86)
CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
SHELL=/usr/bin/bash
NUMBER_OF_PROCESSORS=32
COLORTERM=truecolor
PROCESSOR_LEVEL=23
TERM_PROGRAM_VERSION=1.85.2
CHROME_RESTART=Google Chrome|Whoa! Google Chrome has crashed. Relaunch now?|LEFT_TO_RIGHT
PKG_CONFIG_PATH=/usr/lib/pkgconfig:/usr/share/pkgconfig:/lib/pkgconfig
USERDOMAIN_ROAMINGPROFILE=ASHPOOL
HOSTNAME=ashpool
DEVKITPRO=/opt/devkitpro
PROGRAMFILES=C:\Program Files
MSYSTEM=MSYS
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC
ORIGINAL_TEMP=/home/davem/AppData/Local/Temp
OS=Windows_NT
HOMEDRIVE=C:
MSYSTEM_CARCH=x86_64
USERDOMAIN=ASHPOOL
PWD=/home/davem/projects/gba/cmake-test
USERPROFILE=C:\Users\davem
OneDriveConsumer=C:\Users\davem\OneDrive
MANPATH=/usr/local/man:/usr/share/man:/usr/man:/share/man
PRINTER=Brother MFC-J5345DW Printer
TZ=Europe/London
VSCODE_GIT_ASKPASS_NODE=C:\Users\davem\AppData\Local\Programs\Microsoft VS Code\Code.exe
ALLUSERSPROFILE=C:\ProgramData
ORIGINAL_PATH=/c/Windows/System32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0/
CommonProgramW6432=C:\Program Files\Common Files
HOME=/home/davem
USERNAME=davem
LANG=en_US.UTF-8
OneDrive=C:\Users\davem\OneDrive
COMSPEC=C:\Windows\system32\cmd.exe
GIT_ASKPASS=c:\Users\davem\AppData\Local\Programs\Microsoft VS Code\resources\app\extensions\git\dist\askpass.sh
APPDATA=C:\Users\davem\AppData\Roaming
SYSTEMROOT=C:\Windows
LOCALAPPDATA=C:\Users\davem\AppData\Local
DEVKITARM=/opt/devkitpro/devkitARM
COMPUTERNAME=ASHPOOL
INFOPATH=/usr/local/info:/usr/share/info:/usr/info:/share/info
VSCODE_GIT_ASKPASS_EXTRA_ARGS=--ms-enable-electron-run-as-node
TERM=xterm-256color
LOGONSERVER=\\ASHPOOL
USER=davem
PSModulePath=C:\Program Files\WindowsPowerShell\Modules;C:\Windows\system32\WindowsPowerShell\v1.0\Modules
VSCODE_GIT_IPC_HANDLE=\\.\pipe\vscode-git-c99fb48b8a-sock
TEMP=/tmp
MSYSTEM_CHOST=x86_64-pc-msys
ORIGINAL_TMP=/home/davem/AppData/Local/Temp
SHLVL=1
PROCESSOR_REVISION=0101
DriverData=C:\Windows\System32\Drivers\DriverData
COMMONPROGRAMFILES=C:\Program Files\Common Files
DEVKITPPC=/opt/devkitpro/devkitPPC
PROCESSOR_IDENTIFIER=AMD64 Family 23 Model 1 Stepping 1, AuthenticAMD
SESSIONNAME=Console
PS1=\[\e]0;\w\a\]\n\[\e[32m\]\u@\h \[\e[35m\]$MSYSTEM\[\e[0m\] \[\e[33m\]\w\[\e[0m\]\n\$
VSCODE_GIT_ASKPASS_MAIN=c:\Users\davem\AppData\Local\Programs\Microsoft VS Code\resources\app\extensions\git\dist\askpass-main.js
CHROME_CRASHPAD_PIPE_NAME=\\.\pipe\crashpad_11716_WPBCARGMHRZHAVSH
HOMEPATH=\Users\davem
TMP=/tmp
CONFIG_SITE=/etc/config.site
PATH=/opt/devkitpro/tools/bin:/usr/local/bin:/usr/bin:/bin:/opt/bin:/c/Windows/System32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0/:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
ProgramW6432=C:\Program Files
MSYSTEM_PREFIX=/usr
ORIGINAL_XDG_CURRENT_DESKTOP=undefined
WINDIR=C:\Windows
PROCESSOR_ARCHITECTURE=AMD64
PUBLIC=C:\Users\Public
SYSTEMDRIVE=C:
OLDPWD=/home/davem/projects/gba
TERM_PROGRAM=vscode
ProgramData=C:\ProgramData
_=/usr/bin/env
Notice that the PATH is unix style rather than dos style. I'm struggling to figure out how to get vscode to use this shell for a terminal.

Are you using vscode to run the cmake configure?

Re: Linking error: undefined reference BoyScoutUpdateSong()

Posted: Sun Feb 04, 2024 9:58 am
by thepursuer
Yeah I'm using the integrated terminal. I run cmake inside of the terminal, not through vscode. My vscode settings looks like this:

Code: Select all

{
    "terminal.integrated.profiles.windows": {
        "msys2": {
            "path": "/opt/devkitpro/msys2/usr/bin/bash.exe"
        }
    },
    "terminal.integrated.defaultProfile.windows": "msys2",
    "cmake.buildBeforeRun": false,
    "cmake.configureOnEdit": false,
    "cmake.configureOnOpen": false,
    "files.associations": {
        "map": "cpp",
        "functional": "cpp",
        "array": "cpp",
        "atomic": "cpp",
        "bit": "cpp",
        "*.tcc": "cpp",
        "cctype": "cpp",
        "chrono": "cpp",
        "clocale": "cpp",
        "cmath": "cpp",
        "compare": "cpp",
        "concepts": "cpp",
        "cstdarg": "cpp",
        "cstddef": "cpp",
        "cstdint": "cpp",
        "cstdio": "cpp",
        "cstdlib": "cpp",
        "ctime": "cpp",
        "cwchar": "cpp",
        "cwctype": "cpp",
        "deque": "cpp",
        "string": "cpp",
        "unordered_map": "cpp",
        "vector": "cpp",
        "exception": "cpp",
        "algorithm": "cpp",
        "iterator": "cpp",
        "memory": "cpp",
        "memory_resource": "cpp",
        "numeric": "cpp",
        "random": "cpp",
        "ratio": "cpp",
        "string_view": "cpp",
        "system_error": "cpp",
        "tuple": "cpp",
        "type_traits": "cpp",
        "utility": "cpp",
        "initializer_list": "cpp",
        "iosfwd": "cpp",
        "istream": "cpp",
        "limits": "cpp",
        "new": "cpp",
        "numbers": "cpp",
        "ostream": "cpp",
        "sstream": "cpp",
        "stdexcept": "cpp",
        "streambuf": "cpp",
        "typeinfo": "cpp",
        "unordered_set": "cpp",
        "bitset": "cpp",
        "cstring": "cpp",
        "set": "cpp",
        "optional": "cpp",
        "ios": "cpp",
        "iostream": "cpp",
        "cinttypes": "cpp",
        "semaphore": "cpp",
        "condition_variable": "cpp",
        "stop_token": "cpp",
        "fstream": "cpp",
        "charconv": "cpp",
        "format": "cpp",
        "iomanip": "cpp",
        "span": "cpp",
        "variant": "cpp"
    },
    "C_Cpp.default.cppStandard": "gnu++20",
    "C_Cpp.default.cStandard": "gnu17"
}

Re: Linking error: undefined reference BoyScoutUpdateSong()

Posted: Mon Feb 05, 2024 1:19 am
by thepursuer
Whoops, I copy pasted an attempt to change the path to bash.exe. Originally it looked like:

Code: Select all

"C:\\devkitpro\\msys2\\usr\\bin\\bash.exe"
It might be worth noting that the problem happens even if I just open the terminal outside of vscode.