Step 7.5b1: cspot (philippe44 fork) builds and links on the P4

- external/cspot: git submodule, pinned to philippe44/cspot 3010349
  (bell ed2d6e9); GPL-3.0.
- components/spotify: project component wrapping cspot. bell trimmed to
  what cspot needs (Tremor Vorbis; no codec wrapper, sinks, MQTT, web
  server, fmt, regex; cJSON from IDF). Xtensa biquad assembly filtered
  out (P4 is RISC-V). CMAKE_POLICY_VERSION_MINIMUM 3.5 for CMake 4.
- Patches in components/spotify/patches, applied at configure time:
  nanopb generator works with protobuf >= 5 (MakeClass removed);
  URLParser.cpp missing <cstdio>/<cstring> for GCC 14.
- CONFIG_COMPILER_CXX_EXCEPTIONS=y (cspot needs exceptions).
- spotify_init() only builds a LoginBlob (link check).
- CLAUDE.md: submodule init and IDF-venv Python packages for nanopb.
- Verified on board: "cspot linked: device "P4 AES67", zeroconf info 588
  bytes"; HLS still playing, PTP locked; image 1.83 MB (70% free).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-09-25 15:25:10 +10:00
parent 7bbda0a1e8
commit 039ec75473
11 changed files with 125 additions and 2 deletions
+17
View File
@@ -0,0 +1,17 @@
#include "spotify.h"
#include <memory>
#include "LoginBlob.h"
#include "esp_log.h"
static const char *TAG = "spotify";
// Step 7.5b1: link check only. Zeroconf, login and audio follow in b2/b3.
extern "C" esp_err_t spotify_init(const char *device_name)
{
auto blob = std::make_shared<cspot::LoginBlob>(device_name);
std::string info = blob->buildZeroconfInfo();
ESP_LOGI(TAG, "cspot linked: device \"%s\", zeroconf info %u bytes", device_name, (unsigned)info.size());
return ESP_OK;
}