View Poll Results: Have you found this information useful

Voters
114. You may not vote on this poll
  • Yes, Very insightful

    66 57.89%
  • No, Confussing as hell

    48 42.11%
Page 2 of 4 FirstFirst 1234 LastLast
Results 11 to 20 of 39

Thread: HOWTO: Compile source code

  1. #11
    Join Date
    Oct 2007
    Location
    Rotherham, UK
    Beans
    28
    Distro
    Ubuntu 7.10 Gutsy Gibbon

    Re: HOWTO: Compile source code

    Thanks.. This has gave me a little insight into how you actually do this.

  2. #12
    Join Date
    Aug 2007
    Beans
    10

    Re: HOWTO: Compile source code

    I needed the very latest source code, so I actually found this most helpful,

  3. #13
    Join Date
    May 2005
    Location
    Cydonia
    Beans
    Hidden!
    Distro
    Xubuntu

    Re: HOWTO: Compile source code

    Quote Originally Posted by pay View Post
    Also
    Code:
    sudo apt-get –build source
    will make a generic debian package of the source code.
    Can you elaborate more on this? Does it create Debian standard debs? Do you do it to the source package or the source folder?

  4. #14
    Join Date
    May 2008
    Beans
    154

    Talking Re: HOWTO: Compile source code

    Quote Originally Posted by Endolith View Post
    Why do people persist in using the command line for EVERYTHING? This is not helpful at all.
    On the contrary. I'm generally new to the linux scene, having migrated recently from Vista and having been a long time GUI user.

    I personally find how-to's with command line a heck of a lot easier, faster, and more efficient to follow/execute than a GUI-based tutorial as you can accomplish with one copy/paste what takes a series of 10-50 mouse movements and button clicks. Also you don't have to wait for any GUI windows to load before you can click one checkmark and dismiss the window. It's just an extra --OPTION=parameter setting, which is all part of the single copy/paste action.

    With a command-line copy/paste it's simply faster and easier to get the job done.

    You might not be ingraining the GUI-method into your memory, but every time you read "wget (address-of-remote-file)" you understand more and more what it does and how to use it. (Likewise with any other command-line code) so instead of building your memory based on the slow and inefficient way of doing things, you're building your memory based on the professional, fast, effective way to do things and when you're proficient enough to do it professionally, you're getting 20 minutes work done in 5 by using the command line and thus your time can be worth a lot more money. Even if you're not doing it professionally, it's just good sense to learn the RIGHT way from the start.

    Moreover, GUI's change from version to version. Command-line typically stays the same. If tutorials were mainly based on GUI's they'd have to be updated constantly.

    I definitely agree that this tutorial is a bit too specific and also a bit too ambiguous in some areas but even as a linux freshman I have to say I prefer command-line-based how-to's nine times out of ten.

    One last note: if you actually bite the bullet and make an effort to type out the commands instead of just copy/pasting then you will learn a LOT faster and you'll learn the back-end commands that all the various GUI's use so it won't matter what program/GUI you're trying to work with, you'll know the methodology of getting the job done. As I say I'm new to linux but just by typing out command line instructions for the past couple weeks I've already gotten to the point where I can perform most actions without having to go back and re-consult the walk-through (and in a lot of cases without having to bring up a walk-through at all in the first place).

  5. #15
    Join Date
    Feb 2007
    Location
    New York
    Beans
    894
    Distro
    Ubuntu 9.10 Karmic Koala

    Re: HOWTO: Compile source code

    Quote Originally Posted by the real omni View Post
    You might not be ingraining the GUI-method into your memory, but every time you read "wget (address-of-remote-file)" you understand more and more what it does and how to use it.
    A good computer interface wouldn't require you to learn about how the program works in order to use it.

    so instead of building your memory based on the slow and inefficient way of doing things, you're building your memory based on the professional, fast, effective way to do things
    A good computer interface wouldn't require the memorization of cryptic commands to get things done. The GUI is a better, more efficient interface because it's discoverable. You don't have to read through a manual to figure out how to do something; in a well-written program, it's obvious what you can do from the options presented to you.

    Moreover, GUI's change from version to version. Command-line typically stays the same.
    Not only do command line tools change from version to version, they change from one program to another. Each has its own idiosyncratic switch syntax that differs from all the rest, requiring you to memorize a separate set of code letters for each program (even for similar options). It is not an intuitive or usable interface, and we should not be recommending it to new users unless no other option exists.

    Teaching new users to copy and paste arbitrary commands from the Internet into a terminal without understanding what they do creates a very dangerous mentality that opens them up to exploitation by malicious users. See this notice for an example.
    "Please remember to do things the Ubuntu way. There is always more than one solution to a problem, choose the one you think will be the easiest for the user. ... Try to think as a green user and choose the simplest solution." — Code of Conduct

  6. #16
    Join Date
    Nov 2007
    Beans
    1,818
    Distro
    Ubuntu 11.10 Oneiric Ocelot

    Re: HOWTO: Compile source code

    Quote Originally Posted by Endolith View Post
    A good computer interface wouldn't require you to learn about how the program works in order to use it.
    Well, a good interface might. But a great one will give you a choice as to whether you want to use a GUI or CLI. And it makes all the documentation for either readily available either on the system (man pages or help menus) or online. That way you can choose which you want.

    A good computer interface wouldn't require the memorization of cryptic commands to get things done. The GUI is a better, more efficient interface because it's discoverable. You don't have to read through a manual to figure out how to do something; in a well-written program, it's obvious what you can do from the options presented to you.
    Well, true. And one thing you have to remember is that you are posting this in a HOWTO for compiling. That is a command line set of instructions. And you really don't need to know how to compile unless you need something really special. For example, if you need a application that is not in the repos, is not available in a convienient DEB, or you need something fully optimized. So, most users don't really need to know this. But if you wanted to make a simple little Python GUI for compiling and keep it up, I'm sure you would have the love of the people.

    Not only do command line tools change from version to version, they change from one program to another. Each has its own idiosyncratic switch syntax that differs from all the rest, requiring you to memorize a separate set of code letters for each program (even for similar options). It is not an intuitive or usable interface, and we should not be recommending it to new users unless no other option exists.
    Well, not true really for Linux. CLI commands change very little from version to version. And many applications are similar for similar tasks. For instance: APT, Aptitude, and dpkg all have similar CLI phraseology for handling packages. Also, when you do something wrong in CLI it often spits out an error along with help as to how to do it right. I think that qualifies as intuitive.

    Teaching new users to copy and paste arbitrary commands from the Internet into a terminal without understanding what they do creates a very dangerous mentality that opens them up to exploitation by malicious users. See this notice for an example.
    All good points. That's why most of the push is to make HOWTOs GUI unless you need the CLI for some reason. Also, most good HOWTOs explain what the commands mean instead of just "copy this into the terminal."

    And I'm sure you'll agree that no amount of security software will stop this kind of "social engineering." The only answer is a slightly questioning mindset and plenty of good instruction. And I believe that Linux, and especially Ubuntu is pretty far along with this. There's so many places to get good information and help from seasoned users.

  7. #17
    Join Date
    Jan 2009
    Location
    Colorado
    Beans
    60
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: HOWTO: Compile source code

    Thank you Pay for taking the time to write this "How To". I did find some of the paragraphs confusing but I found something that compliments your article. Try
    http://tuxarena.blogspot.com/2008/09...buntu-and.html

    as it also provides alittle more information to what the first part of the sudo apt-get install build-essential does and how to compile a easy "Hello world!" application.

    Regards.

  8. #18
    Join Date
    Jan 2009
    Location
    Colorado
    Beans
    60
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: HOWTO: Compile source code

    I also ran across this:
    http://coderstalk.blogspot.com/2008/...amming-in.html

    Here he explains the code from:
    http://linuxgazette.net/issue74/tougher.html

    The first link listed on this post will direct you on how to start off writing your first socket program. Sockets are used to communicate across a network. This enables more than one computer to talk to each other. I would be more than happy to help anyone with questions. This program was simple enough for me to compile and fix the few bugs I encountered.

    I'm very new to this stuff also so please have patience for me as well

  9. #19
    Join Date
    Jun 2005
    Beans
    203
    Distro
    Ubuntu 8.10 Intrepid Ibex

    Re: HOWTO: Compile source code

    I just had to reply to this howto as some of the comments here are asinine. First off, Pay, thanks for the effort. This is actually pretty useful. I forgot how to create debs from source so it was nice to see a reference to that here.

    For those of you who are whining about how hard linux aps are to install realize that Ubuntu has the Add/Remove Software feature specifically for you! You don't even need to fire up Synaptic to install apps. It can't get any easier than that.

    Also realize that the ability to compile your software out-of-the-box is an AMAZING feature of gnu linux. It's not straight forward to get a c compiler going in windows, and you are probably going to need to fork over $$ to get one. The gcc compiler in linux is simply an added bonus. You absolutely don't need it to run 99% of the apps you'll use. Most projects have binaries available, and they install just like .exe windows files.

    Pay is just trying to help you out if you like running bleeding edge apps or want to install something more obscure that's not in the repos. It's really only going to help you if you have some curiosity to learn a little more about the system you're using. Linux is the ultimate power users/hacker os. The command line stuff should be for fun hacking, use the repositories if you want things to 'just work' quickly.

    -bt

    edit: lol, I didn't realize this was resurrected from months ago.
    Last edited by BIGtrouble77; January 17th, 2009 at 02:37 AM.
    Lenovo s10 Netbook: Jaunty
    Desktop: Jaunty amd64

  10. #20
    Join Date
    Dec 2007
    Location
    Canada
    Beans
    74
    Distro
    Lubuntu 13.04 Raring Ringtail

    Re: HOWTO: Compile source code

    Just wanted to add my thanks for this quick tutorial - it came up at the top of my Google search.

    All I was looking for was a quick example of "what do they mean when they say compile from source?" This tutorial fit the bill just fine. Now, I've got the source for the package I'm interested it, its dependencies, and I'm well on my way to figuring out the rest. Thank you.

    Oh, and off-topic but as a professional Windows tech that makes a living installing and supporting software, I firmly believe Ubuntu is way, way, way easier to install software -- just hit the check-box and then OK. It makes the Windows EULA-hell/option-overload OK, OK, OK, OK... look totally stupid. I can get a complete (apps included) install of Ubuntu up and running with less than 5% of the effort involved with Windows, just because I don't have to sit there going OK, OK, OK. Best of all, Ubuntu has an OPTIONAL command-line interface that offers huge amounts of power. And, if I really want to, I can download the source, modify it or some compile options, and then make my own package, which is not off-topic at all

    David (an Ubuntu convert, can you tell?)

Page 2 of 4 FirstFirst 1234 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •