Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 6 years ago.
Improve this question
Totally new Swift. I was going through the tutorial at RayWenderLich
and ran into some build errors before even putting in any code. I created the new project, click run, and the following errors show up. (I'm using Xcode 7.3.1)
IconsCore.h
Unknown type name 'IconFamily Resource'
Unknown type name 'IconFamilyHandle'
Unknown type name 'IconFamilyHandle'
NSURLError.h
Could not build module 'CoreServices'
ApplicationServices.h
Could not build module 'CoreServices'
Could not build Objective-C module 'Foundation'
My searching is turning up empty and getting quite frustrating. Especially when I'm just trying to get started. Does anyone have any ideas?
Well, I'm no longer having the problem. Looking to fix Xcode, I ran a terminal command that cleaned something out of /var/logs, and then I could no longer boot. So I went scorched earth and reinstalled the entire OS and Xcode. I did run into some errors while installing, (I think my SSD is failing) but I no longer get the errors while trying to build and run an app.
Summary - I THINK that the problem was a result of corrupted OS or Xcode files.
Related
Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 2 years ago.
Improve this question
I updated my flutter today and I had a lot of problems with the image package.
Target of URI doesn't exist: 'package:image/image.dart'.
Try creating the file referenced by the URI, or Try using a URI for a file that does exist.darturi_does_not_exist
Make sure you have this is pubspec.yaml,
*note remember to have every space in this file aligned
dependencies:
image: ^2.1.14
Save that file, if you're running VS Code, it will run the command pub get for you automatically, if you're running Android Studio, click on Get Dependencies on the top of the screen after saving the file, otherwise you can do it manually via the terminal with the command pub get
then try again
import 'package:image/image.dart';
So I have an xcode project that fails every time I run it on my computer. Works on other computers though. I get the following error:
dyld: Library not loaded: /System/Library/PrivateFrameworks/Swift/libswiftCoreFoundation.dylib
Now, when I look in /System/Library/PrivateFrameworks/Swift/ I can't find the libswiftCoreFoundation.dylib file. But other swift projects work just fine. I have no idea how to fix this. I've tried cleaning, restarting my computer, creating a copy of the project, updating Xcode, updating command line tools, everything I could think of.
The project was working just fine a few hours ago. Something went wrong by itself. No clue how to fix things.
After spending 6 straight hours debugging and trying to fix things, I found the solution. For some reason, my "Library Search Paths" was filled with the wrong directory. I never set it to that directory. But it was set.
Here is what I mean:
The highlighted field was filled with the following: macosx/System/Library/PrivateFrameworks/Swift
I just took that out. I hope this helps save some future traveler the pain and torture I went through
Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 7 years ago.
Improve this question
screenshot
I'm getting an error saying "no such module Parse" after downloading SDK( Parse) and adding frameworks and dependencies to my App. When I added "import Parse" to AppleDelegate.swift but it caused the error.
I attached a screenshot above.
Can anyone help me with this?
Thank you so much
Remove the framework completely by clicking delete in your framework folder (in Xcode, not finder)
Make sure that there is no trace of the framework in finder in your project folder. (I had the same problem and found out that I had duplicates in my Xcode project folder)
Restart Xcode
Re download the frameworks and put into your project through Xcode (not by dragging them in finder)
Clean project
It should run after doing these steps. I had the same problem as you and found restarting Xcode and reloading the frameworks worked. Hopefully this also works for you.
possible duplicate isn't an issue, it means that your question has been asked before ;)
This is what I think you should do:
Your framework is most likely written in Objective C and therefore your cant import it so easily.
Inside your framework create a header file:
Then you write this in the header file to import the parse modules I think:
#import <Parse.h>
And now you should be able to do:
import Parse
Don't forget this:
Go to your main project -> Build Phases -> Link Binary With Libaries -> add Parse there.
I am not sure how the parse module is called, so inside your framework, check how to main file is called (most likely something like parse.h) and replace that with the code inside the <...>
I've spent the past few months converting a project of mine with about 1500 source code files into Swift. It was incredibly tedious, but I finally did it. It runs well, builds well, but:
When I attempt to archive the project, Xcode fails with the following error:
ditto: can't get real path for source '/Users/USER/Library/Developer/Xcode/DerivedData/
APP-dtsbrzschafjiubelceuxtfwstqf/Build/Intermediates/ArchiveIntermediates/APPCore/
IntermediateBuildFilesPath/APPCore.build/Release/APPCore.build/Objects-normal/
x86_64/APPCore.swiftmodule''
Command /usr/bin/ditto failed with exit code 1
APP being the app and APPCore being the embedded framework.
What I've tried:
cleaning the project (which really has no effect when archiving, since archive always compiles from scratch)
using Xcode 7.2 beta (released a few days ago)
making as many declarations as possible non-public
disabling any Swift optimizations for the release build configuration
building the APPCore framework as release - which actually works (!) - and does (!) create the .swiftmodule file
The last part being the strangest here. This evidently points to the archive doing something slightly different, but I have no idea what.
My question is if anyone has any idea why is this happening and how to debug this. I've spent the last two days trying to figure this out, but no results...
I've googled this error as well, but unfortunately, the answers were fairly limited and suggesting to comment all lines of code and then start slowly uncommenting them until the project builds. Which is OK for a smaller project, but not for a 25KLOC project, mainly when you have absolutely no idea where to start...
I had the same issue and your question actually helped me to solve it (Xcode 8).
In debug mode just got the "ditto: can't get real path for source" without any further information. Switching to release mode showed me that the problem was that the framework wasn't allowed to have a bridging header file. I went to the build settings and removed the bridging header file (don't know why there was one) and it now compiles both in release and debug mode.
Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 4 years ago.
Improve this question
I've got a perfectly running sprite-kit project cloned from github to my mac, and i keep getting multiple compiling errors as the one in the title.
The project works well on all supported devices and simulators in my friends mac, which has the same Xcode Version 5.0.2, ios7+. I have no clue where I'm getting this error from, it comes from native libraries such as corefoundation. Has anyone ever seen this error before?
it seems to be a bug in xcode 5 and github. I've tried doing git checkout to older commits, till I found one that did work. then I did git checkout back to the latest commit, and it would magically work. the problem may reappear often, but then just repeating the process will do, as it did for me a couple of times.