Google Drive API for Objective-C with CocoaPods not linking GTMOAuth2 and - google-drive-api

I am trying to incorporate Google Drive API into my Objective-C app. I'm using this link. I setup the quickstart example and that works fine. For my app, I added the API using CocoaPods as directed. When I run the app, I get linker errors not finding GTMOAuth2, GTMSessionFetcher and GoogleAPIClient. Here is one example.
ld: warning: directory not found for option '-L/Users/k/Library/Developer/Xcode/DerivedData/DA/dntvfajcuzknsddygndaenxbqsii/Build/Products/Debug-iphonesimulator/GTMOAuth2'
Under Target->Build settings -> other linker flags
-ObjC -l"GTMOAuth2" -l"GTMSessionFetcher" -l"GoogleAPIClient" -framework "Security" -framework "SystemConfiguration" -lz
for run path search paths, I have #executable/Frameworks
Can some provide info on how to probably setup Xcode so it finds GTMOAuth2, GTMSessionFetcher and GoogleAPIClient that are setup by the CocoaPods.

You may want to try the installation process as discussed in Install a Google SDK using CocoaPods or in Google APIs for iOS which gives the following steps in adding a Google SDK to your iOS app:
CocoaPods is used to install and manage dependencies in existing Xcode projects.
Create an Xcode project, and save it to your local machine.
Create a file named Podfile in your project directory. This file defines your project's dependencies, and is commonly referred to as a Podspec.
Open Podfile, and add your dependencies.
Save the file.
Open a terminal and cd to the directory containing the Podfile.
Run the pod install command. This will install the SDKs specified in the Podspec, along with any dependencies they may have.
Open your app's .xcworkspace file to launch Xcode. Use this file for all development on your app.
Please also check the list of CocoaPods published by Google.
Furthermore, you may want to continue the setup using the approaches to add the library to your project as discussed in this GitHub post such as using GTM OAuth2 or Google Sign-In SDK and adding the framework to an Xcode project.
Lastly, to help you troubleshoot problems during installation, you may visit this guide.

Related

How to install Google Apis Drive v3 via command line on Ubuntu-18.04

I have been trying to install Install-Package Google.Apis.Drive.v3 using this source with the difference that I have Ubuntu-18.04 instead of Windows.
I know it may be a simple question but I have been trying research how to do that from this morning. I installed sudo apt install nuget on my machine and have been trying to add packages or as in this case the Google.Apis.Drive.v3 package but no luck.
I went through this source which was useful, but does not carry information I was able to replicate on my Linux machine.
Also this source, this one and this one too. But also this last one is for Windows and was not very useful.
How do I install Google Apis Drive V3 via command line easily as it is documented for windows but on Ubunbtu-18.04?
Thanks for pointing to the right direction for solving this problem.
Solution
The way you install your Drive API's library is depending on the programming language you are aiming to use. These are the following commands to run depending on the different languages to interact with the API (with their respective links to the source of the setup):
Python:
pip install --upgrade google-api-python-client google-auth-httplib2 google-auth-oauthlib
C#/.NET:
Create a new Visual C# Console Application project in Visual Studio.
Open the NuGet Package Manager Console, select the package source nuget.org, and run the following command:
">Install-Package Google.Apis.Drive.v3
Java:
gradle init --type basic
mkdir -p src/main/java src/main/resources
Node.js:
npm install googleapis#39 --save
For the Browser check out the steps to follow here
I hope this has helped you. Let me know if you need anything else or if you did not understood something.
NOTE: For all Ubuntu-18.04 users that wish to install via command line the correct way is: sudo dotnet add package Google.Apis.Drive.v3

How can i install Google Chrome to use with protractor during automation CI run

My organization doesn't have Google Chrome natively installed within the Virtual Machines configured for automation CI and it's not allowed to install Chrome globally on those machines.
We are using protractor for automation of angular apps which goes really well with Google Chrome.
Is it possible to install Google Chrome at runtime for execution locally so that we can have smooth execution on those VM's. If yes what and how can i install chrome.
We are using TeamCity for CI/CD. Please help.
Update 29/12/2019: A suggestion, you containerize your app. Which means you need to include the step of chrome installation on when the image in being built on your VM.
Generally such a step is included in the Dockerfile.
more info on how to write Dockerfile: https://docs.docker.com/develop/develop-images/dockerfile_best-practices/
Within your angular app, to handle any browser's binary installation, I include it in package.json inside the scripts section:
"webdriver-update": "./node_modules/protractor/bin/webdriver-manager update --standalone --versions.standalone=3.8.0 --chrome --versions.chrome=76.0.3809.68",
This has worked for me in maintaining the dependency on the chrome versions.

How to install the DAML SDK in a Ubuntu VM, which doesn't have the internet connection?

Unable to install the "da-cli-114-7582c1a0bd-linux.run" file in my Ubuntu VM. The setup is failing while checking the latest version check.
I have downloaded the latest DAML SDK setup file "da-cli-114-7582c1a0bd-linux.run" and copied the same into my Ubuntu VM through local network connection. When I try to install the .run file, the setup trying to connect to the internet for latest version check. But I am not allowed to use internet in the application servers/VMs. Because of this restriction the setup is getting failed and I am unable to complete the DAML SDK installation.
Is it possible to get the DAML SDK setup as a .tar file? If we have tar file, then it will be easy to complete the setup manually.
Installing the SDK using the .run files in an environment without an internet connection is not easy. It might be possible to install it in an environment with internet and then tar up the folder ~/.da, extract it back into place in the VM and put ~/.da/bin.
However, there is a new SDK assistant in the works (called daml, not da), which can be installed using curl -sSL get.daml.com | sh. If you look at the content of the installation script, you can see that all it really does is downloading a tar-ball from GitHub releases, un-tars it and calls an install.sh script within. That's probably the easier way to get the SDK into an offline environment at this point.
However, the documentation for the new daml assistant is not on docs.daml.com yet. It will be shortly, but in the meantime you can read it on GitHub.

How to install Yii2 framework - advanced template on shared hosting?

I've tried to download and install the framework but it doesn't have a index file in frontend\web directory.
What i have to do to start using the app?
You can install it locally and run init to generate the missing files, like described here. After that just upload the application to the shared host through FTP.
Also, Yii2 Practical-A App might be useful to you.

How to build OpenSSL for WP8?

How to build OpenSSL for WP8?
AFAIK, we must replace winsock.h by winsock2.h because WP8 only supports winsock2.h. And maybe we must replaces code to target WinRT architecture on WP8 (ThreadPool, ...)
The caveat is that we must build OpenSSL as WP8 static library, so that the output lib can be wrapped by WP8 runtime component, right ?
You can use the Microsoft openssl fork on github with support for windows phone 8.1/8.0 and Windows Store 8.1, that address the entropy on each platform using windows random generators, instructions are located at INSTALL.WINAPP, there is a script located at
ms\do_vsprojects.bat
you should be able to just execute that script withing the root location and open vsout\openssl.sln to build the openssl libraries for different windows platforms.
The fork is located at
https://github.com/microsoft/openssl
At this momment these changes are being in process to be integrated with the main OpenSSL source code base.
here is what you have to do, go to this link and download the VSbuild, now put that into the source files downloaded from the OpenSSL website, the folder structure should look like this:
apps
bugs
certs
.....
vsbuild
once that is done, open the solution, it should upgrade it to VS12, change the settings to a Windows Phone RT build, to generate DLL's there is no need to build *_lib*, so change the other projects, most changes you need to do are to libeay32, do not compile openssl project, just ignore that, start by building libeay32, and start making changes to the code, as there are some functions we don't have in WinRT, you can either #ifdef them out, or create your own functions,
NOTE for rand_win.c change the functions to use rand_s and #ifdef most of the code there is, this might muck up the security, you will have to test it out yourself
Good Luck !
This is so that if anyone wants to build the new version of OpenSSL "1.0.1g" that fixes the Heartbleed problem you can follow the previous steps whit the following changes:
I renamed the folder include to --include and create a new folder named include, the VS project will take care of copying the information, --include if you like you can remove this, when i build the project without this change there where compilation issues.
Note: the include folder that i changed is the one found in the root not the one found under VSbuild
Enjoy
Here is a download of pre-compiled OpenSSL libraries for Windows Phone 8.1 among other platforms:
https://www.teskalabs.com/blog/openssl-binary-distribution-for-developers-static-library
Disclaimer: I run that site.