Skip to content

Commit

Permalink
With these changes the clap-saw-demo validates
Browse files Browse the repository at this point in the history
  • Loading branch information
baconpaul committed Sep 10, 2023
1 parent 21f9816 commit 64150b3
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 4 deletions.
18 changes: 18 additions & 0 deletions clangformat
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
UseTab: Never
---
Language: Cpp
IndentWidth: 2
AlignAfterOpenBracket: Align
BreakBeforeBraces: Allman
ColumnLimit: 100
SortIncludes: false
---
Language: ObjC
IndentWidth: 2
AlignAfterOpenBracket: Align
BreakBeforeBraces: Allman
ColumnLimit: 100
SortIncludes: false

...
8 changes: 5 additions & 3 deletions cmake/enable_sdks.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -576,6 +576,8 @@ if (APPLE)
# with info.plist and entrypoint-per-instance stuff)
target_sources(${AUV2_TARGET} PRIVATE
${CLAP_WRAPPER_CMAKE_CURRENT_SOURCE_DIR}/src/wrapasauv2.cpp
${CLAP_WRAPPER_CMAKE_CURRENT_SOURCE_DIR}/src/detail/auv2/auv2_shared.h
${CLAP_WRAPPER_CMAKE_CURRENT_SOURCE_DIR}/src/detail/auv2/auv2_base_classes.h
${bhtgoutdir}/generated_entrypoints.hxx)


Expand Down Expand Up @@ -619,9 +621,9 @@ if (APPLE)
COMMAND ${CMAKE_COMMAND} -E copy ${bhtgoutdir}/auv2_Info.plist $<TARGET_FILE_DIR:${AUV2_TARGET}>/../Info.plist)

if (NOT ${CMAKE_GENERATOR} STREQUAL "Xcode")
#add_custom_command(TARGET ${AUV2_TARGET} PRE_BUILD
# WORKING_DIRECTORY $<TARGET_PROPERTY:${AUV2_TARGET},LIBRARY_OUTPUT_DIRECTORY>
# COMMAND SetFile -a B "$<TARGET_PROPERTY:${AUV2_TARGET},MACOSX_BUNDLE_BUNDLE_NAME>.$<TARGET_PROPERTY:${AUV2_TARGET},BUNDLE_EXTENSION>")
add_custom_command(TARGET ${AUV2_TARGET} PRE_BUILD
WORKING_DIRECTORY $<TARGET_PROPERTY:${AUV2_TARGET},LIBRARY_OUTPUT_DIRECTORY>
COMMAND SetFile -a B "$<TARGET_PROPERTY:${AUV2_TARGET},MACOSX_BUNDLE_BUNDLE_NAME>.$<TARGET_PROPERTY:${AUV2_TARGET},BUNDLE_EXTENSION>")
endif()

if (NOT ${AUV2_MACOS_EMBEDDED_CLAP_LOCATION} STREQUAL "")
Expand Down
4 changes: 3 additions & 1 deletion src/detail/auv2/auv2_shared.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#pragma once

#include "detail/clap/fsutil.h"
#include <iostream>

namespace free_audio::auv2_wrapper
{
Expand All @@ -19,6 +20,7 @@ struct ClapBridge
const std::string &clapid,
int idx) : _clapname(clapname), _clapid(clapid), _idx(idx)
{
std::cout << "[clap-wraper] auv2: creating clap bridge nm=" << clapname << " id=" << clapid << " idx=" << idx << std::endl;
}

void initialize()
Expand All @@ -27,7 +29,7 @@ struct ClapBridge
{
if (!_library.load(_clapname.c_str()))
{
std::cout << "[ERROR] cannot load either by internal entry nor _clapname" << std::endl;
std::cout << "[ERROR] cannot load either by internal entry nor _clapname (" << _clapname << ")" << std::endl;
return;
}
}
Expand Down

0 comments on commit 64150b3

Please sign in to comment.