Install Cygwin on Windows PC to learn Objective-C


⛏️ This post may be a bit out-dated as iOS programming have moved to Swift and you can learn it on the Windows Operating system as well - https://swift.org/blog/swift-on-windows/.

If you want to learn Objective-C, the language for developing apps for Mac OS and iOS, but you don't have a Mac? Well, there is an out. You can install GCC (GNU Compiler Collection) Compiler for Windows which will let you execute your Objective-C code. To get started quickly all you need to do is download Cygwin: tools which provide a Linux look and feel environment for Windows and also include the compiler for Objective-C and libraries.

Steps to install Cygwin on Windows PC :

Step 1. Download Cygwin setup : 32-bit setup | 64-bit setup

Step 2. Run Cygwin.exe,Click Next.

cygwin_screen1.jpg
cygwin_screen1.jpg

Step 3. Select "Install from Internet", Click Next.

cygwin_screen1.jpg
cygwin_screen1.jpg

Step 4. Choose root directory, Click Next.

cygwin_screen2.jpg
cygwin_screen2.jpg

Step 5. Choose Package installation directory, Click Next.

cygwin_screen2.jpg
cygwin_screen2.jpg

Step 6. Choose Direct Connection, Click Next

cygwin_screen2.jpg
cygwin_screen2.jpg

Step 7. Select any mirror site

cygwin_screen2.jpg
cygwin_screen2.jpg

Step 8. Certain packages will be downloaded from the next,may take a min.

cygwin_screen2.jpg
cygwin_screen2.jpg

Step 9. Expand Devel and select gcc-objc, gcc-objc++, gdb and make, Click Next

cygwin_screen2.jpg
cygwin_screen2.jpg
cygwin_screen2.jpg
cygwin_screen2.jpg
cygwin_screen2.jpg
cygwin_screen2.jpg

Step 10. Click Next

cygwin_screen2.jpg
cygwin_screen2.jpg

Step 11. This Step will take some time (needs patience here!)

cygwin_screen2.jpg
cygwin_screen2.jpg

Step 12. That's it, now you would have the "Cygwin Terminal" icon on your desktop. Let's try running a sample code to see if all is fine. You need to place your "hello world" program under the "home/User/" dir where Cygwin is been installed.

Hello World in Objective-C on Windows!
Hello World in Objective-C on Windows!

Keywords & hashtags: #cygwin, #bash, #installation


Comments:

  • Is this relevant in 2020? I don't think so... why can't you just buy a Macbook and learn to program for macOS or iOS, Swift is the programming language you need to look for.
    anon 10 July 2020 11:21:13 GMT
  • Further comments disabled!


Have Questions? Post them here!
Advertisements
Try Out Code2care Dev Tools:

Advertisements



Android Java Linux Microsoft Google Python macOS Notepad++ Microsoft Teams CSS PHP SharePoint Html Linux C Programs Bootstrap jQuery Sublime Android Studio Facebook Eclipse WhatsApp News MySQL Json HowTos JavaScript FTP S3


Advertisements


Code2care is an initiative to publish and share varied knowledge in programming and technical areas gathered during day-to-day learnings and development activities.

Students and Software Developers can leverage this portal to find solutions to their various queries without re-inventing the wheel by referring to our easy to understand posts. Technical posts might include Learnings, Tutorials, Trouble-Shooting steps, Video Tutorials, Code Snippets, How Tos, Blogs, Articles, etc.
🎉 We are celebrating the 10th years of Code2care! Thank you for all your support! We hope we made a difference.
We strong support Gender Equality & Diversity.

We stand in solidarity with Ukraine - Make a donation to UNHCR - https://donate.unhcr.org/in/en-in/ukraine-emergency