Skip to content

Commit

Permalink
[leveldb] Add privacy manifest for SPM / CocoaPods (#9)
Browse files Browse the repository at this point in the history
* [leveldb] Add privacy manifest for SPM / CocoaPods

* Exclude files that became problematic after bumping to STV 5.3
  • Loading branch information
ncooke3 authored Feb 13, 2024
1 parent 6e09670 commit 174a4b5
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Package.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// swift-tools-version:5.0
// swift-tools-version:5.3
// The swift-tools-version declares the minimum version of Swift required to build this package.

import PackageDescription
Expand Down Expand Up @@ -50,6 +50,8 @@ let package = Package(
"util/no_destructor_test.cc",
"util/status_test.cc",
"db/c_test.c",
"port/README.md",
"port/port_config.h.in",
],
sources: [
"db/",
Expand All @@ -58,6 +60,7 @@ let package = Package(
"util/",
"include/",
],
resources: [.process("Resources/PrivacyInfo.xcprivacy")],
publicHeadersPath: "include",
cSettings: [
.define("LEVELDB_IS_BIG_ENDIAN", to: "0"),
Expand Down
26 changes: 26 additions & 0 deletions Resources/PrivacyInfo.xcprivacy
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSPrivacyTracking</key>
<false/>
<key>NSPrivacyTrackingDomains</key>
<array>
</array>
<key>NSPrivacyCollectedDataTypes</key>
<array>
</array>
<key>NSPrivacyAccessedAPITypes</key>
<array>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryFileTimestamp</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>C617.1</string>
</array>
</dict>
</array>
</dict>
</plist>

4 changes: 4 additions & 0 deletions leveldb-library.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,10 @@ Pod::Spec.new do |s|
"util/testutil.cc"
]

s.resource_bundle = {
"#{s.module_name}_Privacy" => 'Resources/PrivacyInfo.xcprivacy'
}

s.library = 'c++'
end

0 comments on commit 174a4b5

Please sign in to comment.