Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[portaudio] Update overlay to version v19.7.0+2023-04-04 #63

Merged
merged 9 commits into from
Apr 6, 2023
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 20 additions & 40 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,44 +21,7 @@ jobs:
# check_disk_space: df -h
env:
VCPKG_PACKAGES: >-
angle
chromaprint
fdk-aac
ffmpeg
fftw3
hidapi
hss1394
libebur128
libflac
libid3tag
libkeyfinder
libmad
libmodplug
libogg
libopusenc
libshout
libsndfile
libusb
libvorbis
lilv
mp3lame
opus
opusfile
portaudio[asio]
portmidi
protobuf
pthreads
qt5-base
qt5-declarative
qt5-script
qt5-svg
qt5-translations
qt5-winextras
qtkeychain
rubberband
soundtouch
taglib
wavpack
VCPKG_DEFAULT_TRIPLET: ${{ matrix.vcpkg_triplet }}
VCPKG_OVERLAY_PORTS: overlay/ports
DEPS_BASE_NAME: mixxx-deps
Expand Down Expand Up @@ -96,8 +59,8 @@ jobs:
- name: Check available disk space
run: ${{ matrix.check_disk_space }}

- name: Upgrade packages in cache
run: ./vcpkg upgrade --no-dry-run
- name: Remove outdated packages from cache
run: ./vcpkg remove --vcpkg-root=${{ matrix.vcpkg_path }} --outdated --recurse
working-directory: ${{ matrix.vcpkg_path }}

- name: Build packages
Expand All @@ -112,7 +75,24 @@ jobs:
path: ${{ matrix.vcpkg_path }}/buildtrees/**/*.log

- name: Create buildenv archive
run: ./vcpkg export ${{ env.VCPKG_PACKAGES }} --zip --output=${{ env.DEPS_BASE_NAME }}-${{ env.MIXXX_VERSION }}-${{ matrix.vcpkg_triplet }}-${{ steps.vars.outputs.sha_short }}
run: ./vcpkg export ${{ env.VCPKG_PACKAGES }} --raw --output=${{ env.DEPS_BASE_NAME }}-${{ env.MIXXX_VERSION }}-${{ matrix.vcpkg_triplet }}-${{ steps.vars.outputs.sha_short }}
working-directory: ${{ matrix.vcpkg_path }}

- name: Download ${{ env.DEPS_BASE_NAME }}
id: download-file
uses: carlosperate/download-file-action@v2
with:
file-url: 'https://downloads.mixxx.org/dependencies/2.3/Windows/mixxx-deps-2.3-x64-windows-049b5ad.zip'
sha256: '82c49c82f54989cca0b35ab331afcb5fed486e929464beeede321583a778940a'

- name: Inegrate ${{ env.DEPS_BASE_NAME }}
if: ${{ steps.cache.outputs.cache-matched-key == null }}
run: |
cmake -E tar xv ${{ steps.download-file.outputs.file-path }}
cmake -E copy_directory ${{ env.DEPS_BASE_NAME }}-${{ env.MIXXX_VERSION }}-${{ matrix.vcpkg_triplet }}-${{ steps.vars.outputs.sha_short }} mixxx-deps-2.3-x64-windows-049b5ad
cmake -E rm -r ${{ env.DEPS_BASE_NAME }}-${{ env.MIXXX_VERSION }}-${{ matrix.vcpkg_triplet }}-${{ steps.vars.outputs.sha_short }}
cmake -E rename mixxx-deps-2.3-x64-windows-049b5ad ${{ env.DEPS_BASE_NAME }}-${{ env.MIXXX_VERSION }}-${{ matrix.vcpkg_triplet }}-${{ steps.vars.outputs.sha_short }}
cmake -E tar cfv ${{ env.DEPS_BASE_NAME }}-${{ env.MIXXX_VERSION }}-${{ matrix.vcpkg_triplet }}-${{ steps.vars.outputs.sha_short }}.zip --format=zip ${{ env.DEPS_BASE_NAME }}-${{ env.MIXXX_VERSION }}-${{ matrix.vcpkg_triplet }}-${{ steps.vars.outputs.sha_short }}
working-directory: ${{ matrix.vcpkg_path }}

- name: "[Windows] Install additional tools"
Expand Down
33 changes: 33 additions & 0 deletions overlay/ports/jack2/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
cmake_minimum_required(VERSION 3.1)
project(jack VERSION 1.9 LANGUAGES C)

include_directories(common)

add_library(jack common/JackWeakAPI.c)
if(WIN32 AND BUILD_SHARED_LIBS)
target_sources(jack PRIVATE jack.def)
endif()
target_link_libraries(jack PRIVATE ${CMAKE_DL_LIBS})

include(GNUInstallDirs)
install(TARGETS jack
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}"
RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}"
)

set(PREFIX "${CMAKE_INSTALL_PREFIX}")
set(LIBDIR "\${prefix}/${CMAKE_INSTALL_LIBDIR}")
set(INCLUDEDIR "\${prefix}/${CMAKE_INSTALL_INCLUDEDIR}")
set(JACK_VERSION "${CMAKE_PROJECT_VERSION}")
# JackWeak dynamically loads the real JACK library which requires linking CMAKE_DL_LIBS
if(CMAKE_DL_LIBS)
set(CLIENTLIB "jack -l${CMAKE_DL_LIBS}")
else()
set(CLIENTLIB "jack")
endif()
# NOTE: the server_libs variable will be broken but this port does not build the server anyway
configure_file(jack.pc.in "${CMAKE_CURRENT_BINARY_DIR}/jack.pc" @ONLY)
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/jack.pc" DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig")

install(DIRECTORY "common/jack" DESTINATION "include")
96 changes: 96 additions & 0 deletions overlay/ports/jack2/jack.def
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
LIBRARY JACK

EXPORTS

;FIXME these are unimplemented
;jack_port_uuid
;jack_get_cycle_times

jack_get_version
jack_get_version_string
jack_client_open
jack_client_new
jack_client_close
jack_client_name_size
jack_get_client_name
jack_get_uuid_for_client_name
jack_get_client_name_by_uuid
jack_internal_client_new
jack_internal_client_close
jack_activate
jack_deactivate
jack_client_thread_id
jack_is_realtime
jack_thread_wait
jack_cycle_wait
jack_cycle_signal
jack_set_process_thread
jack_set_thread_init_callback
jack_on_shutdown
jack_on_info_shutdown
jack_set_process_callback
jack_set_freewheel_callback
jack_set_buffer_size_callback
jack_set_sample_rate_callback
jack_set_client_registration_callback
jack_set_port_registration_callback
jack_set_port_connect_callback
jack_set_port_rename_callback
jack_set_graph_order_callback
jack_set_xrun_callback
jack_set_latency_callback
jack_set_freewheel
jack_set_buffer_size
jack_get_sample_rate
jack_get_buffer_size
jack_engine_takeover_timebase
jack_cpu_load
jack_port_register
jack_port_unregister
jack_port_get_buffer
jack_port_name
jack_port_short_name
jack_port_flags
jack_port_type
jack_port_type_id
jack_port_is_mine
jack_port_connected
jack_port_connected_to
jack_port_get_connections
jack_port_get_all_connections
jack_port_tie
jack_port_untie
jack_port_set_name
jack_port_rename
jack_port_set_alias
jack_port_unset_alias
jack_port_get_aliases
jack_port_request_monitor
jack_port_request_monitor_by_name
jack_port_ensure_monitor
jack_port_monitoring_input
jack_connect
jack_disconnect
jack_port_disconnect
jack_port_name_size
jack_port_type_size
jack_port_type_get_buffer_size
jack_port_set_latency
jack_port_get_latency_range
jack_port_set_latency_range
jack_recompute_total_latencies
jack_port_get_latency
jack_port_get_total_latency
jack_recompute_total_latency
jack_get_ports
jack_port_by_name
jack_port_by_id
jack_frames_since_cycle_start
jack_frame_time
jack_last_frame_time
jack_frames_to_time
jack_time_to_frames
jack_get_time
jack_set_error_function
jack_set_info_function
jack_free
25 changes: 25 additions & 0 deletions overlay/ports/jack2/portfile.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO jackaudio/jack2
REF v1.9.21
SHA512 0e9ce581fca3c5d9ffb1de22b45cae6d94085c6f92ff3554892e25727baf66a2269f10d338d95d991e8380c4be5e0cc1e1453b9f878c7dc2e8a990f3bd458557
HEAD_REF master
)

# Install headers and a shim library with JackWeakAPI.c
file(COPY
"${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt"
"${CMAKE_CURRENT_LIST_DIR}/jack.def"
DESTINATION "${SOURCE_PATH}"
)

vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
)

vcpkg_cmake_install()
vcpkg_fixup_pkgconfig()

file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")

file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
18 changes: 18 additions & 0 deletions overlay/ports/jack2/vcpkg.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"name": "jack2",
"version-semver": "1.9.21",
"description": "Cross-platform API that enables device sharing and inter-application audio routing",
"homepage": "https://jackaudio.org/",
"license": "GPL-2.0",
"supports": "!uwp",
"dependencies": [
{
"name": "vcpkg-cmake",
"host": true
},
{
"name": "vcpkg-cmake-config",
"host": true
}
]
}
82 changes: 82 additions & 0 deletions overlay/ports/pkgconf/portfile.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO pkgconf/pkgconf
REF cef30268e1a3f79efd607c26abcf556aa314c9c4
SHA512 ea03b81d01521201bdc471a39cdc8b13f9452f7cc78706d5c57056595f3e4e8a3562c022ebb72ce6444f2c7a8dfc778114814ef5064eaef770a70cc294c7f7ee
HEAD_REF master
)

vcpkg_configure_meson(
SOURCE_PATH "${SOURCE_PATH}"
NO_PKG_CONFIG
OPTIONS -Dtests=false
)

set(systemsuffix "")
set(architectureprefix "")

set(SYSTEM_LIBDIR "")
set(PKG_DEFAULT_PATH "")
set(SYSTEM_INCLUDEDIR "")
set(PERSONALITY_PATH "personality.d")


if(NOT VCPKG_TARGET_IS_WINDOWS AND NOT VCPKG_CROSSCOMPILING AND VCPKG_TARGET_ARCHITECTURE MATCHES "x64")
# These defaults are obtained from pkgconf/pkg-config on Ubuntu and OpenSuse
# vcpkg cannot do system introspection to obtain/set these values since it would break binary caching.
set(SYSTEM_INCLUDEDIR "/usr/include")
# System lib dirs will be stripped from -L from the pkg-config output
set(SYSTEM_LIBDIR "/lib:/lib/i386-linux-gnu:/lib/x86_64-linux-gnu:/lib/x86_64-linux-gnux32:/lib64:/lib32:/libx32:/usr/lib:/usr/lib/i386-linux-gnu:/usr/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnux32:/usr/lib64:/usr/lib32:/usr/libx32")
set(PKG_DEFAULT_PATH "/usr/local/lib/x86_64-linux-gnu/pkgconfig:/usr/local/lib64/pkgconfig:/usr/local/lib/pkgconfig:/usr/local/share/pkgconfig:/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib64/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig")
set(PERSONALITY_PATH "/usr/share/pkgconfig/personality.d:/etc/pkgconfig/personality.d")
endif()

if(DEFINED VCPKG_pkgconf_SYSTEM_LIBDIR)
set(SYSTEM_LIBDIR "${VCPKG_pkgconf_SYSTEM_LIBDIR}")
endif()
if(DEFINED VCPKG_pkgconf_PKG_DEFAULT_PATH)
set(PKG_DEFAULT_PATH "${VCPKG_pkgconf_PKG_DEFAULT_PATH}")
endif()
if(DEFINED VCPKG_pkgconf_SYSTEM_INCLUDEDIR)
set(SYSTEM_INCLUDEDIR "${VCPKG_pkgconf_SYSTEM_INCLUDEDIR}")
endif()
if(DEFINED VCPKG_pkgconf_PERSONALITY_PATH)
set(PERSONALITY_PATH "${VCPKG_pkgconf_PERSONALITY_PATH}")
endif()


set(pkgconfig_file "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/libpkgconf/config.h")
if(EXISTS "${pkgconfig_file}")
file(READ "${pkgconfig_file}" contents)
string(REGEX REPLACE "#define PKG_DEFAULT_PATH [^\n]+" "#define PKG_DEFAULT_PATH \"${PKG_DEFAULT_PATH}\"" contents "${contents}")
string(REGEX REPLACE "#define SYSTEM_INCLUDEDIR [^\n]+" "#define SYSTEM_INCLUDEDIR \"${SYSTEM_INCLUDEDIR}\"" contents "${contents}")
string(REGEX REPLACE "#define SYSTEM_LIBDIR [^\n]+" "#define SYSTEM_LIBDIR \"${SYSTEM_LIBDIR}\"" contents "${contents}")
string(REGEX REPLACE "#define PERSONALITY_PATH [^\n]+" "#define PERSONALITY_PATH \"${PERSONALITY_PATH}\"" contents "${contents}")
file(WRITE "${pkgconfig_file}" "${contents}")
endif()
set(pkgconfig_file "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/libpkgconf/config.h")
if(EXISTS "${pkgconfig_file}")
file(READ "${pkgconfig_file}" contents)
string(REGEX REPLACE "#define PKG_DEFAULT_PATH [^\n]+" "#define PKG_DEFAULT_PATH \"${PKG_DEFAULT_PATH}\"" contents "${contents}")
string(REGEX REPLACE "#define SYSTEM_INCLUDEDIR [^\n]+" "#define SYSTEM_INCLUDEDIR \"${SYSTEM_INCLUDEDIR}\"" contents "${contents}")
string(REGEX REPLACE "#define SYSTEM_LIBDIR [^\n]+" "#define SYSTEM_LIBDIR \"${SYSTEM_LIBDIR}\"" contents "${contents}")
string(REGEX REPLACE "#define PERSONALITY_PATH [^\n]+" "#define PERSONALITY_PATH \"${PERSONALITY_PATH}\"" contents "${contents}")
file(WRITE "${pkgconfig_file}" "${contents}")
endif()

vcpkg_install_meson()
vcpkg_fixup_pkgconfig(SKIP_CHECK)

file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/share/doc")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/share/man")

if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/include/pkgconf/libpkgconf/libpkgconf-api.h" "#if defined(PKGCONFIG_IS_STATIC)" "#if 1")
endif()

vcpkg_copy_tools(TOOL_NAMES pkgconf AUTO_CLEAN)

# Handle copyright
file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
14 changes: 14 additions & 0 deletions overlay/ports/pkgconf/vcpkg.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"name": "pkgconf",
"version": "1.8.0",
"port-version": 3,
"description": "pkgconf is a program which helps to configure compiler and linker flags for development libraries. It is similar to pkg-config from freedesktop.org.",
"homepage": "https://github.com/pkgconf/pkgconf",
"supports": "!uwp",
"dependencies": [
{
"name": "vcpkg-tool-meson",
"host": true
}
]
}
Loading