Importing Swift framework in Xcode - where to put "import" instructions? - swift

I am trying to import an existing SDK for ClickSend (https://github.com/ClickSend/clicksend-swift) into my existing iOS Swift project in Xcode, but the installation doesn't say much (at least not for me that comes from Visual Studio and C#).
This is the installation instruction:
Put the package under your project folder and add the following in
import:
"./clicksend-swift"
I can't seem to find any places called "import" where I can add ./clicksend-swift. I have been trying to add the files/folders to my project, but it doesn't compile (can't find the Alamo framework)
I guess this is something that is very trival and everyone understands, since the installation is so short and there are no Google results for doing a simple import project.

The ClickSend team has now updated library and installation instructions, so everything is clear on how to install the library. :)

Related

Xamarin Forms - Using GitHub Source Code instead of Nuget Package

I have a Xamarin Forms Project, and I do use ShinyLib.net Package https://github.com/shinyorg/shiny.
I do have some bugs with Shiny, which I would like to track down and Fix.
How can I make my project use the Source Code from Git instead of the Nuget Packages so I can Debug and Make changes and try to fix some bugs? Shiny already is using .Net MUAI, but it is still compatible with Xamarin.
I tried to Download the Shiny Source Code, and in my Project, I use Add Existing Project, but it shows me that is Incompatible, and it fails when compiling :
Shiny.BluetoothLE is not compatible with netstandard2.1.
Can someone please explain the correct way for me to compile using source code instead of Nuget Package?

UI Test target does not recognize Swift package from custom framework in xcworkspace

I am developing several projects in a single workspace (monorepo). The workspace contains a shared framework that contains code shared between the projects. Some of the code depends on external packages that I import using the Swift Package Manager. Everything is working except that the packages aren't recognized when I use the UI testing target. When I run the UI tests for one of the projects it complains that the packages cannot be found (in the framework). Another solution that suits my needs is also welcome. Anyway, I'm using Xcode 11.3. To reproduce:
Create a new workspace.
Add a new project A and a new framework B into the workspace.
Add any dependency (for example SDWebImage) to the framework.
Add a Swift-file to the framework that just does import SDWebImage.
Now add framework B as a dependency to project A.
If you build project A or unit test project A, there is no problem. However, when you run UI tests on project A it complains that it cannot find the module SDWebImage in the Swift-file you added in point 4 above. Any idea how to solve this?
Edit: When I use Cocoapods instead it gives me the same error. When I use use_frameworks! it doesn't give me the error, but it crashes with "SDWebImage: image not found".
You have to manually add your B framework as a linked library in on your UI Tests target under Build Phases -> Link Binary With Libraries

Difficulties to make package and import (importedNamespace) working when I have several files in XText

I am trying to implement the package/import mechanism into my DSL.
It works perfectly when I have a single file but not with different files.
Even the 15 Minutes Tutorial doesn't work for me. I don't manage to make it work even by coping/pasting the code from the website. I only modify the grammar file.
I tried to investigate this problem further, but found nothing relevant on the Internet.
I noticed that the resource set contains only the current files edited, not the other files present in the project. To see that, I add this line of code in the validator and the scope provider: println(context.eResource.resourceSet.resources).
From my understanding of how XText works, I expected to get one resource for each file present inside the project.
When I create the project, I usually create a "General Project". But I got the same issue with a Java one.
Here my configuration:
macOS Mojave, v. 10.14.1
Eclipse DSL Tools v. 2018-09 (4.9.0)
Xtext v.2.16.0v20181203-0514
JDK 1.8
Thanks a lot for your help.
As suggested by #ChristianDietrich in his comment, the project build was off. After turning it on, the import works perfectly.

how to add .bundle file to a nativescript plugin

I have some thirdparty code I want to add to my nativescript (iOS) project. The code consists of a .framework file and a .bundle file which contains a .momd file. I was thinking of adding this via a custom plugin, the docs are pretty clear on how to add the .framework file, but am not sure how I add and reference the bundle and underlying .momd file. Does anyone have any experience of this that they can share please?
I spent a lot of time poring over the iOS interop documentation while working on my nativescript-midi plugin, but I don't recall seeing anything specifically on adding bundles or .momd files. If possible, I suggest you create a new "container" iOS framework project in which you can import your desired framework, bundle, and .momd file, and then import that combined framework project into your plugin via a Podfile. That's essentially the approach I took to import a C library in my project (the cocoa-midi-message-parser repo referenced by the Podfile in my plugin).
In case anyone else needs to do this. I ended up using cocoapods xcodeproj gem to inject my file into my workspace file. A gist of the working code is here.

Windows Azure Toolkit

I'm trying to build and run some of the example apps included in the Windows Azure Toolkit here, but it can't seem to find libwatoolkitios.a which is a required file for build. I have not modified the project in any way and I would assume that this file should be included automatically, so how do I get it? How have you guys been able to compile the apps successfully? Thanks.
The library libwatoolkitios.a is not provided as download instead you would need to build it first, described in the doc as below:
Open the watoolkit-lib Xcode project.
Compile the project for release.
Place the .a file and the header files somewhere that you can reference from your project (for this example lets say lib).