readium / swift-toolkit

A toolkit for ebooks, audiobooks and comics written in Swift
https://readium.org/mobile/
BSD 3-Clause "New" or "Revised" License
225 stars 96 forks source link

Missing required module 'Minizip' #298

Open Sato-Falisa opened 1 year ago

Sato-Falisa commented 1 year ago

Bug Report

spm add swift-tooklit

What happened?

import R2Shared

Expected behavior

Development environment

swift version build 5.7 xcode 14

Screenshot 2023-05-15 at 10 14 22
mickael-menu commented 1 year ago

I can't reproduce on Xcode 14.3, Swift 5.8 from a blank test project. Could you try again after clearing the build folder and DerivedData?

rm -rf ~/Library/Developer/Xcode/DerivedData

And what do you see in the resolved Package Dependencies? The Zip 2.1.12 dependency must be present.

Screenshot 2023-05-15 at 16 55 54
Sato-Falisa commented 1 year ago

I can't reproduce on Xcode 14.3, Swift 5.8 from a blank test project. Could you try again after clearing the build folder and DerivedData?

rm -rf ~/Library/Developer/Xcode/DerivedData

And what do you see in the resolved Package Dependencies? The Zip 2.1.12 dependency must be present.

Screenshot 2023-05-15 at 16 55 54

I run rm -rf ~/Library/Developer/Xcode/DerivedData show this error

Screenshot 2023-05-16 at 18 57 23

and then File->package-> update to latest package version still show same error

Screenshot 2023-05-16 at 19 02 19
Sato-Falisa commented 1 year ago

I wonder if you give me the different module‘ xcframwwork by complice by Swift 5.7.2 compiler of xcode14.2 or give me the xcframwwork that can support all Swift version compiler by set “build libraries for distribution” as YES for version 2.3.0 or vresion 2.4.0. ( not 2.5.0 )

mickael-menu commented 1 year ago

I'm not sure I understand what you mean? When using Swift Package Manager, there are no XCFrameworks involved.

mickael-menu commented 1 year ago

Do you have the same issue when building the Readium Test App? (using make spm in the TestApp folder, see its README).

Sato-Falisa commented 1 year ago

I used to use carthage to manage [swift-toolkit],but while uodatin update xcode to 14.2 ,my project failed to complied by the swift verison peoblem such like this"Module compiled with Swift 5.6.1 cannot be imported by the Swift 5.7 compiler" when my code need import “R2Shared” or other Class from swift-toolk like this pic 239242280-b0500db5-59e0-4e20-a5df-b171ba665ecd

I have tried to carthage update swift-toolkit,but it always been failed!

so I try to switch the manager way to spm, but it still failed show other error above pic ,

I am upset。so wonder if u can give me some xcframeworks (version 2.3.0 or 2.4.0 complied by swift 5.72),so that I can drag them to floder “Build” in folder “Cartahge" for updating those xcframework

mickael-menu commented 1 year ago

I have tried to carthage update swift-toolkit,but it always been failed!

It's often messy with the Carthage update. You really need to clear all the Carthage caches. For example, from the root of your project:

rm -rf ~/Library/Developer/Xcode/DerivedData
rm -rf ~/Library/Caches/org.carthage.CarthageKit
rm -rf ~/Library/Caches/carthage
rm -rf Carthage

mkdir -p Carthage/Build/iOS
carthage update --use-xcframeworks --platform iOS

I am upset。so wonder if u can give me some xcframeworks (version 2.3.0 or 2.4.0 complied by swift 5.72)

No, sorry.

Do you have the same SPM issue when building the Readium Test App? (using make spm in the TestApp folder, see its README).

Sato-Falisa commented 1 year ago

I have tried to carthage update swift-toolkit,but it always been failed!

It's often messy with the Carthage update. You really need to clear all the Carthage caches. For example, from the root of your project:

rm -rf ~/Library/Developer/Xcode/DerivedData
rm -rf ~/Library/Caches/org.carthage.CarthageKit
rm -rf ~/Library/Caches/carthage
rm -rf Carthage

mkdir -p Carthage/Build/iOS
carthage update --use-xcframeworks --platform iOS

I am upset。so wonder if u can give me some xcframeworks (version 2.3.0 or 2.4.0 complied by swift 5.72)

No, sorry.

Do you have the same SPM issue when building the Readium Test App? (using make spm in the TestApp folder, see its README).

yes I face. the problem using SPM ,fpr example. other file need import 'R2Shared', show error “No such module ”!!!!!