Skip to content

Commit

Permalink
All - Add cava Dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
nlogozzo committed Jan 10, 2025
1 parent b03b628 commit b20e54e
Show file tree
Hide file tree
Showing 5 changed files with 175 additions and 2 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,10 @@ jobs:
run: |
$ProgressPreference = 'SilentlyContinue'
Invoke-WebRequest https://aka.ms/vs/17/release/vc_redist.x64.exe -OutFile vc_redist.x64.exe
Invoke-WebRequest https://download.microsoft.com/download/1/6/B/16B06F60-3B20-4FF2-B699-5E9B7962F9AE/VSU_4/vcredist_x64.exe -OutFile vc_redist.2012.x64.exe
Invoke-WebRequest https://github.com/karlstav/cava/releases/download/0.10.3/cava_win.zip -OutFile cava.zip
Expand-Archive -Force 'cava.zip'
Remove-Item -Force cava\config
iscc setup.iss
- name: Upload
uses: actions/upload-artifact@v4
Expand Down
72 changes: 72 additions & 0 deletions flatpak/org.nickvision.cavalier.gnome.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"finish-args":[
"--socket=fallback-x11",
"--socket=wayland",
"--socket=pulseaudio",
"--device=dri",
"--share=ipc",
"--talk-name=com.canonical.Unity",
Expand Down Expand Up @@ -64,6 +65,77 @@
}
]
},
{
"name": "fftw3f",
"config-opts": [
"--enable-threads",
"--enable-shared",
"--disable-static",
"--enable-float"
],
"build-options": {
"arch": {
"x86_64": {
"config-opts": [
"--enable-sse2",
"--enable-avx",
"--enable-avx-128-fma"
]
},
"aarch64": {
"config-opts": [
"--enable-neon"
]
}
}
},
"sources": [
{
"type": "archive",
"url": "https://www.fftw.org/fftw-3.3.10.tar.gz",
"sha256": "56c932549852cddcfafdab3820b0200c7742675be92179e59e6215b340e26467"
}
],
"cleanup": [
"/bin",
"/include",
"/lib/cmake",
"/lib/pkgconfig",
"/share/man",
"*.la",
"*.so"
]
},
{
"name" : "iniparser",
"buildsystem" : "simple",
"build-commands" :
[
"make PREFIX=/app",
"install -Dm0644 src/iniparser.h /app/include/iniparser.h",
"install -Dm0644 src/dictionary.h /app/include/dictionary.h",
"install -Dm0644 libiniparser.so.1 /app/lib/libiniparser.so.1",
"ln -sf libiniparser.so.1 /app/lib/libiniparser.so"
],
"sources" : [
{
"type" : "git",
"url" : "https://github.com/ndevilla/iniparser.git",
"tag" : "v4.2.5"
}
]
},
{
"name" : "cava",
"buildsystem" : "autotools",
"sources" : [
{
"type" : "git",
"url" : "https://github.com/karlstav/cava.git",
"tag" : "0.10.3"
}
]
},
{
"name": "blueprint-compiler",
"buildsystem": "meson",
Expand Down
72 changes: 72 additions & 0 deletions flatpak/org.nickvision.cavalier.qt.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"finish-args":[
"--socket=fallback-x11",
"--socket=wayland",
"--socket=pulseaudio",
"--device=dri",
"--share=ipc",
"--talk-name=com.canonical.Unity",
Expand Down Expand Up @@ -81,6 +82,77 @@
}
]
},
{
"name": "fftw3f",
"config-opts": [
"--enable-threads",
"--enable-shared",
"--disable-static",
"--enable-float"
],
"build-options": {
"arch": {
"x86_64": {
"config-opts": [
"--enable-sse2",
"--enable-avx",
"--enable-avx-128-fma"
]
},
"aarch64": {
"config-opts": [
"--enable-neon"
]
}
}
},
"sources": [
{
"type": "archive",
"url": "https://www.fftw.org/fftw-3.3.10.tar.gz",
"sha256": "56c932549852cddcfafdab3820b0200c7742675be92179e59e6215b340e26467"
}
],
"cleanup": [
"/bin",
"/include",
"/lib/cmake",
"/lib/pkgconfig",
"/share/man",
"*.la",
"*.so"
]
},
{
"name" : "iniparser",
"buildsystem" : "simple",
"build-commands" :
[
"make PREFIX=/app",
"install -Dm0644 src/iniparser.h /app/include/iniparser.h",
"install -Dm0644 src/dictionary.h /app/include/dictionary.h",
"install -Dm0644 libiniparser.so.1 /app/lib/libiniparser.so.1",
"ln -sf libiniparser.so.1 /app/lib/libiniparser.so"
],
"sources" : [
{
"type" : "git",
"url" : "https://github.com/ndevilla/iniparser.git",
"tag" : "v4.2.5"
}
]
},
{
"name" : "cava",
"buildsystem" : "autotools",
"sources" : [
{
"type" : "git",
"url" : "https://github.com/karlstav/cava.git",
"tag" : "0.10.3"
}
]
},
{
"name": "org.nickvision.cavalier",
"buildsystem": "cmake-ninja",
Expand Down
13 changes: 12 additions & 1 deletion inno/setup.iss
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,15 @@ begin
MsgBox('Unable to install VC . Please try again', mbError, MB_OK);
end;
procedure SetupVC2012();
var
ResultCode: Integer;
begin
if not Exec(ExpandConstant('{app}\deps\vc_redist.2012.x64.exe'), '/install /quiet /norestart', '', SW_HIDE, ewWaitUntilTerminated, ResultCode)
then
MsgBox('Unable to install VC . Please try again', mbError, MB_OK);
end;
procedure Cleanup();
begin
DelTree(ExpandConstant('{app}\deps'), True, True, True);
Expand All @@ -57,7 +66,9 @@ Name: "english"; MessagesFile: "compiler:Default.isl"
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked

[Files]
Source: "vc_redist.x64.exe"; DestDir: "{app}\deps"; AfterInstall: SetupVC
Source: "vc_redist.x64.exe"; DestDir: "{app}\deps"; AfterInstall: SetupVC
Source: "vc_redist.2012.x64.exe"; DestDir: "{app}\deps"; AfterInstall: SetupVC2012
Source: "cava\*"; DestDir: "{app}\Release"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "..\build\org.nickvision.cavalier.qt\Release\{#MyAppExeName}"; DestDir: "{app}\Release"; Flags: ignoreversion
Source: "..\build\org.nickvision.cavalier.qt\Release\*"; DestDir: "{app}\Release"; Flags: ignoreversion recursesubdirs createallsubdirs; AfterInstall: Cleanup
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
Expand Down
16 changes: 15 additions & 1 deletion snap/snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,20 @@ parts:
- libboost-json1.83-dev
override-prime: ''

cava:
source: https://github.com/karlstav/cava.git
source-tag: '0.10.3'
source-depth: 1
build-environment:
- CFLAGS: -I/snap/gnome-46-2404-sdk/current/usr/include
plugin: autotools
autotools-configure-parameters:
- --prefix=/usr
build-packages:
- libfftw3-dev
prime:
- -usr/share

libxmlplusplus:
source: https://github.com/libxmlplusplus/libxmlplusplus.git
source-tag: '5.4.0'
Expand All @@ -63,7 +77,7 @@ parts:
- usr/lib/${CRAFT_ARCH_TRIPLET_BUILD_FOR}/libxml++-5.0*.so*

cavalier:
after: [maddy, libnick, libxmlplusplus]
after: [maddy, libnick, cava, libxmlplusplus]
plugin: cmake
source: .
build-snaps:
Expand Down

0 comments on commit b20e54e

Please sign in to comment.