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

Enable linux and mac build in workflow #19

Open
wants to merge 71 commits into
base: develop
Choose a base branch
from
Open

Conversation

stekyne
Copy link
Member

@stekyne stekyne commented Jul 8, 2023

@stekyne stekyne changed the title Enable linux build in workflow Enable linux and mac build in workflow Oct 9, 2024
@stekyne stekyne requested a review from vlazzarini October 9, 2024 16:19
@stekyne stekyne marked this pull request as ready for review October 9, 2024 16:19
@stekyne
Copy link
Member Author

stekyne commented Oct 9, 2024

@vlazzarini I think this is good enough to merge after this long time and lot of changes. Let me know what you think

Copy link
Member

@vlazzarini vlazzarini left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just wondering. I see the csound headers directory in both 6.x and 7.x. Is there a mechanism to keep them in sync with the latest versions? It's not a problem so much for 6.x, which is not going to change, but for 7.x for instance we may update things without breaking ABI and opcodes may depend on it.

I guess before we were depending on FindCsound.cmake. One thing we could do is just grab the sources for Csound from git, build and install a simple no-dependencies copy so that we have the public headers as required. But maybe you have this solved?

@stekyne
Copy link
Member Author

stekyne commented Oct 9, 2024

@vlazzarini You're right. I had tried to think of more sustainable mechanisms, such as adding Csound to chocolatey and installing that before running the build. That way the FindCsound.cmake would work on windows. On Linux and Mac, we'd just use the normal package managers and the same FindCsound.cmake method. This was quite slow though and not always working for some reason. I'm also not sure does it work with multiple versions of Csound installed? I figured that the APIs are not changing much or at least, not enough to break the plugins here so I just dumped them into the repo to make it more reliable.

We can do another way if you think it's better but it's working for now.

@vlazzarini
Copy link
Member

vlazzarini commented Oct 9, 2024

Can we try doing like I'm doing here with libsndfile?

csound/csound#1986

see the macosx vanilla workflow. We could do something similar with Csound here?

Alternatively, could we not do git submodule?

@stekyne
Copy link
Member Author

stekyne commented Oct 9, 2024

Some of the headers are compiled during the build so I don't think we can just lift the headers from the repo or use a submodule/subtree. It's also not that great a DX for local dev. I guess installing a build of Csound makes the most sense and the plugin build already looks for the appropriate csound env vars to find the headers but does this actually work having Csound 6 and 7 installed side by side? If not, then we'll have to do something else.

@vlazzarini
Copy link
Member

Exactly, the raw headers are incomplete.
We need to run a build, install somewhere and then pull the headers. I suppose we should be ok with separate actions for each version. A simple build is very quick, at least on Mac and Linux, we install locally and then pass the path to CMake.

Another alternative is just to run CMake, and the incomplete headers are created in the include subdir, we can copy from that. We don't need a full build, but we will still need to install libsndfile to get CMake to run correctly, so it's not much of a gain.

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

Successfully merging this pull request may close these issues.

2 participants