You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Notarize package following [Apple's instructions](https://developer.apple.com/documentation/security/customizing-the-notarization-workflow#Upload-your-app-to-the-notarization-service)
70
+
* Distribute generated package in `<Path-To-Checkout>/release/RelWithDebInfo/<Your-Plugin-Name>.pkg`
71
+
72
+
#### Ubuntu
73
+
* Generate an Ubuntu-style `deb` package:
74
+
```Bash
75
+
cmake --prefix ubuntu-x86_64 --target package
76
+
```
77
+
* Generate compressed tar archive
78
+
```Bash
79
+
cd<Path-To-Checkout>/release/RelWithDebInfo
80
+
XZ_OPT=-T0 tar -cJf <Path-To-Checkout>/release/<Your-Plugin-Name>.tar.xz lib share
81
+
```
82
+
83
+
## Detailed Setup
12
84
13
85
The plugin project is set up using the included `buildspec.json` file. The following fields should be customized for an actual plugin:
14
86
@@ -18,8 +90,6 @@ The plugin project is set up using the included `buildspec.json` file. The follo
18
90
*`website`: URL of a website associated with the plugin
19
91
*`email`: Contact email address associated with the plugin
20
92
*`uuids`
21
-
*`macosPackage`: Unique (**!**) identifier for the macOS plugin package
22
-
*`macosInstaller`: Unique (**!**) identifier for the macOS plugin installer
23
93
*`windowsApp`: Unique (**!**) identifier for the Windows plugin installer
24
94
25
95
These values are read and processed automatically by the CMake build scripts, so no further adjustments in other files are needed.
@@ -32,7 +102,7 @@ Platform-specific settings are set up in the `platformConfig` section of the bui
32
102
33
103
### Set Up Build Dependencies
34
104
35
-
Just like OBS Studio itself, plugins need to be built using dependencies available either via the `obs-deps` repository (Windows and macOS) or via a distribution's package system (Linux).
105
+
Just like OBS Studio itself, plugins need to be built using dependencies available either via the `obs-deps` repository (Windows and macOS) or via a distribution's package system (Ubuntu).
36
106
37
107
#### Choose An OBS Studio Version
38
108
@@ -42,7 +112,7 @@ By default the plugin template specifies the most current official OBS Studio ve
42
112
* Plugins targeting the _latest_ version of OBS Studio might not work in older versions because the internal data structures used by `libobs` might not be compatible
43
113
* Users are encouraged to always update to the most recent version of OBS Studio available within a reasonable time after release - plugin authors have to choose for themselves if they'd rather keep up with OBS Studio releases or stay with an older version as their baseline (which might of course preclude the plugin from using functionality introduced in a newer version)
44
114
45
-
On Linux, the version used for development might be decided by the specific version available via a distribution's package management system, so OBS Studio compatibility for plugins might be determined by those versions instead.
115
+
On Ubuntu, the version used for development might be decided by the specific version available via a distribution's package management system, so OBS Studio compatibility for plugins might be determined by those versions instead.
46
116
47
117
#### Windows and macOS
48
118
@@ -52,24 +122,24 @@ Windows and macOS dependency downloads are configured in the `buildspec.json` fi
52
122
*`obs-studio`: Version of OBS Studio to build plugin with (needed for `libobs` and `obs-frontend-api`)
53
123
*`prebuilt`: Prebuilt OBS Studio dependencies
54
124
*`qt6`: Prebuilt version of Qt6 as used by OBS Studio
55
-
*`tools`: Contains additional build tools used by CI
125
+
*`tools`: Contains additional build tools used by CI (Optional)
56
126
57
127
The values should be kept in sync with OBS Studio releases and the `buildspec.json` file in use by the main project to ensure that the plugin is developed and built in sync with its target environment.
58
128
59
129
To update a dependency, change the `version` and associated `hashes` entries to match the new version. The used hash algorithm is `sha256`.
60
130
61
-
#### Linux
131
+
#### Ubuntu
62
132
63
-
Linux dependencies need to be resolved using the package management tools appropriate for the local distribution. As an example, building on Ubuntu requires the following packages to be installed:
133
+
Ubuntu dependencies need to be resolved using the package management tools appropriate for the local distribution. As an example, building on Ubuntu requires the following packages to be installed:
64
134
65
135
* Build System Dependencies:
66
136
*`cmake`
67
137
*`ninja-build`
68
138
*`pkg-config`
69
139
* Build Dependencies:
70
140
*`build-essential`
71
-
*`libobs-dev`
72
-
* Qt6 Dependencies:
141
+
*`obs-studio` - **Important:** Needs to be installed via the `ppa` package
142
+
* Qt6 Dependencies (if custom Qt widgets or dialogs are provided by the plugin):
73
143
*`qt6-base-dev`
74
144
*`libqt6svg6-dev`
75
145
*`qt6-base-private-dev`
@@ -80,47 +150,78 @@ To create a build configuration, `cmake` needs to be installed on the system. Th
80
150
81
151
*`macos`
82
152
* Universal architecture (supports Intel-based CPUs as Apple Silicon)
83
-
* Defaults to Qt version `6`
84
153
* Defaults to macOS deployment target `11.0`
85
154
*`macos-ci`
86
155
* Inherits from `macos`
87
156
* Enables compile warnings as error
88
157
*`windows-x64`
89
158
* Windows 64-bit architecture
90
-
* Defaults to Qt version `6`
91
159
* Defaults to Visual Studio 17 2022
92
-
* Defaults to Windows SDK version `10.0.18363.657`
160
+
* Defaults to Windows SDK version `10.0.22621`
93
161
*`windows-ci-x64`
94
162
* Inherits from `windows-x64`
95
163
* Enables compile warnings as error
96
-
*`linux-x86_64`
97
-
* Linux x86_64 architecture
98
-
* Defaults to Qt version `6`
164
+
*`ubuntu-x86_64`
165
+
* Ubuntu x86_64 architecture
99
166
* Defaults to Ninja as build tool
100
-
* Defaults to `RelWithDebInfo` build configuration
101
-
*`linux-ci-x86_64`
102
-
* Inherits from `linux-x86_64`
103
-
* Enables compile warnings as error
104
-
*`linux-aarch64`
105
-
* Provided as an experimental preview feature
106
-
* Linux aarch64 (ARM64) architecture
107
-
* Defaults to Qt version `6`
108
-
* Defaults to Ninja as build tool
109
-
* Defaults to `RelWithDebInfo` build configuration
110
-
*`linux-ci-aarch64`
111
-
* Inherits from `linux-aarch64`
167
+
*`ubuntu-ci-x86_64`
168
+
* Inherits from `ubuntu-x86_64`
112
169
* Enables compile warnings as error
113
170
114
-
Presets can be either specified on the command line (`cmake --preset <PRESET>`) or via the associated select field in the CMake Windows GUI. Only presets appropriate for the current build host are available for selection.
171
+
Presets can either be specified on the command line (`cmake --preset <PRESET>`) or via the associated select field in the CMake Windows GUI. Only presets appropriate for the current build host are available for selection.
115
172
116
173
Additional build system options are available to developers:
117
174
118
-
*`ENABLE_CCACHE`: Enables support for compilation speed-ups via ccache (enabled by default on macOS and Linux)
175
+
*`ENABLE_CCACHE`: Enables support for compilation speed-ups via ccache (disabled by default on macOS and Ubuntu for local builds)
119
176
*`ENABLE_FRONTEND_API`: Adds OBS Frontend API support for interactions with OBS Studio frontend functionality (disabled by default)
120
177
*`ENABLE_QT`: Adds Qt6 support for custom user interface elements (disabled by default)
121
178
*`CODESIGN_IDENTITY`: Name of the Apple Developer certificate that should be used for code signing
122
179
*`CODESIGN_TEAM`: Apple Developer team ID that should be used for code signing
123
180
181
+
## Creating Distributable Packages
182
+
183
+
#### Windows
184
+
By default an InnoSetup script is generated by the build system und placed in the `build-<ARCHITECTURE>` sub-directory of the project named `installer-Windows.generated.iss` (with <ARCHITECTURE> being limited to just `x64` for the time being). This script file can be use with InnoSetup's `iscc` compiler to generate an installer executable:
To create a simple archive of your plugin, simply compress the contents of the chosen configuration subdirectory (e.g. `RelWithDebInfo`) inside the checkout root's `release` subdirectory with an archiving program of your choice[^6]:
[^6]: Be careful to clean up the `release` directory contents after packaging your plugin to avoid re-packaging already existing packages on consecutive runs of these commands.
197
+
198
+
#### macOS
199
+
200
+
By default the build system will automatically create a distributable package installer named `<Your-Plugin-Name>.pkg` in a subdirectory with the name of the chosen build configuration (e.g. `RelWithDebInfo`) inside the checkout root's `release` subdirectory.
201
+
202
+
For proper distribution this package needs to be signed with a "Developer ID Installer" certificate (see below for more detailed information about signing information):
Finally the package should also be notarized, for which [Apple provides documentation](https://developer.apple.com/documentation/security/customizing-the-notarization-workflow#Upload-your-app-to-the-notarization-service).
209
+
210
+
#### Ubuntu
211
+
212
+
CMake can be invoked to generate Ubuntu-compatible `deb` and `ddeb` packages directly, which will be put into the checkout root's `release` subdirectory:
213
+
```Bash
214
+
cmake --prefix ubuntu-x86_64 --target package
215
+
```
216
+
217
+
Alternatively a simple compressed tar archive can be generated by simply archiving the entire contents of a directory specific to the chosen build configuration (e.g. `RelWithDebInfo` inside that same directory:
218
+
```Bash
219
+
cd<Path-To-Checkout>/release/RelWithDebInfo
220
+
XZ_OPT=-T0 tar -cJf <Path-To-Checkout>/release/<Your-Plugin-Name>.tar.xz lib share
221
+
```
222
+
223
+
Be mindful of the install prefix used for configuring the project (on Ubuntu this should be `/usr/lib/x86_64-linux-gnu` for x86_64 builds), as this becomes the required installation directory for the plugin.
224
+
124
225
## GitHub Actions & CI
125
226
126
227
Default GitHub Actions workflows are available for the following repository actions:
0 commit comments