commit e11e63b2090f25f5cab19278437003a90faf4377
parent 06d6c859b7da5acbd37ad1a7b9be88a97398c1ce
Author: Alexandre Bique <bique.alexandre@gmail.com>
Date: Mon, 8 Jan 2024 12:57:08 +0100
Finish the exclusion of drafts from `clap.h`
Diffstat:
6 files changed, 19 insertions(+), 16 deletions(-)
diff --git 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
@@ -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/all.h b/include/clap/all.h
@@ -0,0 +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/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"
diff --git a/include/clap/draft.h b/include/clap/draft.h
@@ -1,12 +0,0 @@
-#pragma once
-
-#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/resource-directory.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
@@ -1,5 +1,4 @@
-#include <clap/clap.h>
-#include <clap/draft.h>
+#include <clap/all.h>
// 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
@@ -1,5 +1,4 @@
-#include <clap/clap.h>
-#include <clap/draft.h>
+#include <clap/all.h>
// The purpose of this file is to check that all headers compile