From e11e63b2090f25f5cab19278437003a90faf4377 Mon Sep 17 00:00:00 2001 From: Alexandre Bique Date: Mon, 8 Jan 2024 12:57:35 +0100 Subject: [PATCH] Finish the exclusion of drafts from `clap.h` --- README.md | 1 + conventions/extension-id.md | 2 ++ include/clap/{draft.h => all.h} | 6 ++++-- src/main.c | 3 +-- src/main.cc | 3 +-- 5 files changed, 9 insertions(+), 6 deletions(-) rename include/clap/{draft.h => all.h} (84%) diff --git a/README.md b/README.md index 0d3a99b9..c8af6ecc 100644 --- a/README.md +++ b/README.md @@ -32,6 +32,7 @@ that is, a plugin binary compiled with CLAP 1.x can be loaded by any other CLAP 1.y. To work with CLAP, include [clap/clap.h](include/clap/clap.h). +To also include the draft extensions, include [clap/all.h](include/clap/all.h). The two most important objects are `clap_host` and `clap_plugin`. diff --git a/conventions/extension-id.md b/conventions/extension-id.md index b725be8d..c07b22a0 100644 --- a/conventions/extension-id.md +++ b/conventions/extension-id.md @@ -14,8 +14,10 @@ Where: ## Draft An extension is considered a draft extension if it is in the [draft](../include/clap/ext/draft/) folder. +Make sure to also include it in [all.h](../include/clap/all.h). When the extension is migrating from draft to stable, its extension ID must not change. +Move its inclusion from [all.h](../include/clap/all.h) into [clap.h](../include/clap/clap.h). All extensions must go though the draft phase first. diff --git a/include/clap/draft.h b/include/clap/all.h similarity index 84% rename from include/clap/draft.h rename to include/clap/all.h index 7d5f6a34..40e83469 100644 --- a/include/clap/draft.h +++ b/include/clap/all.h @@ -1,12 +1,14 @@ #pragma once +#include "clap.h" + #include "factory/draft/plugin-invalidation.h" #include "factory/draft/plugin-state-converter.h" #include "ext/draft/ambisonic.h" #include "ext/draft/cv.h" -#include "ext/draft/midi-mappings.h" +#include "ext/draft/extensible-audio-ports.h" #include "ext/draft/resource-directory.h" +#include "ext/draft/transport-control.h" #include "ext/draft/triggers.h" #include "ext/draft/tuning.h" -#include "ext/draft/extensible-audio-ports.h" diff --git a/src/main.c b/src/main.c index f4db6b79..eaeb5251 100644 --- a/src/main.c +++ b/src/main.c @@ -1,5 +1,4 @@ -#include -#include +#include // The purpose of this file is to check that all headers compile int main(int argc, char **argv) { diff --git a/src/main.cc b/src/main.cc index 1071d67d..fcf64a69 100644 --- a/src/main.cc +++ b/src/main.cc @@ -1,5 +1,4 @@ -#include -#include +#include // The purpose of this file is to check that all headers compile