Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linker error with onDropdownEvent - missing required architecture arm64 #160

Open
tjex opened this issue Sep 13, 2022 · 0 comments
Open

Comments

@tjex
Copy link

tjex commented Sep 13, 2022

On a M1max 14" MBP. Tried with Xcode 13.3 and 13.4.
I've just tried adding a dropdown to my gui and when using the ofxDatGuiDropdownEvent, I get given a linker error:

ld: warning: ignoring file /Applications/Xcode-13.4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/QTKit.framework/QTKit.tbd, missing required architecture arm64 in file /Applications/Xcode-13.4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk/System/Library/Frameworks/QTKit.framework/QTKit.tbd
Undefined symbols for architecture arm64:
"ofApp::onDropdownEvent(ofxDatGuiDropdownEvent)", referenced from:
ofApp::setup() in ofApp.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I've checked the build phases -> compile sources section and it shows that both the main .cpp source files are included for compilation.

Screen Shot 2022-09-13 at 15 06 06

Not sure what's happening because I also have two sliders and a button that work just fine.
If I comment out the event handler call in setup(), then it compiles successfully.

ofApp.cpp

    gui = new ofxDatGui( ofxDatGuiAnchor::TOP_RIGHT);
    ofxDatGuiButton* ballSpawn = gui->addButton("Spawn Ball");
    gui->onButtonEvent(this, &ofApp::onButtonEvent);
    
    ofxDatGuiSlider* sliderRadius = gui->addSlider("Tombola Size", 0, 200);
    gui->onSliderEvent(this, &ofApp::onSliderEvent);
    
    ofxDatGuiSlider* sliderRotate = gui->addSlider("Tombola Rotate", -5, 5);
    gui->onSliderEvent(this, &ofApp::onSliderEvent);
    
    ofxDatGuiDropdown* midiOutPorts = gui->addDropdown("Midi Out Ports", midiOut.getOutPortList());
    gui->onDropdownEvent(this, &ofApp::onDropdownEvent);

ofApp.h

    // ofxDatGui
    ofxDatGui* gui;
    ofxDatGuiButton* ballSpawn;
    ofxDatGuiSlider* sliderRadius;
    ofxDatGuiSlider* sliderRotate;
    ofxDatGuiDropdown* midiOutPorts;
    void onButtonEvent(ofxDatGuiButtonEvent e);
    void onSliderEvent(ofxDatGuiSliderEvent e);
    void onDropdownEvent(ofxDatGuiDropdownEvent e);

📌 Here is the documentation for dropdowns

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant