Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
18 changes: 13 additions & 5 deletions tur-pypi-312/python3.12-polars/arboard-dummy-platform.diff
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ https://github.com/1Password/arboard/pull/50
/// The native clipboard is not accessible due to being held by an other party.
--- /dev/null
+++ b/src/platform/dummy.rs
@@ -0,0 +1,78 @@
@@ -0,0 +1,86 @@
+/*
+SPDX-License-Identifier: Apache-2.0 OR MIT
+
Expand All @@ -25,7 +25,7 @@ https://github.com/1Password/arboard/pull/50
+use crate::common::Error;
+#[cfg(feature = "image-data")]
+use crate::common::ImageData;
+use std::borrow::Cow;
+use std::{borrow::Cow, path::PathBuf};
+
+pub(crate) struct Clipboard { }
+
Expand All @@ -52,6 +52,14 @@ https://github.com/1Password/arboard/pull/50
+ pub(crate) fn image(self) -> Result<ImageData<'static>, Error> {
+ Err(Error::ContentNotAvailable)
+ }
+
+ pub(crate) fn html(self) -> Result<String, Error> {
+ Err(Error::ContentNotAvailable)
+ }
+
+ pub(crate) fn file_list(self) -> Result<Vec<PathBuf>, Error> {
+ Err(Error::ContentNotAvailable)
+ }
+}
+
+pub(crate) struct Set<'clipboard> {
Expand All @@ -63,16 +71,16 @@ https://github.com/1Password/arboard/pull/50
+ Self { clipboard }
+ }
+
+ pub(crate) fn text(self, data: Cow<'_, str>) -> Result<(), Error> {
+ pub(crate) fn text(self, _data: Cow<'_, str>) -> Result<(), Error> {
+ Err(Error::ClipboardNotSupported)
+ }
+
+ pub(crate) fn html(self, html: Cow<'_, str>, alt: Option<Cow<'_, str>>) -> Result<(), Error> {
+ pub(crate) fn html(self, _html: Cow<'_, str>, _alt: Option<Cow<'_, str>>) -> Result<(), Error> {
+ Err(Error::ClipboardNotSupported)
+ }
+
+ #[cfg(feature = "image-data")]
+ pub(crate) fn image(self, data: ImageData) -> Result<(), Error> {
+ pub(crate) fn image(self, _data: ImageData) -> Result<(), Error> {
+ Err(Error::ClipboardNotSupported)
+ }
+}
Expand Down
22 changes: 12 additions & 10 deletions tur-pypi-312/python3.12-polars/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ TERMUX_PKG_HOMEPAGE=https://github.com/pola-rs/polars
TERMUX_PKG_DESCRIPTION="Dataframes powered by a multithreaded, vectorized query engine, written in Rust"
TERMUX_PKG_LICENSE="MIT"
TERMUX_PKG_MAINTAINER="@termux-user-repository"
TERMUX_PKG_VERSION="1.29.0"
TERMUX_PKG_VERSION="1.30.0"
TERMUX_PKG_SRCURL=https://github.com/pola-rs/polars/releases/download/py-$TERMUX_PKG_VERSION/polars-$TERMUX_PKG_VERSION.tar.gz
TERMUX_PKG_SHA256=d2acb71fce1ff0ea76db5f648abd91a7a6c460fafabce9a2e8175184efa00d02
TERMUX_PKG_SHA256=dfe94ae84a5efd9ba74e616e3e125b24ca155494a931890a8f17480737c4db45
TERMUX_PKG_AUTO_UPDATE=true
TERMUX_PKG_DEPENDS="libc++, python"
TERMUX_PKG_PYTHON_COMMON_DEPS="wheel"
Expand All @@ -30,18 +30,15 @@ source $TERMUX_SCRIPTDIR/common-files/tur_build_wheel.sh
termux_pkg_auto_update() {
# Get latest release tag:
local api_url="https://api.github.com/repos/pola-rs/polars/git/refs/tags"
local latest_refs_tags=$(curl -s "${api_url}" | jq .[].ref | grep -oP py-${TERMUX_PKG_UPDATE_VERSION_REGEXP} | sort -V)
local latest_refs_tags=$(
curl -s "$api_url" | jq -r .[].ref | cut -d'/' -f 3 |
grep "py-" | grep -v -E "(rc)|(alpha)|(beta)"
)
if [[ -z "${latest_refs_tags}" ]]; then
echo "WARN: Unable to get latest refs tags from upstream. Try again later." >&2
return
fi

local latest_version="$(echo "${latest_refs_tags}" | tail -n1 | cut -c 4-)"
if [[ "${latest_version}" == "${TERMUX_PKG_VERSION}" ]]; then
echo "INFO: No update needed. Already at version '${TERMUX_PKG_VERSION}'."
return
fi

local latest_version="$(echo "${latest_refs_tags}" | sort -V | tail -n1)"
termux_pkg_upgrade_version "${latest_version}"
}

Expand All @@ -61,6 +58,11 @@ termux_step_pre_configure() {
touch "${TERMUX_PKG_BUILDDIR}/android.toolchain.cmake"

cargo vendor
find ./vendor \
-mindepth 1 -maxdepth 1 -type d \
! -wholename ./vendor/arboard \
-exec rm -rf '{}' \;

patch --silent -p1 \
-d ./vendor/arboard/ \
< "$TERMUX_PKG_BUILDER_DIR"/arboard-dummy-platform.diff
Expand Down