user/zotero: upgrade to 7.0.0_beta109

This commit is contained in:
Antoine Martin 2024-07-04 22:51:27 -04:00
parent 7671a9d567
commit 87e02ab716
8 changed files with 4302 additions and 143 deletions

View file

@ -1,18 +1,19 @@
# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
# Maintainer: Antoine Martin (ayakael) <dev@ayakael.net>
pkgname=zotero
pkgver=7.0.0_beta83
pkgver=7.0.0_beta109
pkgrel=0
_fxver=115.9.1
_gittag=$pkgver
# Date of release, YY-MM-DD for metainfo file (see package())
# https://www.mozilla.org/firefox/organizations/notes/
_releasedate=2024-06-03
_releasedate=2024-08-01
pkgdesc="A free, easy-to-use tool to help you collect, organize, cite, and share your research sources."
url="https://www.mozilla.org/en-US/firefox/organizations/"
# s390x and riscv64: blocked by rust and cargo
# armhf: build failure on armhf due to wasm
arch="x86_64 armv7 aarch64 x86 ppc64le"
# ppc64le: test suite stalls
arch="x86_64 armv7 aarch64 x86"
license="GPL-3.0-only AND LGPL-2.1-only AND LGPL-3.0-only AND MPL-2.0"
depends="
ffmpeg-libavcodec
@ -57,8 +58,6 @@ makedepends="
perl
pipewire-dev
pulseaudio-dev
py3-psutil
py3-zstandard
python3
rsync
sed
@ -77,12 +76,16 @@ source="https://ftp.mozilla.org/pub/firefox/releases/${_fxver}esr/source/firefox
fix-webrtc-glibcisms.patch
icu74.patch
lfs64.patch
llvm18-bindgen.patch
llvm18.patch
moz-system-jpeg.patch
no-ccache-stats.patch
nrappkit-qsort.patch
ppc-musttail.patch
ppc-webrtc.patch
python-deps.patch
rust-lto-thin.patch
https://dev.alpinelinux.org/archive/firefox/rust1.78-packed-to-portable_simd.patch
rust1.78-packed-to-portable_simd.patch
rust1.78-qcms-stdsimd.patch
sandbox-fork.patch
sandbox-largefile.patch
@ -95,12 +98,12 @@ source="https://ftp.mozilla.org/pub/firefox/releases/${_fxver}esr/source/firefox
vendor-prefs.js
zotero.desktop
zotero_drop-phantomjs.patch
https://lab.ilot.io/mirrors/zotero-client/-/releases/$_gittag/downloads/tarball/zotero-client-$_gittag.tar.gz
zotero_build-modifications.patch
zotero_test-drop-build.patch
zotero_test-fix-chars.patch
zotero_test-push-timeout-to-30sec.patch
zotero_drop-jazzer.patch
"
builddir="$srcdir"/firefox-$_fxver
@ -171,6 +174,7 @@ prepare() {
cp "$srcdir"/stab.h toolkit/crashreporter/google-breakpad/src/
_clear_vendor_checksums audio_thread_priority
_clear_vendor_checksums bindgen
base64 -d "$srcdir"/mozilla-location.keys > "$builddir"/mozilla-api-key
@ -372,7 +376,11 @@ cd68b89e29e5f6379fbd5679db27b9a5ef70ea65e51c0d0a8137e1f1fd210e35a8cfb047798e9549
305c874fdea3096e9c4c6aa6520ac64bb1c347c4b59db8360096646593fe684c3b5377874d91cecd33d56d1410b4714fbdea2b514923723ecbeff79d51265d9b fix-webrtc-glibcisms.patch
afabea91b328c5a68eaa20f9099ac7b2d0e7f2423e816b05ed168bdd326a5684fa02de08bf05c6033e9b888f02775d1b0443a00329b7a632ee399122a391c13a icu74.patch
5fa9382c692e4bd6a2634308f24a6526fd12a60a2563d2090056d43a60505df3ec9881bbf54562e69394467529b3b0dc45955afca46ed329af03cea074fff070 lfs64.patch
d7a9443cd81d3ef4a6baa1b5d05f2497bc07c1de815a4d85b613b734989e7c589019dd860ea2eb9e32067973efbfd1c913790c6c238778da23d76fbd904128d1 llvm18-bindgen.patch
8c4de34188f634833d99d17bc389c43ab9576b3f0581387407ae77f636a890779cd02786b632fbdfd8b0305575517d51b04f76b9aa3f1a94c3d822578286fc6f llvm18.patch
e28b1fe2967d46c888b41a0a03ee1b6de763124a0281b68aebac04ec3b76cb6fdb56a376d419a003fd87f79e9d086aafd4aaa24efa3345f9857352d3d489356f moz-system-jpeg.patch
c0437a6753f3f350968fa12d250efdfe1bea77baf0e4c06b072b5cc9e78c774dbf4506bc536337030d349fb3ba4460097b75b0c7c5b8fb2d39d8b0a392948936 no-ccache-stats.patch
b586ddb21b50fa8fba798c3a269518049c38cc52fd91ad00e96a3f1144e6b2879d9df1a182a2fb181898042043ae98381a70d0e4acbf8aa705d2b4f62c17a5a1 nrappkit-qsort.patch
2d8dff86212d6d2a904cbb5a5a1d6c17b89adc929fc6a3f4c6cb669f5e83ecddff5a799225319ba445a187b04d111251af75dd3ce8a039164bc14d2a432a2a04 ppc-musttail.patch
6f60e83599041db1b707c21784197ea9816b2c936b89a274bfc24554a600981e6f28448fe41fab0942bd31acd49b1c00beb2eb0961149f2ffa6a4154be123ea7 ppc-webrtc.patch
4e40b34c5f77a1a21fe971a6fcd8a21b1a63423a3a7932a5a6e1c7a2779f9f06a561c806614a01931679a4b1c6afdfd8ae1f3cc6b673f259ccd368e8e54f6e90 python-deps.patch
@ -387,10 +395,10 @@ d354f48a29bfc16719f3b230b1395063239d4420f9e47522de4662392d9697b15f931ca3bf6055d1
382510375b1a2fa79be0ab79e3391a021ae2c022429ffbaa7e7a69166f99bb56d01e59a1b10688592a29238f21c9d6977672bd77f9fae439b66bdfe0c55ddb15 mozilla-location.keys
fc45bc3ffb9404e5338ea26a9f04807b40f6f516324972cddd48bedb91b8bd7c6b8d4e03a0209020f5e67b703bc4ff89389985791b9bd544a0fc3951e2dc338e vendor-prefs.js
e1a0a4ff5cc1b53f13776ca11927d671426b0691e78e74a4adf2166d57bb2ae8ac409cc11a37ce5e2f680fdf05d5bc3849c33a9717aca1bb62d03ae5231a67fb zotero.desktop
abbcb92fe89029833bbfb15a8a65204c4043c8c9a372d1aa3d18756584cea32078238caded7f0099314228093b09ac10e18ac3c8ecb8138d30f57664c63f7f8a zotero_drop-phantomjs.patch
4b5125ae1cc235803e6f4eb89787c631b3b55c6b34263fe16aef4b2c371df28d9daf05d83a7e2fa36c05a2153585d674a23bec98e0488d9dc9eabe5f5924a873 zotero-client-7.0.0_beta83.tar.gz
da70afc3c7cd9c6d1547561f2e780fcd583a37f7aeaafb79b4e31257e3f319f88008ef7b8c7951607050a87710ca900abd4d9959d103427baf41b20798032cf9 zotero-client-7.0.0_beta109.tar.gz
746dbabbb3ea9199d17891e2079b9256d04843f548132178862117d2334694d98e2cc981945d72f31d0e5b2c42904d371633f6905996bb580aa0b5ae95c64ddc zotero_build-modifications.patch
337070ee4c44ccb35c6b6290c18327740bb9fccfd1a6ad1045782e83daa290b6ced7d53955d3a889f661d588738a64f2e7f383639f4c46be9fdf891168abc9ff zotero_test-drop-build.patch
f0e4f09496531222e8400959f9ef12852bca269eb3bf4c3b87ccaf92f28a12b9374461a1c79ad294a4393dbe30800aa1c85497033d0bc304fa8c198dfab3efd2 zotero_test-fix-chars.patch
9dc390d8bae42e645cae45fe5551751d8f38d5c1b8b2cc0eec1c2191f4bde293ffb2c67cfc4de765f2d48b1da4d5fcd4f1c03711e5da3180cd1b63710ccf5599 zotero_test-push-timeout-to-30sec.patch
eb6b6ccb8955adab541cb26cd3b378c7ab0e0cb50d8546413f086c924f50a07db99ea29f050a4744e46d81ee9be5cd6a4f32248f4205e4f6360856c98377b973 zotero_drop-jazzer.patch
"

View file

@ -0,0 +1,619 @@
Patch-Source: https://github.com/chimera-linux/cports/blob/899c997/contrib/thunderbird/patches/llvm18-bindgen.patch
https://github.com/rust-lang/rust-bindgen/pull/2689
--
diff --git a/ir/item.rs b/ir/item.rs
index 40f6f7d..87d09da 100644
--- a/third_party/rust/bindgen/ir/item.rs
+++ b/third_party/rust/bindgen/ir/item.rs
@@ -6,8 +6,8 @@ use super::annotations::Annotations;
use super::comp::{CompKind, MethodKind};
use super::context::{BindgenContext, ItemId, PartialType, TypeId};
use super::derive::{
- CanDeriveCopy, CanDeriveDebug, CanDeriveDefault, CanDeriveEq,
- CanDeriveHash, CanDeriveOrd, CanDerivePartialEq, CanDerivePartialOrd,
+ CanDeriveCopy, CanDeriveDebug, CanDeriveDefault, CanDeriveEq, CanDeriveHash, CanDeriveOrd,
+ CanDerivePartialEq, CanDerivePartialOrd,
};
use super::dot::DotAttributes;
use super::function::{Function, FunctionKind};
@@ -59,10 +59,7 @@ pub trait ItemCanonicalPath {
/// Get the namespace-aware canonical path for this item. This means that if
/// namespaces are disabled, you'll get a single item, and otherwise you get
/// the whole path.
- fn namespace_aware_canonical_path(
- &self,
- ctx: &BindgenContext,
- ) -> Vec<String>;
+ fn namespace_aware_canonical_path(&self, ctx: &BindgenContext) -> Vec<String>;
/// Get the canonical path for this item.
fn canonical_path(&self, ctx: &BindgenContext) -> Vec<String>;
@@ -159,11 +156,7 @@ where
{
type Extra = ();
- fn as_template_param(
- &self,
- ctx: &BindgenContext,
- _: &(),
- ) -> Option<TypeId> {
+ fn as_template_param(&self, ctx: &BindgenContext, _: &()) -> Option<TypeId> {
ctx.resolve_item((*self).into()).as_template_param(ctx, &())
}
}
@@ -171,11 +164,7 @@ where
impl AsTemplateParam for Item {
type Extra = ();
- fn as_template_param(
- &self,
- ctx: &BindgenContext,
- _: &(),
- ) -> Option<TypeId> {
+ fn as_template_param(&self, ctx: &BindgenContext, _: &()) -> Option<TypeId> {
self.kind.as_template_param(ctx, self)
}
}
@@ -183,16 +172,10 @@ impl AsTemplateParam for Item {
impl AsTemplateParam for ItemKind {
type Extra = Item;
- fn as_template_param(
- &self,
- ctx: &BindgenContext,
- item: &Item,
- ) -> Option<TypeId> {
+ fn as_template_param(&self, ctx: &BindgenContext, item: &Item) -> Option<TypeId> {
match *self {
ItemKind::Type(ref ty) => ty.as_template_param(ctx, item),
- ItemKind::Module(..) |
- ItemKind::Function(..) |
- ItemKind::Var(..) => None,
+ ItemKind::Module(..) | ItemKind::Function(..) | ItemKind::Var(..) => None,
}
}
}
@@ -214,10 +197,7 @@ impl<T> ItemCanonicalPath for T
where
T: Copy + Into<ItemId>,
{
- fn namespace_aware_canonical_path(
- &self,
- ctx: &BindgenContext,
- ) -> Vec<String> {
+ fn namespace_aware_canonical_path(&self, ctx: &BindgenContext) -> Vec<String> {
debug_assert!(
ctx.in_codegen_phase(),
"You're not supposed to call this yet"
@@ -282,9 +262,7 @@ impl Trace for Item {
// There are some types, like resolved type references, where we
// don't want to stop collecting types even though they may be
// opaque.
- if ty.should_be_traced_unconditionally() ||
- !self.is_opaque(ctx, &())
- {
+ if ty.should_be_traced_unconditionally() || !self.is_opaque(ctx, &()) {
ty.trace(ctx, tracer, self);
}
}
@@ -450,11 +428,7 @@ impl Item {
}
/// Construct a new opaque item type.
- pub fn new_opaque_type(
- with_id: ItemId,
- ty: &clang::Type,
- ctx: &mut BindgenContext,
- ) -> TypeId {
+ pub fn new_opaque_type(with_id: ItemId, ty: &clang::Type, ctx: &mut BindgenContext) -> TypeId {
let location = ty.declaration().location();
let ty = Opaque::from_clang_ty(ty, ctx);
let kind = ItemKind::Type(ty);
@@ -497,12 +471,11 @@ impl Item {
self.ancestors(ctx)
.filter(|id| {
ctx.resolve_item(*id).as_module().map_or(false, |module| {
- !module.is_inline() ||
- ctx.options().conservative_inline_namespaces
+ !module.is_inline() || ctx.options().conservative_inline_namespaces
})
})
- .count() +
- 1
+ .count()
+ + 1
}
/// Get this `Item`'s comment, if it has any, already preprocessed and with
@@ -577,9 +550,9 @@ impl Item {
pub fn is_toplevel(&self, ctx: &BindgenContext) -> bool {
// FIXME: Workaround for some types falling behind when parsing weird
// stl classes, for example.
- if ctx.options().enable_cxx_namespaces &&
- self.kind().is_module() &&
- self.id() != ctx.root_module()
+ if ctx.options().enable_cxx_namespaces
+ && self.kind().is_module()
+ && self.id() != ctx.root_module()
{
return false;
}
@@ -593,9 +566,7 @@ impl Item {
if parent_item.id() == ctx.root_module() {
return true;
- } else if ctx.options().enable_cxx_namespaces ||
- !parent_item.kind().is_module()
- {
+ } else if ctx.options().enable_cxx_namespaces || !parent_item.kind().is_module() {
return false;
}
@@ -656,15 +627,13 @@ impl Item {
let path = self.path_for_allowlisting(ctx);
let name = path[1..].join("::");
- ctx.options().blocklisted_items.matches(&name) ||
- match self.kind {
+ ctx.options().blocklisted_items.matches(&name)
+ || match self.kind {
ItemKind::Type(..) => {
- ctx.options().blocklisted_types.matches(&name) ||
- ctx.is_replaced_type(path, self.id)
- }
- ItemKind::Function(..) => {
- ctx.options().blocklisted_functions.matches(&name)
+ ctx.options().blocklisted_types.matches(&name)
+ || ctx.is_replaced_type(path, self.id)
}
+ ItemKind::Function(..) => ctx.options().blocklisted_functions.matches(&name),
// TODO: Add constant / namespace blocklisting?
ItemKind::Var(..) | ItemKind::Module(..) => false,
}
@@ -723,12 +692,7 @@ impl Item {
}
/// Helper function for full_disambiguated_name
- fn push_disambiguated_name(
- &self,
- ctx: &BindgenContext,
- to: &mut String,
- level: u8,
- ) {
+ fn push_disambiguated_name(&self, ctx: &BindgenContext, to: &mut String, level: u8) {
to.push_str(&self.canonical_name(ctx));
if let ItemKind::Type(ref ty) = *self.kind() {
if let TypeKind::TemplateInstantiation(ref inst) = *ty.kind() {
@@ -791,16 +755,14 @@ impl Item {
match *self.kind() {
ItemKind::Var(ref var) => var.name().to_owned(),
- ItemKind::Module(ref module) => {
- module.name().map(ToOwned::to_owned).unwrap_or_else(|| {
- format!("_bindgen_mod_{}", self.exposed_id(ctx))
- })
- }
- ItemKind::Type(ref ty) => {
- ty.sanitized_name(ctx).map(Into::into).unwrap_or_else(|| {
- format!("_bindgen_ty_{}", self.exposed_id(ctx))
- })
- }
+ ItemKind::Module(ref module) => module
+ .name()
+ .map(ToOwned::to_owned)
+ .unwrap_or_else(|| format!("_bindgen_mod_{}", self.exposed_id(ctx))),
+ ItemKind::Type(ref ty) => ty
+ .sanitized_name(ctx)
+ .map(Into::into)
+ .unwrap_or_else(|| format!("_bindgen_ty_{}", self.exposed_id(ctx))),
ItemKind::Function(ref fun) => {
let mut name = fun.name().to_owned();
@@ -839,11 +801,7 @@ impl Item {
/// If `BindgenOptions::disable_nested_struct_naming` is true then returned
/// name is the inner most non-anonymous name plus all the anonymous base names
/// that follows.
- pub fn real_canonical_name(
- &self,
- ctx: &BindgenContext,
- opt: &NameOptions,
- ) -> String {
+ pub fn real_canonical_name(&self, ctx: &BindgenContext, opt: &NameOptions) -> String {
let target = ctx.resolve_item(self.name_target(ctx));
// Short-circuit if the target has an override, and just use that.
@@ -874,9 +832,7 @@ impl Item {
})
.filter(|id| {
if !ctx.options().conservative_inline_namespaces {
- if let ItemKind::Module(ref module) =
- *ctx.resolve_item(*id).kind()
- {
+ if let ItemKind::Module(ref module) = *ctx.resolve_item(*id).kind() {
return !module.is_inline();
}
}
@@ -947,9 +903,9 @@ impl Item {
let ty_kind = self.kind().as_type().map(|t| t.kind());
if let Some(ty_kind) = ty_kind {
match *ty_kind {
- TypeKind::Comp(..) |
- TypeKind::TemplateInstantiation(..) |
- TypeKind::Enum(..) => return self.local_id(ctx).to_string(),
+ TypeKind::Comp(..) | TypeKind::TemplateInstantiation(..) | TypeKind::Enum(..) => {
+ return self.local_id(ctx).to_string()
+ }
_ => {}
}
}
@@ -990,8 +946,7 @@ impl Item {
match *type_.kind() {
TypeKind::Enum(ref enum_) => {
- enum_.computed_enum_variation(ctx, self) ==
- EnumVariation::ModuleConsts
+ enum_.computed_enum_variation(ctx, self) == EnumVariation::ModuleConsts
}
TypeKind::Alias(inner_id) => {
// TODO(emilio): Make this "hop through type aliases that aren't
@@ -1018,18 +973,12 @@ impl Item {
ItemKind::Type(_) => cc.types(),
ItemKind::Function(ref f) => match f.kind() {
FunctionKind::Function => cc.functions(),
- FunctionKind::Method(MethodKind::Constructor) => {
- cc.constructors()
- }
- FunctionKind::Method(MethodKind::Destructor) |
- FunctionKind::Method(MethodKind::VirtualDestructor {
- ..
- }) => cc.destructors(),
- FunctionKind::Method(MethodKind::Static) |
- FunctionKind::Method(MethodKind::Normal) |
- FunctionKind::Method(MethodKind::Virtual { .. }) => {
- cc.methods()
- }
+ FunctionKind::Method(MethodKind::Constructor) => cc.constructors(),
+ FunctionKind::Method(MethodKind::Destructor)
+ | FunctionKind::Method(MethodKind::VirtualDestructor { .. }) => cc.destructors(),
+ FunctionKind::Method(MethodKind::Static)
+ | FunctionKind::Method(MethodKind::Normal)
+ | FunctionKind::Method(MethodKind::Virtual { .. }) => cc.methods(),
},
}
}
@@ -1041,14 +990,9 @@ impl Item {
.borrow_with(|| self.compute_path(ctx, UserMangled::No))
}
- fn compute_path(
- &self,
- ctx: &BindgenContext,
- mangled: UserMangled,
- ) -> Vec<String> {
+ fn compute_path(&self, ctx: &BindgenContext, mangled: UserMangled) -> Vec<String> {
if let Some(path) = self.annotations().use_instead_of() {
- let mut ret =
- vec![ctx.resolve_item(ctx.root_module()).name(ctx).get()];
+ let mut ret = vec![ctx.resolve_item(ctx.root_module()).name(ctx).get()];
ret.extend_from_slice(path);
return ret;
}
@@ -1059,10 +1003,9 @@ impl Item {
.chain(iter::once(ctx.root_module().into()))
.map(|id| ctx.resolve_item(id))
.filter(|item| {
- item.id() == target.id() ||
- item.as_module().map_or(false, |module| {
- !module.is_inline() ||
- ctx.options().conservative_inline_namespaces
+ item.id() == target.id()
+ || item.as_module().map_or(false, |module| {
+ !module.is_inline() || ctx.options().conservative_inline_namespaces
})
})
.map(|item| {
@@ -1123,9 +1066,9 @@ impl IsOpaque for Item {
ctx.in_codegen_phase(),
"You're not supposed to call this yet"
);
- self.annotations.opaque() ||
- self.as_type().map_or(false, |ty| ty.is_opaque(ctx, self)) ||
- ctx.opaque_by_name(self.path_for_allowlisting(ctx))
+ self.annotations.opaque()
+ || self.as_type().map_or(false, |ty| ty.is_opaque(ctx, self))
+ || ctx.opaque_by_name(self.path_for_allowlisting(ctx))
}
}
@@ -1225,11 +1168,7 @@ impl HasFloat for Item {
pub type ItemSet = BTreeSet<ItemId>;
impl DotAttributes for Item {
- fn dot_attributes<W>(
- &self,
- ctx: &BindgenContext,
- out: &mut W,
- ) -> io::Result<()>
+ fn dot_attributes<W>(&self, ctx: &BindgenContext, out: &mut W) -> io::Result<()>
where
W: io::Write,
{
@@ -1306,17 +1245,10 @@ fn visit_child(
}
impl Item {
- pub(crate) fn builtin_type(
- kind: TypeKind,
- is_const: bool,
- ctx: &mut BindgenContext,
- ) -> TypeId {
+ pub(crate) fn builtin_type(kind: TypeKind, is_const: bool, ctx: &mut BindgenContext) -> TypeId {
// Feel free to add more here, I'm just lazy.
match kind {
- TypeKind::Void |
- TypeKind::Int(..) |
- TypeKind::Pointer(..) |
- TypeKind::Float(..) => {}
+ TypeKind::Void | TypeKind::Int(..) | TypeKind::Pointer(..) | TypeKind::Float(..) => {}
_ => panic!("Unsupported builtin type"),
}
@@ -1428,52 +1360,44 @@ impl Item {
}
// Guess how does clang treat extern "C" blocks?
- if cursor.kind() == CXCursor_UnexposedDecl {
- Err(ParseError::Recurse)
- } else {
+ match cursor.kind() {
+ // On Clang 18+, extern "C" is reported accurately as a LinkageSpec.
+ // Older LLVM treat it as UnexposedDecl.
+ CXCursor_LinkageSpec | CXCursor_UnexposedDecl => Err(ParseError::Recurse),
// We allowlist cursors here known to be unhandled, to prevent being
// too noisy about this.
- match cursor.kind() {
- CXCursor_MacroDefinition |
- CXCursor_MacroExpansion |
- CXCursor_UsingDeclaration |
- CXCursor_UsingDirective |
- CXCursor_StaticAssert |
- CXCursor_FunctionTemplate => {
- debug!(
- "Unhandled cursor kind {:?}: {:?}",
- cursor.kind(),
- cursor
- );
- }
- CXCursor_InclusionDirective => {
- let file = cursor.get_included_file_name();
- match file {
- None => {
- warn!(
- "Inclusion of a nameless file in {:?}",
- cursor
- );
- }
- Some(filename) => {
- ctx.include_file(filename);
- }
- }
- }
- _ => {
- // ignore toplevel operator overloads
- let spelling = cursor.spelling();
- if !spelling.starts_with("operator") {
- warn!(
- "Unhandled cursor kind {:?}: {:?}",
- cursor.kind(),
- cursor
- );
- }
- }
+ CXCursor_MacroDefinition
+ | CXCursor_MacroExpansion
+ | CXCursor_UsingDeclaration
+ | CXCursor_UsingDirective
+ | CXCursor_StaticAssert
+ | CXCursor_FunctionTemplate => {
+ debug!("Unhandled cursor kind {:?}: {:?}", cursor.kind(), cursor);
+ Err(ParseError::Continue)
}
- Err(ParseError::Continue)
+ CXCursor_InclusionDirective => {
+ let file = cursor.get_included_file_name();
+ match file {
+ None => {
+ warn!("Inclusion of a nameless file in {:?}", cursor);
+ }
+ Some(included_file) => {
+ for cb in &ctx.options().parse_callbacks {
+ cb.include_file(&included_file);
+ }
+ }
+ }
+ Err(ParseError::Continue)
+ }
+ _ => {
+ // ignore toplevel operator overloads
+ let spelling = cursor.spelling();
+ if !spelling.starts_with("operator") {
+ warn!("Unhandled cursor kind {:?}: {:?}", cursor.kind(), cursor);
+ }
+ Err(ParseError::Continue)
+ }
}
}
@@ -1511,22 +1435,11 @@ impl Item {
if ctx.collected_typerefs() {
debug!("refs already collected, resolving directly");
- return Item::from_ty_with_id(
- potential_id,
- &ty,
- location,
- parent_id,
- ctx,
- )
- .unwrap_or_else(|_| Item::new_opaque_type(potential_id, &ty, ctx));
+ return Item::from_ty_with_id(potential_id, &ty, location, parent_id, ctx)
+ .unwrap_or_else(|_| Item::new_opaque_type(potential_id, &ty, ctx));
}
- if let Some(ty) = ctx.builtin_or_resolved_ty(
- potential_id,
- parent_id,
- &ty,
- Some(location),
- ) {
+ if let Some(ty) = ctx.builtin_or_resolved_ty(potential_id, parent_id, &ty, Some(location)) {
debug!("{:?} already resolved: {:?}", ty, location);
return ty;
}
@@ -1586,12 +1499,10 @@ impl Item {
id, ty, location
);
- if ty.kind() == clang_sys::CXType_Unexposed ||
- location.cur_type().kind() == clang_sys::CXType_Unexposed
+ if ty.kind() == clang_sys::CXType_Unexposed
+ || location.cur_type().kind() == clang_sys::CXType_Unexposed
{
- if ty.is_associated_type() ||
- location.cur_type().is_associated_type()
- {
+ if ty.is_associated_type() || location.cur_type().is_associated_type() {
return Ok(Item::new_opaque_type(id, ty, ctx));
}
@@ -1618,8 +1529,7 @@ impl Item {
};
let comment = decl.raw_comment().or_else(|| location.raw_comment());
- let annotations =
- Annotations::new(&decl).or_else(|| Annotations::new(&location));
+ let annotations = Annotations::new(&decl).or_else(|| Annotations::new(&location));
if let Some(ref annotations) = annotations {
if let Some(replaced) = annotations.use_instead_of() {
@@ -1627,9 +1537,7 @@ impl Item {
}
}
- if let Some(ty) =
- ctx.builtin_or_resolved_ty(id, parent_id, ty, Some(location))
- {
+ if let Some(ty) = ctx.builtin_or_resolved_ty(id, parent_id, ty, Some(location)) {
return Ok(ty);
}
@@ -1665,9 +1573,7 @@ impl Item {
let result = Type::from_clang_ty(id, ty, location, parent_id, ctx);
let relevant_parent_id = parent_id.unwrap_or(current_module);
let ret = match result {
- Ok(ParseResult::AlreadyResolved(ty)) => {
- Ok(ty.as_type_id_unchecked())
- }
+ Ok(ParseResult::AlreadyResolved(ty)) => Ok(ty.as_type_id_unchecked()),
Ok(ParseResult::New(item, declaration)) => {
ctx.add_item(
Item::new(
@@ -1698,13 +1604,10 @@ impl Item {
assert_eq!(*finished.decl(), declaration_to_look_for);
}
- location.visit(|cur| {
- visit_child(cur, id, ty, parent_id, ctx, &mut result)
- });
+ location.visit(|cur| visit_child(cur, id, ty, parent_id, ctx, &mut result));
if valid_decl {
- let partial_ty =
- PartialType::new(declaration_to_look_for, id);
+ let partial_ty = PartialType::new(declaration_to_look_for, id);
ctx.begin_parsing(partial_ty);
}
@@ -1813,10 +1716,7 @@ impl Item {
// but maintaining these scopes properly would require more changes to
// the whole libclang -> IR parsing code.
- fn is_template_with_spelling(
- refd: &clang::Cursor,
- spelling: &str,
- ) -> bool {
+ fn is_template_with_spelling(refd: &clang::Cursor, spelling: &str) -> bool {
lazy_static! {
static ref ANON_TYPE_PARAM_RE: regex::Regex =
regex::Regex::new(r"^type\-parameter\-\d+\-\d+$").unwrap();
@@ -1838,11 +1738,7 @@ impl Item {
} else if location.kind() == clang_sys::CXCursor_TypeRef {
// Situation (2)
match location.referenced() {
- Some(refd)
- if is_template_with_spelling(&refd, &ty_spelling) =>
- {
- refd
- }
+ Some(refd) if is_template_with_spelling(&refd, &ty_spelling) => refd,
_ => return None,
}
} else {
@@ -1851,16 +1747,11 @@ impl Item {
location.visit(|child| {
let child_ty = child.cur_type();
- if child_ty.kind() == clang_sys::CXCursor_TypeRef &&
- child_ty.spelling() == ty_spelling
+ if child_ty.kind() == clang_sys::CXCursor_TypeRef
+ && child_ty.spelling() == ty_spelling
{
match child.referenced() {
- Some(refd)
- if is_template_with_spelling(
- &refd,
- &ty_spelling,
- ) =>
- {
+ Some(refd) if is_template_with_spelling(&refd, &ty_spelling) => {
definition = Some(refd);
return clang_sys::CXChildVisit_Break;
}
@@ -1883,12 +1774,7 @@ impl Item {
if let Some(id) = ctx.get_type_param(&definition) {
if let Some(with_id) = with_id {
- return Some(ctx.build_ty_wrapper(
- with_id,
- id,
- Some(parent),
- &ty,
- ));
+ return Some(ctx.build_ty_wrapper(with_id, id, Some(parent), &ty));
} else {
return Some(id);
}
@@ -1920,8 +1806,8 @@ impl ItemCanonicalName for Item {
);
self.canonical_name
.borrow_with(|| {
- let in_namespace = ctx.options().enable_cxx_namespaces ||
- ctx.options().disable_name_namespacing;
+ let in_namespace =
+ ctx.options().enable_cxx_namespaces || ctx.options().disable_name_namespacing;
if in_namespace {
self.name(ctx).within_namespaces().get()
@@ -1934,10 +1820,7 @@ impl ItemCanonicalName for Item {
}
impl ItemCanonicalPath for Item {
- fn namespace_aware_canonical_path(
- &self,
- ctx: &BindgenContext,
- ) -> Vec<String> {
+ fn namespace_aware_canonical_path(&self, ctx: &BindgenContext) -> Vec<String> {
let mut path = self.canonical_path(ctx);
// ASSUMPTION: (disable_name_namespacing && cxx_namespaces)

23
user/zotero/llvm18.patch Normal file
View file

@ -0,0 +1,23 @@
Patch-Source: https://github.com/chimera-linux/cports/blob/899c997/contrib/thunderbird/patches/llvm18.patch
--- a/dom/media/webrtc/libwebrtcglue/WebrtcGmpVideoCodec.cpp
+++ b/dom/media/webrtc/libwebrtcglue/WebrtcGmpVideoCodec.cpp
@@ -540,7 +540,7 @@
webrtc::VideoFrameType ft;
GmpFrameTypeToWebrtcFrameType(aEncodedFrame->FrameType(), &ft);
- uint32_t timestamp = (aEncodedFrame->TimeStamp() * 90ll + 999) / 1000;
+ uint64_t timestamp = (aEncodedFrame->TimeStamp() * 90ll + 999) / 1000;
GMP_LOG_DEBUG("GMP Encoded: %" PRIu64 ", type %d, len %d",
aEncodedFrame->TimeStamp(), aEncodedFrame->BufferType(),
--- a/dom/media/webrtc/libwebrtcglue/WebrtcGmpVideoCodec.h
+++ b/dom/media/webrtc/libwebrtcglue/WebrtcGmpVideoCodec.h
@@ -302,7 +302,7 @@
int64_t timestamp_us;
};
// Map rtp time -> input image data
- DataMutex<std::map<uint32_t, InputImageData>> mInputImageMap;
+ DataMutex<std::map<uint64_t, InputImageData>> mInputImageMap;
MediaEventProducer<uint64_t> mInitPluginEvent;
MediaEventProducer<uint64_t> mReleasePluginEvent;

View file

@ -0,0 +1,15 @@
Patch-Source: https://phabricator.services.mozilla.com/D212612
diff --git a/toolkit/moz.configure b/toolkit/moz.configure
index 6d5485325c..c5dcc65dd5 100644
--- a/toolkit/moz.configure
+++ b/toolkit/moz.configure
@@ -2426,6 +2426,8 @@ with only_when(compile_environment):
& jpeg_arm_neon_vld1q_u8_x4,
)
+ set_config("MOZ_SYSTEM_JPEG", True, when="--with-system-jpeg")
+
# PNG
# ===

View file

@ -0,0 +1,34 @@
missing include to use qsort()
https://bugzil.la/1906955
--- a/dom/media/webrtc/transport/third_party/nrappkit/src/registry/registry_local.c 2024-07-09 18:11:39.207125821 +0200
+++ b/dom/media/webrtc/transport/third_party/nrappkit/src/registry/registry_local.c 2024-07-09 18:12:07.657013364 +0200
@@ -53,6 +53,7 @@
#include <openssl/ssl.h>
#endif
#include <ctype.h>
+#include <stdlib.h>
#include "registry.h"
#include "registry_int.h"
#include "registry_vtbl.h"
@@ -62,6 +63,10 @@
#include "r_errors.h"
#include "r_macros.h"
+static int nr_compare_string(const void *arg1, const void *arg2) {
+ return strcasecmp(*(const char **)arg1, *(const char **)arg2);
+}
+
/* if C were an object-oriented language, nr_scalar_registry_node and
* nr_array_registry_node would subclass nr_registry_node, but it isn't
* object-oriented language, so this is used in cases where the pointer
@@ -1067,7 +1072,7 @@
}
assert(sizeof(*arg.children) == sizeof(NR_registry));
- qsort(arg.children, arg.length, sizeof(*arg.children), (void*)strcasecmp);
+ qsort(arg.children, arg.length, sizeof(*arg.children), nr_compare_string);
*length = arg.length;

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,12 @@
diff --git a/zotero/pdf-worker/pdf.js/package.json.orig b/zotero/pdf-worker/pdf.js/package.json
index c76c824..c3658db 100644
--- a/zotero/pdf-worker/pdf.js/package.json.orig
+++ b/zotero/pdf-worker/pdf.js/package.json
@@ -7,7 +7,6 @@
"@babel/runtime": "^7.24.7",
"@fluent/bundle": "^0.18.0",
"@fluent/dom": "^0.9.0",
- "@jazzer.js/core": "^2.1.0",
"@metalsmith/layouts": "^2.7.0",
"@metalsmith/markdown": "^1.10.0",
"autoprefixer": "^10.4.19",

View file

@ -1,134 +0,0 @@
diff --git a/zotero/reader/package-lock.json.orig b/zotero/reader/package-lock.json
index e3a638f..0800781 100644
--- a/zotero/reader/package-lock.json.orig
+++ b/zotero/reader/package-lock.json
@@ -84,7 +84,6 @@
"karma-chrome-launcher": "^3.1.0",
"karma-mocha": "^2.0.1",
"karma-mocha-reporter": "^2.2.5",
- "karma-phantomjs-launcher": "^1.0.4",
"karma-sourcemap-loader": "^0.3.7",
"karma-webpack": "^5.0.0",
"mocha": "^7.2.0",
@@ -12342,20 +12341,6 @@
"node": ">=4"
}
},
- "node_modules/karma-phantomjs-launcher": {
- "version": "1.0.4",
- "resolved": "https://registry.npmjs.org/karma-phantomjs-launcher/-/karma-phantomjs-launcher-1.0.4.tgz",
- "integrity": "sha512-tf4P3plsE7wb5Pqh8GJ6RnElxfI/UM4MtVnjbSIZFpdFJlKnjRzfIx8MLCcSYJBwZ1+qSKFz4uBe3XNoq2t3KA==",
- "deprecated": "PhantomJS development have stopped, use puppeteer or similar",
- "dev": true,
- "dependencies": {
- "lodash": "^4.0.1",
- "phantomjs-prebuilt": "^2.1.7"
- },
- "peerDependencies": {
- "karma": ">=0.9"
- }
- },
"node_modules/karma-sourcemap-loader": {
"version": "0.3.8",
"resolved": "https://registry.npmjs.org/karma-sourcemap-loader/-/karma-sourcemap-loader-0.3.8.tgz",
@@ -15340,40 +15325,6 @@
"integrity": "sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==",
"dev": true
},
- "node_modules/phantomjs-prebuilt": {
- "version": "2.1.16",
- "resolved": "https://registry.npmjs.org/phantomjs-prebuilt/-/phantomjs-prebuilt-2.1.16.tgz",
- "integrity": "sha512-PIiRzBhW85xco2fuj41FmsyuYHKjKuXWmhjy3A/Y+CMpN/63TV+s9uzfVhsUwFe0G77xWtHBG8xmXf5BqEUEuQ==",
- "deprecated": "this package is now deprecated",
- "dev": true,
- "hasInstallScript": true,
- "dependencies": {
- "es6-promise": "^4.0.3",
- "extract-zip": "^1.6.5",
- "fs-extra": "^1.0.0",
- "hasha": "^2.2.0",
- "kew": "^0.7.0",
- "progress": "^1.1.8",
- "request": "^2.81.0",
- "request-progress": "^2.0.1",
- "which": "^1.2.10"
- },
- "bin": {
- "phantomjs": "bin/phantomjs"
- }
- },
- "node_modules/phantomjs-prebuilt/node_modules/which": {
- "version": "1.3.1",
- "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz",
- "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==",
- "dev": true,
- "dependencies": {
- "isexe": "^2.0.0"
- },
- "bin": {
- "which": "bin/which"
- }
- },
"node_modules/picocolors": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz",
@@ -27192,7 +27143,6 @@
"karma-chrome-launcher": "^3.1.0",
"karma-mocha": "^2.0.1",
"karma-mocha-reporter": "^2.2.5",
- "karma-phantomjs-launcher": "^1.0.4",
"karma-sourcemap-loader": "^0.3.7",
"karma-webpack": "^5.0.0",
"mocha": "^7.2.0",
@@ -30512,16 +30462,6 @@
}
}
},
- "karma-phantomjs-launcher": {
- "version": "1.0.4",
- "resolved": "https://registry.npmjs.org/karma-phantomjs-launcher/-/karma-phantomjs-launcher-1.0.4.tgz",
- "integrity": "sha512-tf4P3plsE7wb5Pqh8GJ6RnElxfI/UM4MtVnjbSIZFpdFJlKnjRzfIx8MLCcSYJBwZ1+qSKFz4uBe3XNoq2t3KA==",
- "dev": true,
- "requires": {
- "lodash": "^4.0.1",
- "phantomjs-prebuilt": "^2.1.7"
- }
- },
"karma-sourcemap-loader": {
"version": "0.3.8",
"resolved": "https://registry.npmjs.org/karma-sourcemap-loader/-/karma-sourcemap-loader-0.3.8.tgz",
@@ -32687,34 +32627,6 @@
"integrity": "sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==",
"dev": true
},
- "phantomjs-prebuilt": {
- "version": "2.1.16",
- "resolved": "https://registry.npmjs.org/phantomjs-prebuilt/-/phantomjs-prebuilt-2.1.16.tgz",
- "integrity": "sha512-PIiRzBhW85xco2fuj41FmsyuYHKjKuXWmhjy3A/Y+CMpN/63TV+s9uzfVhsUwFe0G77xWtHBG8xmXf5BqEUEuQ==",
- "dev": true,
- "requires": {
- "es6-promise": "^4.0.3",
- "extract-zip": "^1.6.5",
- "fs-extra": "^1.0.0",
- "hasha": "^2.2.0",
- "kew": "^0.7.0",
- "progress": "^1.1.8",
- "request": "^2.81.0",
- "request-progress": "^2.0.1",
- "which": "^1.2.10"
- },
- "dependencies": {
- "which": {
- "version": "1.3.1",
- "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz",
- "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==",
- "dev": true,
- "requires": {
- "isexe": "^2.0.0"
- }
- }
- }
- },
"picocolors": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz",