Target "debug" doesn't exist in the Project - ant

I have tried to create APK file using the "ant debug" command. But when i tried i got the following error
Build Failed
Target "debug" does not exist in the Project "androiddemo"
Total Time: 0 Seconds
Build Failed
Target "release" does not exist in the Project "androiddemo"
Total Time: 0 Seconds
Checked with release command also. Getting the same error. Could you please guide me to get APK file of Android application

I did a stupid mistake with my command. The actual command is
"ant -debug"
But APK file is not created. Is anything i missed in that?

Related

I can't start fastlane iOS build. gym ends up with error [duplicate]

following is the error in xcode
I have also tried build legacy from workspace settings but failed to do so.
Multiple commands produce '/Users/saifubaid/Library/Developer/Xcode/DerivedData/antispam-bjwrxskogxnnophfhgkpyxxcqcuj/Build/Intermediates.noindex/ArchiveIntermediates/antispam/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/AccessibilityResources.bundle':
Target 'React-Core.common-AccessibilityResources' has create directory command with output '/Users/saifubaid/Library/Developer/Xcode/DerivedData/antispam-bjwrxskogxnnophfhgkpyxxcqcuj/Build/Intermediates.noindex/ArchiveIntermediates/antispam/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/AccessibilityResources.bundle'
Target 'React-Core.common-CoreModulesHeaders-AccessibilityResources' has create directory command with output '/Users/saifubaid/Library/Developer/Xcode/DerivedData/antispam-bjwrxskogxnnophfhgkpyxxcqcuj/Build/Intermediates.noindex/ArchiveIntermediates/antispam/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/AccessibilityResources.bundle'
stuck on it. tried almost every solution.
Multiple commands produce '/Users/shubhamnagota/dev/zest/zest-app/ios/DerivedData/zestapp/Build/Intermediates.noindex/ArchiveIntermediates/zestapp/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/AccessibilityResources.bundle':
Click on Pods App
From the list remove React-Core-AccessibilityResources
Clean Project
Build Again
Archive.
Worked for me! :)

Can't build and run react-native project on Mac

Referring this issue, I've the same problem. I've MacOs El Captain on VMware.
Node v. 7.8.0
npm v.4.6.1
react-native-cli 2.0.1
react-native 0.46.4
Xcode v. 8.2.1
I've two issues:
- when trying to init a new react-native project, the packages fetching hangs on getting react-native 0.46.4 package from repo. Other packages were downloaded successfully. So I've execute npm install from Windows and then copied the node_modules folder on Mac.
- when trying to run the project on iOS simulator I recieve the following error:
** BUILD FAILED **
...
In file included from /Users/michelebombardi/Desktop/ReactNativeProjects/caliup/node_modules/react-native/React/../third-party/folly-2016.09.26.00/folly/Bits.h:70:
/Users/michelebombardi/Desktop/ReactNativeProjects/caliup/node_modules/react-native/React/../third-party/folly-2016.09.26.00/folly/detail/BitIteratorDetail.h:21:10: fatal error: 'boost/iterator/iterator_adaptor.hpp' file not found
#include <boost/iterator/iterator_adaptor.hpp>
The following build commands failed:
CompileC /Users/michelebombardi/Desktop/ReactNativeProjects/caliup/ios/build/Build/Intermediates/React.build/Debug-iphonesimulator/third-party.build/Objects-normal/x86_64/Conv.o /Users/michelebombardi/Desktop/ReactNativeProjects/caliup/node_modules/react-native/third-party/folly-2016.09.26.00/folly/Conv.cpp normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)
Installing build/Build/Products/Debug-iphonesimulator/CaliUp.app
An error was encountered processing the command (domain=NSPOSIXErrorDomain, code=2):
Failed to install the requested application
An application bundle was not found at the provided path.
Provide a valid path to the desired application bundle.
Print: Entry, ":CFBundleIdentifier", Does Not Exist
Command failed: /usr/libexec/PlistBuddy -c Print:CFBundleIdentifier build/Build/Products/Debug-iphonesimulator/CaliUp.app/Info.plist
Print: Entry, ":CFBundleIdentifier", Does Not Exist`
I really need to publish my app on the app store before the end of the week.
I've already try all suggested solutions but nothin works.
Could anyone help me?
First try this:
watchman watch-del-all && rm -rf node_modules
If you install node using Homebrew uninstall it and install node from here.(https://nodejs.org/en/)
Now if you used yarn to install node modules:
Try npm install
This error is caused by a failed third party library download in the build step. In your home folder there should be a ~/.rncache directory with a number of compressed C++ libraries. The error occurs when one or more of these files fails to download completely from the github amazon s3 servers. (likely in China)
The problem sticks around because the script in the react-native xcode build doesn't know how to resume the broken download. So you can fix this by deleting your ~/.rncache folder and because these folders are extracted into your modules you should also rm -rf node_modules and reinstall.
More info can be found here and here
May be this will work. Try these steps:
Backup your icons, images etc from ios folder.
Check that app name is set for key "name" in {project-root}\app.json file.
Delete ios/ and android/ directories
Run react-native eject
Replace the icons,images etc you copied earlier
Run react-native link
Launch you app from Xcode using short cut key command+r

Error while trying to run script in Xcode for firebase crash reporting

I am trying to integrate the crash reporting of firebase in my project. Though I am successfully getting the crash report in the firebase console I seem to get these 3 errors:
/Users/human/Library/Developer/Xcode/DerivedData/DummyProject-cousedziotoermfdyvgdmbmchdta/Build/Intermediates/DummyProject.build/Debug-iphoneos/DummyProject.build/Script-45E477EF1D33D4631052B160.sh:
line 3: /Users/human/DummyProject/ServiceAccount.json:
Permission denied
cat: : No such file or directory
Command /bin/sh emitted errors but did not return a nonzero exit code
to indicate failure
How do I resolve these errors?
I followed these instructions in firebase
Try the following:
Replace the Run Script build phase you added in Step 3b of the instructions with the simplified:
"${PODS_ROOT}"/FirebaseCrash/upload-sym
In short, delete everything but the last line. This will put upload-sym in interactive mode. If you did not use Cocoapods to install FirebaseCrash, use the full path to the upload-sym script where you installed the framework.
Delete any cached credentials you may have accidentally added:
/bin/rm -f $HOME/Library/Preferences/com.google.SymbolUpload.plist
/bin/rm -f $HOME/Library/Preferences/com.google.SymbolUploadToken.plist
Do a build. When the Run Script build phase starts, you will be prompted with a dialog for the location of the JSON credential file you downloaded in Step 1 of the instructions. You will only be prompted once. Future builds will have the information in the credential cache. If you have permission problems, make sure you have the right JSON file and repeat step 2 above.
What is your "Debug Information Format" set to in your Xcode Build Options? If it’s set to only "DWARF" it will show this erros during build. You could set to "DWARF with dSYM File" errors should disappear.

Permissions error in Jenkins when building CocoaPods based Xcode workspace

I'm trying to setup Jenkins to compile an iOS Xcode project. The xcode project uses CocoaPods. However, I get this error in Jenkins when I attempt a build. All files in the Pods/ directory have full write/read/execute permissions. Any thoughts?
/bin/sh -c /Users/Shared/Jenkins/Library/Developer/Xcode/DerivedData/MyApp-dripdwqnufuksvhcfgcgxajaahyq/Build/Intermediates/MyApp.build/Debug-iphonesimulator/MyApp.build/Script-EAAE77068BA044C9B06632CE.sh
/Users/samy/Work/mobile/iphone/MyApp/Pods/Pods-resources.sh: line 5: /Users/samy/Work/mobile/iphone/MyApp/Pods/resources-to-copy-MyApp.txt: Permission denied
** BUILD FAILED **
The following build commands failed:
PhaseScriptExecution Copy\ Pods\ Resources /Users/Shared/Jenkins/Library/Developer/Xcode/DerivedData/MyApp-dripdwqnufuksvhcfgcgxajaahyq/Build/Intermediates/MyApp.build/Debug-iphonesimulator/MyApp.build/Script-EAAE77068BA044C9B06632CE.sh
(1 failure)
Build step 'Xcode' marked build as failure
Finished: FAILURE
"Full read/write/execute permissions" for whom? Which user? Jenkins usually runs under it's own user, called jenkins
The only workaround I came across was to move the entire Xcode project to jenkins user directory.
You might want to add a custom build setting PODS_ROOT
PODS_ROOT=$(PROJECT_DIR)/Pods

The following build commands failed

I hope someone can help me. I'm really crazy, I've tried everything.
A few days ago installed Titanium Studio on my Mac, then install Xcode. I created a "single window Application Project". Without touching anything special puslo RUN> iOS Simulator> iPhone Retina (3.5 inch).
The program begins to build until the prompt type:
[INFO]: Invoking xcodebuild
[ERROR]: ** BUILD FAILED **
[ERROR]: The following build commands failed:
[ERROR]: Ld build / Debug-iphonesimulator / helloworld.app / helloworld Normal i386
[ERROR] (1 failure)
I updated all Xcode and everything related to Titanium.
Is there any solution?
I have read a lot a lot many forums, but I have not found any solution that works. I have cleaned the build folder, and even fails.
Can you think of anything?
Try installing the command line tools for Xcode. Xcode -> Preferences, Downloads.
Also try checking if you have a folder that has the same name as the app itself?
For me this was a caching issue causing the build to fail.
Delete all DerivedData from your Library root folder
rm -rf /Users/<Your Username>/Library/Developer/Xcode/DerivedData/*
Obviously, replace <Your Username> with whatever your username is (if you're not sure, just run the $ whoami command)
We need to clean cache
If you're using npm
watchman watch-del-all; npm start -- --reset-cache;
If you're using yarn
watchman watch-del-all; yarn start --reset-cache;
Re-install pods
cd ios; pod install; cd ..;
This worked for me at the very least.

Resources