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

Fix: Add missing dependencies and CMake flags #345

Merged
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,17 @@ jobs:
runs-on: macos-13
steps:
- name: Install dependencies
run: brew install automake fluid-synth gtk+ cairo lv2
run: brew install automake fluid-synth gtk+ cairo lv2 gtk-mac-integration expat
- name: Check out
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Configure
run: |
export LDFLAGS="-L$(brew --prefix)/lib"
export CPPFLAGS="-I$(brew --prefix expat)/include"
mkdir build && cd build
cmake .. -DCMAKE_INSTALL_PREFIX=../install
cmake .. -DCMAKE_INSTALL_PREFIX=../install -DCMAKE_SHARED_LINKER_FLAGS="-L$(brew --prefix)/lib -Wl,-rpath,$(brew --prefix)/lib" -DCMAKE_CXX_FLAGS="-I$(brew --prefix)/include"
- name: Build
run: cmake --build build
# install does not work yet, but seems less critical for now
Expand Down
6 changes: 4 additions & 2 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,10 @@ if(USE_LV2 AND USE_GUI)
set(LV2DIR "${CMAKE_INSTALL_PREFIX}/lib/lv2/calf.lv2")
add_library(calflv2gui SHARED gui.cpp gui_config.cpp gui_controls.cpp ctl_curve.cpp ctl_keyboard.cpp ctl_knob.cpp ctl_led.cpp ctl_tube.cpp ctl_vumeter.cpp ctl_frame.cpp ctl_fader.cpp ctl_buttons.cpp ctl_notebook.cpp ctl_meterscale.cpp ctl_combobox.cpp ctl_tuner.cpp ctl_phasegraph.cpp ctl_pattern.cpp metadata.cpp giface.cpp plugin_gui_window.cpp preset.cpp preset_gui.cpp lv2gui.cpp osctl.cpp utils.cpp ctl_linegraph.cpp drawingutils.cpp)
target_include_directories(calflv2gui PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
target_link_options(calflv2gui PRIVATE -Wl,-z,nodelete)
target_link_libraries(calflv2gui PRIVATE ${GTK_LIBRARIES} fluidsynth)
if (NOT APPLE)
erickisos marked this conversation as resolved.
Show resolved Hide resolved
target_link_options(calflv2gui PRIVATE -Wl,-z,nodelete)
endif()
target_link_libraries(calflv2gui PRIVATE ${GTK_LIBRARIES} ${EXPAT_LIBRARIES} fluidsynth)
set_target_properties(calf PROPERTIES
INSTALL_RPATH "${LV2DIR}"
BUILD_WITH_INSTALL_RPATH TRUE
Expand Down