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

[BUG] M3 Mac won't run #28

Open
QiuYeHong90 opened this issue Dec 30, 2024 · 10 comments
Open

[BUG] M3 Mac won't run #28

QiuYeHong90 opened this issue Dec 30, 2024 · 10 comments

Comments

@QiuYeHong90
Copy link

OpenIM Server Version

报各种编译错误

Operating System and CPU Architecture

macOS (ARM)

Deployment Method

Source Code Deployment

Bug Description and Steps to Reproduce

报各种编译错误

Screenshots Link

报各种编译错误Command SwiftCompile failed with a nonzero exit code

@QiuYeHong90
Copy link
Author

有些第三方库限制了版本号,导致xcode 16 不兼容M3 电脑, 目前把版本号限制去掉之后可以运行了

@Axbros
Copy link

Axbros commented Dec 31, 2024

請問compile之後有ipa文件嗎

@std-s std-s changed the title [BUG] M3 Mac 跑不起来 [BUG] M3 Mac won't run Jan 2, 2025
@std-s
Copy link
Member

std-s commented Jan 2, 2025

@QiuYeHong90 Hi, could you please send me the modified version of the dependency?

@QiuYeHong90
Copy link
Author

s.dependency 'OUICore'
s.dependency 'OUICoreView'
s.dependency 'JXSegmentedView', '1.3.0'
s.dependency 'MJRefresh'
s.dependency 'RxSwift'
s.dependency 'RxRelay'
s.dependency 'SnapKit'
s.dependency 'DifferenceKit', '1.3.0'
s.dependency 'ChatLayout', '2.0.10'
s.dependency 'InputBarAccessoryView', '5.5.0'
s.dependency 'OUICalling'

s.dependency 'OUICore'
s.dependency 'Lantern', '1.1.5'

s.dependency 'OpenIMSDK', '3.8.2'
s.dependency 'SnapKit', '> 4.0'
s.dependency 'RxSwift', '
> 6.5'
s.dependency 'RxCocoa', '> 6.0'
s.dependency 'RxKeyboard', '
> 2.0'
s.dependency 'RxDataSources', '5.0.0'
s.dependency 'Kingfisher', '7.7.0'
s.dependency 'lottie-ios', '> 3.0'
s.dependency 'ZLPhotoBrowser', '4.3.0'
s.dependency 'ProgressHUD', '14.1.0'
s.dependency 'IQKeyboardManagerSwift'
s.dependency 'Localize-Swift', '
> 3.2'
s.dependency 'Alamofire', '4.9.1'

@QiuYeHong90
Copy link
Author

我用的是 SDK-3.8.2 这个版本的

@QiuYeHong90
Copy link
Author

当时一些第三方没升级到最新的版本,就导致编译出错了, 我看了你的main 分之已经修复了

@QiuYeHong90
Copy link
Author

alerts-and-pickers 这个第三方库一直编译错误

@QiuYeHong90
Copy link
Author

Log("status = (CNContactStore.authorizationStatus(for: .contacts))")
switch CNContactStore.authorizationStatus(for: .contacts) {

    case .notDetermined:
        /// This case means the user is prompted for the first time for allowing contacts
        Contacts.requestAccess { [unowned self] bool, error in
            self.checkStatus(completionHandler: completionHandler)
        }
        
    case .authorized:
        /// Authorization granted by user for this app.
        DispatchQueue.main.async {
            self.fetchContacts(completionHandler: completionHandler)
        }

    case .denied, .restricted:
        /// User has denied the current app to access the contacts.
        let productName = Bundle.main.dlgpicker_appName
        let alert = UIAlertController(title: "Permission denied", message: "\(productName) does not have access to contacts. Please, allow the application to access to your contacts.", preferredStyle: .alert)
        alert.addAction(title: "Settings", style: .destructive) { action in
            if let settingsURL = URL(string: UIApplication.openSettingsURLString) {
                UIApplication.shared.open(settingsURL)
            }
        }
        alert.addAction(title: "OK".localized, style: .cancel) { [unowned self] action in
            self.alertController?.dismiss(animated: true)
        }
        alert.show()
    case .limited:
        break
    @unknown default:
        break
    }

@QiuYeHong90
Copy link
Author

少了两个枚举值

@QiuYeHong90
Copy link
Author

installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings.delete 'IPHONEOS_DEPLOYMENT_TARGET'

config.build_settings["EXCLUDED_ARCHS[sdk=iphonesimulator*]"] = "arm64"

      config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '13.0'
      config.build_settings['ENABLE_BITCODE'] = 'NO'
      config.build_settings['EXPANDED_CODE_SIGN_IDENTITY'] = ""
      config.build_settings['CODE_SIGNING_REQUIRED'] = "NO"
      config.build_settings['CODE_SIGNING_ALLOWED'] = "NO"
            
      if target.name == 'OUIIM'
        config.build_settings['OTHER_SWIFT_FLAGS'] = ['$(inherited)',
        '-D', 'COCOAPODS',
        '-D', 'ENABLE_CALL',
        ]
      end
      
      if target.name == 'OUICore'
        config.build_settings['OTHER_SWIFT_FLAGS'] = ['$(inherited)',
        '-D', 'COCOAPODS',
        ]
      end

      if target.name == 'OUICoreView'
        config.build_settings['OTHER_SWIFT_FLAGS'] = ['$(inherited)',
        '-D', 'COCOAPODS',
        ]
      end
end

end
end

这个地方需要设置iOS 13

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants