Qt Installation Issues

29 views
Skip to first unread message

Josh Maggart

unread,
Mar 29, 2012, 4:01:23 PM3/29/12
to feetwe...@googlegroups.com
Hey Robert & Janice,

It was great meeting you guys last night and looking forward to working with you guys on FWC and RHCSA stuff.

Just a note:  I was trying to follow the Qt Install guide on the FWC page and it was going fine on the Mac I am using right now, except that it let me know that I didn't have a C++ compiler installed.  I am assuming I just need to follow the instructions to install them most up to date Xcode but I just wanted to let you know.  I can update this post with the results if you'd like me to.

Hope this helps!

Josh Maggart

unread,
Mar 29, 2012, 4:29:07 PM3/29/12
to feetwe...@googlegroups.com
I am trying to download Xcode which is what the Qt installer suggested but it is taking FOREVER through the app store.  Any suggestions on a good compiler?  Do I need an IDE as well?  Thanks!

Robert Holder

unread,
Mar 29, 2012, 7:17:50 PM3/29/12
to feetwe...@googlegroups.com, Josh Maggart

At dentist will respond in detail shortly :-)

--

Sent from my Nokia N9

Janice Dugger

unread,
Mar 29, 2012, 8:41:43 PM3/29/12
to FeetWetCoding
Hi Josh, it was great meeting you, too! :-)

Thanks so much for the feedback. I recently ran into the same issue on
Ubuntu, but I didn't think to check the mac. When I installed Qt SDK
on my mac I already had XCode so I didn't see it. We're going to need
to update our documentation to help with this extra step of finding
and installing a compiler.

You're probably done downloading XCode by now, but just in case, you
might check out this short thread:

http://stackoverflow.com/questions/2122425/how-do-i-install-g-on-macos-x

...in particular this segment:

> To install g++ _without_ having to download the MASSIVE xCode install, try this package:
> https://github.com/kennethreitz/osx-gcc-installer

> It's basically a script that repackages just the critical chunks of xCode for distribution. ie, building the pkg requires an xCode install, which is why > the built DMG files are hosted on the project page.

I haven't tried this myself but I thought maybe it could help you.

Thanks again for trying to work through the issues. Your feedback is
really helpful!

Janice

Janice Dugger

unread,
Mar 29, 2012, 9:24:59 PM3/29/12
to FeetWetCoding
Oh, I forgot to answer your IDE question. We've designed FeetWetCoding
to work with the QtCreator IDE, which comes with the SDK. It's fairly
simple to use and after configuring it to find your compiler, it
should work with no need to configure where the Qt libraries are. I
would recommend trying to use QtCreator first, and see if you like it.
If you really wanted to configure a different IDE (e.g. XCode) then
you might be able to get that to work, too, but we've never tried it
so we probably wouldn't be able to offer as much help with IDE issues
in that scenario.

Here are the notes I jotted down when I was configuring the compiler
to use with QtCreator on Ubuntu. Hopefully they'll be of some help to
you:

In QtCreator 2.4.1 (for mac):
  1) Qt "Creator->Preferences..." menu item
-- (Note to others: It's "Tools->Options" on Windows and Linux)
  2) Select the "Build & Run" option about midway down on the left
  3) Click the "Tool Chains" tab
  4) Click the "Add" button on the right

Here's where it gets a little fuzzy since I can't simulate your exact
setup on my own mac...

A drop-down menu under the "Add" button should list some compilers for
you to choose from. Hopefully you'll find the one you intend to use,
whether it's gcc, g++, etc. I don't know if XCode is a compiler or
just the IDE, so it might not be listed. QtCreator might even auto-
detect your compiler(s) once you've installed them, in which case you
should see some information under the "Auto-detected" heading in the
main panel. (After installing your compiler you might try exiting out
of QtCreator and restarting it in case that triggers it to search
known locations for compilers). If it doesn't auto-detect anything,
you can select one of the compilers in the "Add" menu and manually
configure it by clicking the name in the main panel under the "Manual"
heading, and typing in the path to that compiler and debugger. If
you're not sure where your compiler is, you might look through the
XCode configuration and see if you can find it there.

Once you get your compiler configured you'll hopefully be ready to go.
You should be able to open the FeetWetCoding project by double-
clicking the "FeetWetCoding.pro" file in the project directory. (Note
to Linux users: This doesn't always work on Linux and you might have
to open QtCreator manually, then load up the project using the "Open
File or Project" menu item.)

Please let us know if you have any more questions as you proceed.

Thanks!
Janice

Josh Maggart

unread,
Apr 2, 2012, 1:01:17 AM4/2/12
to feetwe...@googlegroups.com
Hey Janice,

Finally got around to configuring Qt for GCC and as you mentioned Qt auto-detected the compiler. However, when I followed the next directions to double-click the .pro file it brought up this:

So hopefully you can tell that this is the Qt Creator but anyway, after I selected the .pro file all it open was this and I had to guess I was supposed to press the "green play" arrow to get it started.  Once I did that I gave a message that said "building" and eventually your program came up.

This probably sounds vague and ambiguous but hopefully it makes some kinda sense.

Hope this helps!

On Thursday, March 29, 2012 2:01:23 PM UTC-6, Josh Maggart wrote:

Robert Holder

unread,
Apr 2, 2012, 6:56:59 PM4/2/12
to feetwe...@googlegroups.com
Hey Josh!  :-)

That screen that came up when you doubleclicked the FeetWetCoding.pro file is the Qt Creator IDE, where you will make changes to the code.  The basic cycle is:

1) Edit a C++ source file (ending in .cpp)
2) Click the green "Build & Run" arrow in the lower left corner of the Qt Creator IDE window
3) See if the program is doing what you want (select Chapter, Section and Exercise in the dropdown buttons at the top of the running fwc program)
4) If your changes worked, congratulations!  :-D  If not, return to step 1

The first exercise to start with is in Chapter01, Section02, 010_ChangeText.cpp:



...so it looks like you are ready to start hacking!  Hit me up anytime you see me online on g+ chat for either text chat, or video hangout where we can share screens.  I find the screensharing thing in g+ hangouts to be very useful!  You have to install a plug-in to use g+ hangouts.  When I installed it, and when a friend installed it also, it acts like it's installing but never finished, so I had to run the hangout plug-in installer from my chrome file download list at the bottom of the browser window.

--r

Robert Holder

unread,
Apr 2, 2012, 7:00:08 PM4/2/12
to feetwe...@googlegroups.com
Crap, I missed a step in the "basic development cycle" list in my previous message:

1) Edit a C++ source file (ending in .cpp)
2) Click the green "Build & Run" arrow in the lower left corner of the Qt Creator IDE window
3) See if the program is doing what you want (select Chapter, Section and Exercise in the dropdown buttons at the top of the running fwc program)
4) If your changes worked, congratulations!  :-D  If not, then:
5) Exit the running feetwetcoding executable (NOT the Qt Creator IDE) and THEN return to step 1  :-)

Janice Dugger

unread,
Apr 2, 2012, 8:40:13 PM4/2/12
to FeetWetCoding
Hey Josh,

Thanks for the info--it doesn't sound vague or ambiguous at all, it's
very helpful. It sounds like you saw exactly what you were supposed to
see, but it also sounds like you weren't really sure whether you were
seeing the right thing or not. That tells me that we need to make our
documentation simpler and more straightforward, so that's our plan.
We're going to shorten it and emphasize that "basic development cycle"
that Robert described.

I hope you have fun trying some of the exercises. As always, don't
hesitate to ping us if you have any questions or comments.

Thanks!
Janice

On Apr 1, 11:01 pm, Josh Maggart <josh.magg...@gmail.com> wrote:
> Hey Janice,
>
> Finally got around to configuring Qt for GCC and as you mentioned Qt
> auto-detected the compiler. However, when I followed the next directions to
> double-click the .pro file it brought up this:
>
> <https://lh4.googleusercontent.com/-92-93iytyRg/T3kvCDty5QI/AAAAAAAAAW...>
Reply all
Reply to author
Forward
0 new messages