Post marked as unsolved
104
Views
Hey guys! so im learning Obj-C ik most will say just learn swift but im doing Obj-c for a purpose lmao. But anyway in the book i have that teaches me it says to select the foundation tool from the menu for command line utility. but in hte xcode 12.4 version there is no foundation in the drop box or foundation tool option in new project. So in the new version im looking for the new steps that basically do the following old step from my book.
For type of Application select command line utility, Foundation Tool, and click choose.
Post marked as unsolved
97
Views
Greetings!
I encounter an issue when try building an xcframework from a framework project with Embed and Sign option enabled for the project's pods. When I'm trying to use the xcframework in the final app I get a compile errors: No such module framework's dependency from pod
Failed to build module framework-module-name from its module interface; it may have been damaged or it may have triggered a bug in the Swift compiler when it was produced.
The goal is to get the xcframework contains all the required things. To be able simply add the xcframework to any app without any additional dependencies.
Question: Does the option "Embed and Sign" include all of the libraries into the main project build ?
Post marked as unsolved
94
Views
Hi, I'm new to coding, and so I was wondering if someone could help me with an app I'm building? I am using Core Data to make a to do list app, and was using YouTube to learn. I have a problem: my app compiles, but the string where I have my @FetchRequest shows up as a Thread 1 Error: signal SIG ABRT. I realize this means it crashed, but I don't know where/how to fix. Lmk if anyone gets this/could help? Thanks.
Post marked as unsolved
184
Views
Hi!
I'm trying to compile this GPL 3.0 C++ UCI chess engine (based on Stockfish) for Apple Silicon M1 native to run on my wonderful new Mac mini M1.
https:/pixeldrain.com/u/xqskCd3S - add a / to https
Please, could someone SKILLED compile it, modifying the makefile originally made for Windows x64?
(popcnt SSE3 or SSE41 | SSE43, NO AVX2 or BM2 extensions)
...Or at least could you suggest me a tutorial for compiling it using Xcode 12.2 or command line tools. I'm an asp.net programmer (until now :-) )
I use free BangsiaGui chess interface for Mac. https:/banksiagui.com/dl/BanksiaGui-0.38-mac.zip - add a / to https
Ask me all informations you need...
Thank you in advance, Amor64Chess
Post marked as unsolved
136
Views
Is there a new way in Big Sur, running on an M1, to enable and utilize large memory pages? I've done a lot of searching on the internet and many tests, but haven't been able to figure it out. Closest I've come to insight is thinking there might be a conflict with JIT preventing the usage of it?
This is what used to work in C++:
void *mem = mmap(0, size, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON, VM_FLAGS_SUPERPAGE_SIZE_2MB, 0);
Also tried:
void *p = mmap((void *) 0x000200000000, 8 * 1024 * 1024,
PROT_READ | PROT_WRITE,
MAP_ANON | MAP_FIXED | MAP_PRIVATE,
VM_FLAGS_SUPERPAGE_SIZE_2MB, 0);
Maybe there's an alternative way to accomplish Huge pages.
Post marked as unsolved
354
Views
as the title suggests, i cant run my (objective c) project in xcode after upgrading to Xcode 12. It is a Cocoapods project.
It works fine when i deploy to my phone, but in the simulator
I get three different errors for some reason.
It complains about "missing module map" for a separate project i include:
module map file '...(path)/Build/Products/Debug-iphonesimulator/MyLibraryProject/MyLibraryProject.imagemap' not found
2. It complains about a precompiled header:
<unknown>:0: error: failed to emit precompiled header '(path)/Build/Intermediates.noindex/PrecompiledHeaders/myProject-Bridging-Header-swift2UGSYUUFRK85M-clang18QKMU0TXX4JD.pch' for bridging header '(path)/iphone/myProject/myProject-Bridging-Header.h'
3. Finally it complains about Not finding a bundle for a library that i use:
error: Resource "(path)/Products/Debug-iphonesimulator/FCAlertView/FCAlertView.bundle" not found. Run 'pod install' to update the copy resources script.
Again, i can build and deploy to my phone, and submit to TestFlight/Appstore, but if i pick an emulator it's crash and burn.
I am not very knowledgeable about xcode inner workings, so if anyone has any pointers, i'd be *most* grateful.
Post marked as unsolved
74
Views
Build fail with Swift Compiler Error:
The compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions
on line 9 in code section below (line 150 in BBPMainController.swift).
I have tried to comment out sections and line 150 together with expressions where aboveAlpha is used and it does the trick.
Have been unable to understand why and would appreciate brighter eyes to help out.
BBPMainController.swift - https://developer.apple.com/forums/content/attachment/96c2ba15-9909-44af-98be-4d68f785a8b4
func scrollViewDidScroll(_ scrollView: UIScrollView) {
// -- Update overlayer alpha value --
let maxAlphaValue: CGFloat = 0.75
// Calcuate alpha
let aboveAlpha = 0 - (maxAlphaValue - maxAlphaValue * ((scrollView.contentOffset.y - view.bounds.height) / view.bounds.height)) + maxAlphaValue * 2
let belowAlpha = maxAlphaValue - maxAlphaValue * ((scrollView.contentOffset.y - view.bounds.height) / view.bounds.height) + maxAlphaValue
// Set alpha or 0 if alpha is greater than 1
applocationScrollOverlayerAboveView.alpha = aboveAlpha 1 ? 0 : max(0, min(1, aboveAlpha))
applocationScrollOverlayerBelowView.alpha = belowAlpha 1 ? 0 : max(0, min(1, belowAlpha))
// -- Update transform scale and view alpha value --
let minScaleValue: CGFloat = 0.6
let scale: CGFloat
if aboveAlpha 1 {
scale = ((scrollView.contentOffset.y - view.bounds.height * 2) / view.bounds.height) * minScaleValue + abs(minScaleValue - 1)
} else {
scale = 0 - ((scrollView.contentOffset.y - view.bounds.height) / view.bounds.height) * minScaleValue + abs(minScaleValue - 1)
}
applicationController.view.transform = CGAffineTransform(scaleX: scale, y: scale)
applicationController.view.alpha = max(0, min(1, scale))
}
Post marked as unsolved
125
Views
I have a project with an iOS deployment target of 10.0.
When I add some SwiftUI views to the project, I can build only debug configuration of it. But when I'm trying to compile the Release configuration, I see the errors like Cannot find type 'View' in scope, or Unknown attribute 'Binding', etc.
As the project has an iOS 10 deployment target, I use the @available(iOS 13.0, *) attribute, like this:
import SwiftUI
@available(iOS 13.0, *)
struct GiftView: View { ... }
There is an interesting fact: when I increase the deployment target to iOS 11.0 the Release configuration compiles correctly.
Additional details: the project is only the iPhone iOS deployment target (not iPadOS, macOS).
the project uses CocoaPods (probably it somehow affects).
Post marked as unsolved
59
Views
I can't generate IPA's files after update Visual Studio to 16.9.1 version.
I use Xamarin Forms Cross Platform with this project, and I usually compile and build IPAs easily. But now, I can't do it and I don't know if there could be problem of ios certificates, because the debug certificate expired this days and I had to create another one.
This is a list of my installed products: Xamarin Forms: 5.0.0.1931
Xamarin iOS and Mac SDK: 14.14.2.5 (3836759d4)
VisualStudio.Mac: 10
Xamarin: 16.9.000.273 (d16-9@1bba9e0)
Post marked as unsolved
66
Views
Has anyone seen a problem like this? I have a C program
#include stdio.h
char map[0x7fffffff];
int main(void){
printf("!\n");
}
When I compile this from the command line and run it, I get the following message:
dyld: Library not loaded: /usr/lib/libSystem.B.dylib
Referenced from: /Users/td/./a.out
Reason: image not found
Abort trap: 6
If I reduce the size of the array enough (say to 100), or if I malloc the storage, the error goes away and the program runs correctly.
I'm using Xcode 12.4, macOS 11.2.3 on a Mac mini (M1, 2020, 16GB).
cc --version says it's
Apple clang version 12.0.0 (clang-1200.0.32.29)
Target: arm64-apple-darwin20.3.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
C++ behaves the same.
Post marked as unsolved
112
Views
I am working on a solution based on tribal cultures for understanding how people live in groups and within society
Thus brain science will not be only theory but a real world solution for anyone who needs
I need some tips on machine learning by Apple developers
I aim to write code at system level like kernel and BIOS firmware and programming hardware itself
So i can understand the scientific paradigms when you tell me
I plan to test many frameworks also my own but I want to work with Apple directly and tomorrow I will visit Apple store for talking about Apple Mac Air M1 device
I want to open myself in anysense
Thanks for your understanding
See you there
Post marked as solved
149
Views
With the rising amount of assets in the iOS app, the time to compile them is also growing. Is it possible to speed up asset catalog compilation for development purposes only?
E.g. perhaps there are shortcuts or build settings to only copy the assets instead of compressing & optimizing them for debug / developer builds.
Post marked as unsolved
183
Views
Hi guys,
I'm a beginner in xcode and encountered the following error message while compiling a c++ program:
dyld: Library not loaded: /usr/lib/libc++.1.dylib
Referenced from: /Users/RobertYangSun/Library/Developer/Xcode/DerivedData/test-btxasgasfmanhugbyahybngpwzri/Build/Products/Debug/test
Reason: image not found
I have no idea what this error is saying, and the program was working a while ago. I assume I accidentally deleted the /usr/lib/libc++.1.dylib file?
Here's my entire c++ program:
#include bits/stdc++.h
using namespace std;
int N, K, gapTime[(int)1e9], ans;
setint cycles;
int main()
{
// Load data
cin N K;
// Find and sort distinct cycles
cycles.insert(0);
for (int i = 0; i N; i++)
{
int temp;
cin temp;
cycles.insert((temp + 11)/12);
}
// Eliminate K greatest gaps
int totalGap = 0;
int timeSkipped = 0;
setint::iterator itr;
int a = *cycles.begin(), i = 0;
for (itr = cycles.begin(); itr != cycles.end(); itr++)
{
gapTime[i] = *itr - a;
a = *itr;
totalGap += gapTime[i];
i++;
}
sort(gapTime, gapTime+cycles.size(), greaterint());
ans += (K-1)*12;
i = 0;
for (itr = cycles.begin(); itr != cycles.end(); itr++)
{
if (i = K-1)
{
timeSkipped += gapTime[i];
}
else
{
break;
}
i++;
}
ans += totalGap - timeSkipped;
cout ans endl;
}
Please help!!
Robert
Post marked as unsolved
855
Views
When upgrading from Xcode11.7 to Xcode12.0 (12A7209), after performing the basic necessary project updates and resolving any new warnings, my main app target's Swift interface header is not found when compiling. We've had a mixed ObjC/Swift app for the last ~4 years and have successfully mixed the two with this header since the beginning. With almost no changes to our project file or build settings, Xcode12 will not locate this file and so our ObjC code does not compile.
I went through and commented out all of our ObjC code that references our Swift code and commented out all imports of the Swift header, at which point the build succeeded without warnings. Re-adding a single #import "Remind101-Swift.h" line in our ObjC code yields the error again.
Different incantations of #include do not fix the issue (brackets instead of quotes, fully qualified with module name "Remind101/Remind101-Swift.h").
The file is being generated correctly; I've inspected it in the $(DERIVED_FILES_DIR) directory and its contents look correct.
Swift interface headers from other targets in my application are properly resolved and accessible from my ObjC code, both within those targets and from other targets, e.g. #import <RemindData/RemindData-Swift.h>.
The same Copy Remind101-Swift.h build command appears to be getting executed on both Xcode11 and Xcode12, with the same file paths, but Xcode12 does not successfully find the file after this.
Ditto /Users/aleffelman/Library/Developer/Xcode/DerivedData/Remind101-apkkgwscepuagogklsdprmjnyjpa/Build/Intermediates.noindex/Remind101.build/Developer-iphonesimulator/Remind101.build/DerivedSources/Remind101-Swift.h /Users/aleffelman/Library/Developer/Xcode/DerivedData/Remind101-apkkgwscepuagogklsdprmjnyjpa/Build/Intermediates.noindex/Remind101.build/Developer-iphonesimulator/Remind101.build/Objects-normal/x86_64/Remind101-Swift.h (in target 'Remind101' from project 'Remind101')
		cd /Users/aleffelman/Documents/Code/r101-ios-teacher
		/usr/bin/ditto -rsrc /Users/aleffelman/Library/Developer/Xcode/DerivedData/Remind101-apkkgwscepuagogklsdprmjnyjpa/Build/Intermediates.noindex/Remind101.build/Developer-iphonesimulator/Remind101.build/Objects-normal/x86_64/Remind101-Swift.h /Users/aleffelman/Library/Developer/Xcode/DerivedData/Remind101-apkkgwscepuagogklsdprmjnyjpa/Build/Intermediates.noindex/Remind101.build/Developer-iphonesimulator/Remind101.build/DerivedSources/Remind101-Swift.h
I've added the path $(CONFIGURATION_TEMP_DIR)/$(PROJECT_NAME).build/DerivedSources/ to both the "User Header Search Paths" and "Header Search Paths" in an effort to tell Xcode where to locate the file, but even though that path resolves correctly to where the header file is, I still get the error.
Ultimately, everything was working with our mixed language project in Xcode11 and it is not working with Xcode12, and I've exhausted everything I could think of to debug the situation.
Post marked as unsolved
90
Views
I have a simple project that I built to track down a bizarre problem.
In my applicationDidFinishLaunching:, I call isdigit().
If I add a C Flag such as -DBUILD_RETAIL or a preprocessor macro such as BUILD_RETAIL=1, then I get:
Implicitly declaring library function 'isdigit' with type 'int (int)'
This happens even if I add #import ctype.h to the .m file.
I am on 10.15.7 with Xcode 12.4