diff --git a/.github/workflows/cppcmake.yml b/.github/workflows/cppcmake.yml index 4a10df7..be5da82 100644 --- a/.github/workflows/cppcmake.yml +++ b/.github/workflows/cppcmake.yml @@ -20,13 +20,8 @@ jobs: matrix: config: - { name: "ubuntu-latest", os: ubuntu-latest, cmake_extra: "" } - - { name: "windows-x64", os: windows-latest, cmake_extra: "-T v143" } - - { - name: "windows-x32", - os: windows-latest, - cmake_extra: "-T v143 -A Win32", - } - - { name: "macOS-latest", os: macos-latest, cmake_extra: "" } + - { name: "windows-latest", os: windows-latest, cmake_extra: "-T v143" } + - { name: "macos-latest", os: macos-latest, cmake_extra: "" } fail-fast: false steps: @@ -65,6 +60,16 @@ jobs: permissions: contents: write steps: + - name: Validate tag format + shell: bash + env: + TAG: ${{ github.ref_name }} + run: | + if [[ ! "$TAG" =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]]; then + echo "::error::Tag '$TAG' does not match the required vX.Y.Z format" + exit 1 + fi + - name: Download Artifacts uses: actions/download-artifact@v8 diff --git a/.gitignore b/.gitignore index 24b3246..6d77c22 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,3 @@ -xdf.pro.user CMakeCache.txt CMakeFiles Makefile @@ -6,9 +5,15 @@ cmake_install.cmake CMakeLists.txt.user CMakeSettings.json *.a +*.o +*.obj +*.so +*.dll +*.lib *.dylib /build /out /.vs +/.vscode /cmake-build-debug /.idea diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..b45b7fd --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,102 @@ +## [UNRELEASED] Β· YYYY-MM-DD + +### πŸ”§ Fixed +- Read all channels of multi-channel string streams instead of only the first, which previously misaligned the file cursor and corrupted subsequent reads ([#58](https://github.com/xdf-modules/libxdf/pull/58) by [Alberto Barradas](https://github.com/abcsds)) + +## [0.99.10] Β· 2026-03-20 +### πŸ”§ Fixed +- Do not segfault when loading an XDF file with no data (only clock sync values) ([#42](https://github.com/xdf-modules/libxdf/pull/42) by [WesselVS](https://github.com/WesselVS)) + +### πŸŒ€ Changed +- Bump the required C++ standard to C++17 in `xdf.pro` ([#44](https://github.com/xdf-modules/libxdf/pull/44) by [Yida Lin](https://github.com/Yida-Lin)) +- Bump the minimum macOS deployment target ([#48](https://github.com/xdf-modules/libxdf/pull/48) by [Clemens Brunner](https://github.com/cbrnr)) +- Reformat `CMakeLists.txt` and bump the minimum required CMake version ([#50](https://github.com/xdf-modules/libxdf/pull/50) by [Clemens Brunner](https://github.com/cbrnr)) +- Bump bundled pugixml to 1.15 ([#51](https://github.com/xdf-modules/libxdf/pull/51) by [Clemens Brunner](https://github.com/cbrnr)) +- Improve and simplify the README ([#52](https://github.com/xdf-modules/libxdf/pull/52) by [Clemens Brunner](https://github.com/cbrnr)) + +### πŸ—‘οΈ Removed +- Remove unused cruft from the repository ([#53](https://github.com/xdf-modules/libxdf/pull/53) by [Clemens Brunner](https://github.com/cbrnr)) +- Remove a dysfunctional documentation link ([#55](https://github.com/xdf-modules/libxdf/pull/55) by [Clemens Brunner](https://github.com/cbrnr)) + +## [0.99.9] Β· 2024-08-25 +### πŸ”§ Fixed +- Include `` to fix builds with strict standard library implementations ([#37](https://github.com/xdf-modules/libxdf/pull/37) by [Gijom](https://github.com/Gijom)) +- Fix missing pugixml dependency in the generated CMake package config file ([#38](https://github.com/xdf-modules/libxdf/pull/38) by [myd7349](https://github.com/myd7349)) +- Fix a typo that leaked into the compiled binary ([#40](https://github.com/xdf-modules/libxdf/pull/40) by [Γ‰tienne Mollier](https://github.com/emollier)) +- Fix a potentially uninitialized variable ([#41](https://github.com/xdf-modules/libxdf/pull/41) by [Antoine Bonnier](https://github.com/antoine21839)) + +### πŸŒ€ Changed +- Update the CI workflow ([#39](https://github.com/xdf-modules/libxdf/pull/39) by [myd7349](https://github.com/myd7349)) + +## [0.99.8] Β· 2021-09-29 +*(v0.99.7, published the day before, had a version-number mismatch and was immediately superseded by this release.)* + +### πŸ”§ Fixed +- Install exported CMake targets to `libdir/cmake/libxdf` ([#32](https://github.com/xdf-modules/libxdf/pull/32) by [Juhani Numminen](https://github.com/jnumm)) + +### πŸŒ€ Changed +- Update the minimum required macOS version to 10.13 ([#33](https://github.com/xdf-modules/libxdf/pull/33) by [Clemens Brunner](https://github.com/cbrnr)) +- Rename the `master` branch to `main` in the CI workflow ([#36](https://github.com/xdf-modules/libxdf/pull/36) by [Yida Lin](https://github.com/Yida-Lin)) + +## [0.99.6] Β· 2020-11-12 +### ✨ Added +- Add a GitHub Actions workflow to automatically build, package, and publish releases ([#31](https://github.com/xdf-modules/libxdf/pull/31) by [Chadwick Boulay](https://github.com/cboulay)) + +## [0.991] Β· 2020-11-11 +### ✨ Added +- Add a reference to the README ([#30](https://github.com/xdf-modules/libxdf/pull/30) by [Yida Lin](https://github.com/Yida-Lin)) + +### πŸ”§ Fixed +- Fix a bug where minimum/maximum time stamps could be read as NaN ([#23](https://github.com/xdf-modules/libxdf/pull/23) by [Yida Lin](https://github.com/Yida-Lin)) +- Fix the return type of `readLength()` ([#22](https://github.com/xdf-modules/libxdf/pull/22) by [Yida Lin](https://github.com/Yida-Lin)) + +### πŸŒ€ Changed +- Wrap raw `ifstream::read()` calls in a helper function to avoid error-prone size arguments ([#18](https://github.com/xdf-modules/libxdf/pull/18) by [Tristan Stenner](https://github.com/tstenner)) +- Various CMake build script improvements ([#20](https://github.com/xdf-modules/libxdf/pull/20) and [#21](https://github.com/xdf-modules/libxdf/pull/21) by [Tristan Stenner](https://github.com/tstenner)) +- Change the license from GPL-3.0 to BSD-2, and update authors and copyright year ([#29](https://github.com/xdf-modules/libxdf/pull/29) by [Yida Lin](https://github.com/Yida-Lin)) + +## [0.99] Β· 2019-03-21 +### πŸ”§ Fixed +- Correctly compute the major sample rate when a recording only contains streams with a variable sampling rate ([#16](https://github.com/xdf-modules/libxdf/pull/16) by [Rene Maget](https://github.com/rstdm)) +- Synchronize samples that occur before the first clock synchronization value, avoiding huge (and sometimes crash-inducing) memory allocations caused by an incorrectly inflated recording duration ([#16](https://github.com/xdf-modules/libxdf/pull/16) by [Rene Maget](https://github.com/rstdm)) + +## [0.98] Β· 2018-07-12 +### ✨ Added +- Add support for synchronizing time stamps across streams (by [Yida Lin](https://github.com/Yida-Lin)) + +## [0.96] Β· 2017-08-02 +### ✨ Added +- Add support for building both a static and a shared library ([#15](https://github.com/xdf-modules/libxdf/pull/15) by [Clemens Brunner](https://github.com/cbrnr)) + +## [0.95] Β· 2017-08-02 +### ✨ Added +- Add a vector to store the effective sample rate of each stream (by [Yida Lin](https://github.com/Yida-Lin)) +- Add a CMake build in addition to qmake ([#10](https://github.com/xdf-modules/libxdf/pull/10) by [Clemens Brunner](https://github.com/cbrnr)) +- Add a minimum macOS deployment target ([#14](https://github.com/xdf-modules/libxdf/pull/14) by [Clemens Brunner](https://github.com/cbrnr)) + +### πŸ”§ Fixed +- Remove compiler warnings ([#9](https://github.com/xdf-modules/libxdf/pull/9) by [Clemens Brunner](https://github.com/cbrnr)) + +### πŸŒ€ Changed +- Update the README ([#11](https://github.com/xdf-modules/libxdf/pull/11) by [Clemens Brunner](https://github.com/cbrnr)) + +## [0.94] Β· 2017-04-13 +### πŸŒ€ Changed +- Switch to 1-based channel numbering in the user interface (by [Yida Lin](https://github.com/Yida-Lin)) + +## [0.93] Β· 2017-03-28 +### πŸ”§ Fixed +- Fix several bugs (by [Yida Lin](https://github.com/Yida-Lin)) +- Remove remaining `malloc.h` includes ([#5](https://github.com/xdf-modules/libxdf/pull/5) by [Clemens Brunner](https://github.com/cbrnr)) +- Fix compiler warnings ([#6](https://github.com/xdf-modules/libxdf/pull/6) by [Clemens Brunner](https://github.com/cbrnr)) + +### πŸŒ€ Changed +- Use `double` instead of `float` for time stamps (by [Yida Lin](https://github.com/Yida-Lin)) +- Explicitly enable C99 ([#7](https://github.com/xdf-modules/libxdf/pull/7) by [Clemens Brunner](https://github.com/cbrnr)) + +## [0.92] Β· 2017-02-10 +### ✨ Added +- Initial public release of libXDF, distributed as both prebuilt binaries and source code, for use with [SigViewer](https://github.com/cbrnr/sigviewer) (by [Yida Lin](https://github.com/Yida-Lin)) + +### πŸ”§ Fixed +- Switch the build system to CMake and fix a `malloc.h` build issue ([#3](https://github.com/xdf-modules/libxdf/pull/3) by [Clemens Brunner](https://github.com/cbrnr)) diff --git a/CHANGELOG.txt b/CHANGELOG.txt deleted file mode 100644 index b9c5ea8..0000000 --- a/CHANGELOG.txt +++ /dev/null @@ -1,5 +0,0 @@ -# Changelog - -## [0.992] - 2020-11-11 -### Added -- GitHub Actions for automatic build on pull requests to master and automatic build and release on tags. diff --git a/LICENSE.txt b/LICENSE similarity index 100% rename from LICENSE.txt rename to LICENSE diff --git a/README.md b/README.md index 149b0eb..c3536f15 100644 --- a/README.md +++ b/README.md @@ -76,7 +76,7 @@ Releases are built and published automatically by [.github/workflows/cppcmake.ym git tag vX.Y.Z git push origin vX.Y.Z ``` -5. CI builds, packages, and publishes the release automatically β€” check the Actions and Releases tabs to confirm it succeeded. +5. CI builds, packages, and publishes the release automatically β€” check the Actions and Releases tabs to confirm it succeeded. The release step rejects any tag that does not match `vX.Y.Z` (e.g. `v0.99.11`), so no release is created if the tag format is wrong. ## References diff --git a/xdf.pro b/xdf.pro deleted file mode 100644 index 6cfccf9..0000000 --- a/xdf.pro +++ /dev/null @@ -1,36 +0,0 @@ -QT -= gui - -TARGET = xdf -TEMPLATE = lib -CONFIG += c++17 shared_and_static build_all -INCLUDEPATH += pugixml - -QMAKE_CFLAGS += -std=c99 - -SOURCES += xdf.cpp \ - smarc/filtering.c \ - smarc/multi_stage.c \ - smarc/polyfilt.c \ - smarc/remez_lp.c \ - smarc/smarc.c \ - smarc/stage_impl.c \ - pugixml/pugixml.cpp - -HEADERS += xdf.h \ - smarc/filtering.h \ - smarc/multi_stage.h \ - smarc/polyfilt.h \ - smarc/remez_lp.h \ - smarc/smarc.h \ - smarc/stage_impl.h \ - pugixml/pugiconfig.hpp \ - pugixml/pugixml.hpp - -unix { - target.path = /usr/lib - INSTALLS += target -} - -macx { - QMAKE_MACOSX_DEPLOYMENT_TARGET = 11 -}