Which version of apache ant is compatible with OS X 10.7.5? - xcode

I've had so much trouble in installing ant. I first downloaded it from the apache website, had some errors. Then I finally figured out a way to install through terminals 'brew install ant'; which it worked after downloading Xcode and configuring bash_profile.
So my question is, why does it show that the version is 1.8.2? instead of 1.9.7? Is this a compatibility issue?
This is my output

To my knowledge, All OS X versions prior to 10.9 have ANT already installed. From 10.9 and later , we need to install ANT.
Installation ANT is about extracting tar file, setting ANT_HOME variable, Setting path and setting JAVA_HOME as well.
In my view, you are already seeing an older version of ANT installed in your machine by default. However, ANT 1.8.x or 1.9.x both are pretty stable and should able to meet your build automation objectives.

Related

Fastlane fails on Jenkins google-api-client-0.38.0 requires ruby version ~> 2.4

As a proof of concept, I successfully built a local Jenkins server on my MacBook (MacOS is Catalina) and the pipeline uses Fastlane scripts to clone, build, and distribute successfully.
Now, I have a Mac Server in our Data Center and I completed the same build-out and installed Jenkins. When I run the same pipeline, it fails, so I tried executing from the command line and it fails with this error:
google-api-client-0.38.0 requires ruby version ~> 2.4
Apparently, my install used ruby 3.0, so I followed recommendations to install rbenv and down level to 2.4. the installers were successful, but still the problem persists and uses ruby 3.0. The paths defined in my profiles look correct.
There are two key differences between my local server and the server in the data center that I can think of that may be influencing this problem:
My MacBook was upgraded to Catalina where the DataCenter iMac was built factory-fresh with Catalina. Note that an Apple version of ruby is installed with Catalina.
I do not have Xcode installed, only the CLI xcode-select version 2373; I would like to keep the IDEs off of this server, so there isn't a temptation to fix code on this dedicated Jenkins server.
Any recommendations to further troubleshoot this installation?
First, you probably will have to install Xcode, to use all of its tools (the CLI won't cut it). I recommend xcode-install to manage xcode versions via CLI. That is one key difference in your setup.
However, there're probably shenanigans with your $PATH environment within Jenkins. From what I understood from your description, you were able to run fastlane normally by invoking it via Terminal, but it won't work in Jenkins, is that right? Check the $PATH in Jenkins and make sure it matches the $PATH in your Terminal. rbenv and other ruby version managers require you to execute some startup code (e.g. eval "$(rbenv init -)" in case of rbenv) before being able to use it, and then setting up the right $PATH is required to make everything work as expected (i.e. have it point at Ruby 2.4 instead of 3.0).

Apache Ant 1.9.6 Installation on Mac OSx - Does not run - Command not Found

I downloaded and installed apache ant 1.9.6 on my Mac OSx El Capitan 10.11.3 in /usr/local/, added the path to the bash_profile, however, I am unable to make it run. I get the following message back, as opposed to the version
-bash: ant: command not found
I did a lot of stackoverflow, however, couldn't find solution to this.
This is how my /usr/local looks:
This is how my bash_profile parameters for apache ant looks:
# Apache Ant
export ANT_HOME=“/usr/local/ant”
export PATH=$PATH:$ANT_HOME/bin
Could you please give me any hint that you may have.
Thank you.
Remove the quotes when you set ANT_HOME
It should be
export ANT_HOME=/usr/local/ant
This is only tangentially related to your issue, but you may want to look into homebrew, using this package manager on my mac I simply do
brew intall ant It gets your PATH setup automatically.
It also lets you upgrade to future versions with brew upgrade ant
The detailed and easy steps of installing ant using homebrew on Mac OSX is already discussed here:
How can I install Apache Ant on Mac OS X?
I installed homebrew and I was able to successfully install ant using homebrew package.

Installing Bakefile in Mac osx 10.11

I have been trying to install bakefile(v0.2.9) in mac osx 10.11. Whenever I try to install bakefile using the dmg file I get The installation failed.The installer could not install the software because there was no software found to install error.
I even tried building it from the source code(v1.2.5.1 from github). I built it using the sudo make command.However sudo make install command throws No rule to make target install.
Is there any other way to install bakefile in macosx 10.11?
Edit :
Finally I managed to install the bakefile 0.2.9 in osx 10.11. I can't use the latest version as it does not supports the bakefile we have been using in our projects.
Though the installation is successful,I get the segmentation fault 11 when I try to build the bakefiles(.bkl). Some of the forums suggested that the problem could be associated with python 2.7. I followed all the steps needed to resolve the issue. But none of them helped.
I have been using python 2.7.11. How can I avoid this segmentation fault?
I advice against using the legacy 0.2.9 version.
I even tried building it from the source code(v1.2.5.1 from github).
You didn’t, that’s the problem — you tried to build a very different version, 0.2.9 != 1.2.5.1. The relation between these two branches is explained at http://bakefile.org — they are incompatible and different.
If you want to build 0.2.9 from sources, you need to download and build 0.2.9.
If you want to use the 1.x version, you can download packaged “binary” version, as explained at https://github.com/vslavik/bakefile
P.S. You don’t need to, and shouldn’t, use sudo when installing somewhere you typically have access to, such as /usr/local on OS X.

Git for Mac fails to launch: "illegal instruction"

...I've looked pretty carefully (I believe), and have been unsuccessful at getting an installation of Git for my Mac.
For various reasons, I'm running 10.6.8 of Mac OS X and will not be changing that anytime soon.
I've already gathered and installed the bundle exposed here:
https://help.github.com/articles/set-up-git
The installation instructions are pretty clear, and it's obvious to me that the package installed. But any attempts to use the git client from the command line result in an "Illegal Instruction" error.
I've sifted pretty carefully through information available here:
http://git-scm.com/book/en/Getting-Started-Installing-Git
There is another bundle that seems to be available. It is called "GitHub for Mac 1.7.5, but it appears to require Mac OS X 10.7 or later.
Has anyone else encountered this difficulty? Must I build from source?
I'm a couple of hours of reading and hacking into this effort? Is there something obvious that I've not considered?
Yes, I've had the same exact problem, and what I did is installed an earlier build from here:
https://code.google.com/p/git-osx-installer/
I'm running 10.6.8 and installed the newest build there, 1.8.4.2
SourceForge only has 1.9.0 and 1.8.5.2
http://sourceforge.net/projects/git-osx-installer/reviews?source=navbar
Someone on the reviews said they had trouble with both and went back to 1.7. I would try that if 1.8.4.2 doesn't work.
I was able to run the config commands without an illegal instruction error, at least.
I had this problem and was able to install a working version using Homebrew.
# first uninstall the broken version
# mount the DMG for the broken version using Finder
# "type" this with the tab key! it saves typing and fixes the version number
cd /Volumes/Git\ 2.0.1\ Snow\ Leopard\ Intel\ Universal/
./uninstall.sh
# make bash forget about the uninstalled binary
hash -r
cd
# now install the working version
# assumes you have Homebrew installed
brew install git
git version
I had this today on Snow Leopard after running the suggested git installer from git-scm. Really horrible. Found that installing Macports using their old Snow Leopard package and then
sudo port install git +svn +doc +bash_completion +gitweb
installs git plus its dependencies and git now works fine; version 1.9.3 installed and working on 10.6.8.
I had the same problem. There are various methods for downloading and installing git - Try macports or homebrew. The thing that finally worked for me was having xcode 3.2.6 installed with the additional command line tools - version 3.2 that comes with the leopard install disk wasn't enough. You can install xcode etc. from the disk and then run software update to upgrade it to 3.2.6.
The latest build for Snow Leopard in the official git-osx-installer repo is Git 2.3.5 currently. You can download it from http://sourceforge.net/projects/git-osx-installer/files/git-2.3.5-intel-universal-snow-leopard.dmg/download using web browser. This installation works for me on OS X 10.6.8.
Or you can check yourself for a newer version: http://sourceforge.net/projects/git-osx-installer/files/
Yes - it seems that it does not support the older OS version (mine was 10.6.8). I upgraded to the newest Mac OS 10.9.4 (the installation will take a while), reinstalled the Git software (note that it will ask for xcode to be installed, which I proceeded), and everything works fine from there. Hope this helps.
Ref : https://help.github.com/articles/does-github-for-mac-run-on-os-x-10-6-snow-leopard
To quote:
Does GitHub for Mac run on OS X 10.6 Snow Leopard?
No, GitHub for Mac requires OS X 10.7 (Lion) or higher.
We made this decision because the app relies on a number of
technologies which are not available in Mac OS X 10.6 or earlier. We
want to provide the best experience possible for the app's users, so
we've made the choice to only support 10.7 and above, and not make
earlier versions available.

How to downgrade JRE/JDK on Mac OSX?

Does anyone know how to downgrade the version for JRE/JDK from 1.6.0_24 to 1.6.0_18 on a Mac OSX thru Terminal? I need to downgrade in order to get a Java applet working in Firefox. Any help would be much appreciated.
That does not seem to be accurate any more.
I just managed to downgrade both JRE and compiler from Java 8 to 7 by looking into /Library/Java/JavaVirtualMachines, and moving away the directory with the highest version number, e.g.
sudo mv jdk1.8.0.jdk ~/Desktop/
That's easy. You have to remove de .jdk directory of the JDK 7 in /Library/Java/JavaVirtualMachines.
Now you only have to install the version you like.
=)
More info:
http://docs.oracle.com/javase/7/docs/webnotes/install/mac/mac-jdk.html#uninstall
If the older JDK isn't on your machine, you'd need to use the GUI and download the Java updater. The one closest to yours I could find was for Java 1.6.0_15 for Mac OS 10.5 (you didn't mention which Mac OS X version you were running):
Java for Mac OS X 10.5 Update 5
I didn't see any for Mac OS X 10.6. For that, you would probably have to download the updaters for each 10.6 release, and extract the JDK installer from the updater (using something like Pacifist
Oh, and if you haven't already, try running /Applications/Utilities/Java Preferences.app, which lets you change the default Java on your machine amongst the ones you have installed.
Hope this helps...
I removed the JavaAppletPlugin:
/Library/Internet Plug-Ins/JavaAppletPlugin.plugin
and all 1.8 JDKs:
/Library/Java/JavaVirtualMachines/jdk1.8.0_45.jdk
/Library/Java/JavaVirtualMachines/jdk1.8.0_60.jdk
Then I was able to re-install 1.7.
To downgrade your JDK you will need the JDK installation package and an app called Pacifist, available from http://www.charlessoft.com/ . The usage is pretty straight forward. I have used it to downgrade my JDK before.
Which version of firefox are you running?
I believe you can have more than one version of jdk/jre on a machine as long as you specify the path when compiling/running. However, the jvm is bundled with mac which makes this problematic.
This post may be helpful
How to install a specific JDK on Mac OS X?
These days MAC OS comes with latest java version(8 or later).
Even if you install the old versions, it points to the Newest version. All it need is just pointing to the old version. To downgrade to any version that is preinstalled is to create a symlink of that version.
Follow these simple steps to downgrade your java version.
(1) cd /System/Library/Frameworks/JavaVM.framework/Versions
(2) sudo bash
(3) rm Current
(4) ln -s 1.6.0/Contents/ Current
(5) java -version
This will point the java to last update in java6. And now update all the paths.
Hope it might be helpful and let me know if it works...:)
There is no downgrade mechanism for what you want to do.
The typical suggestion is to roll back to the version you want either through Time Machine or by reinstalling and only update selectively to the version you need by downloading explicitly from Apple and not updating Java through software update.
I'd recommend you look into the problem instead. If you cannot run this in Firefox, then try with Chrome or Safari. If it is the mixed code issue, then this is changed in the Java Settings panel in Programs -> Utilities in the Advanced panel.
I've had the very same problem. You can open the JRE 1.6.0_20 image file with Pacifist software and extract all the folders with the framework into the \System\Library\Frameworks\JavaVM.framework\Versions folders. After that the JRE should appear in your Applications/Utilities/Java Preferences JRE selection menu, where you can switch between the running JRE's.

Resources