Thread: Free C++ Compiler?

  1. #1
    Registered User
    Join Date
    Mar 2006
    Location
    USA::Colorado
    Posts
    155

    Free C++ Compiler?

    Hello,

    I'm working on a c++ project at school but the only compilers I can find require an installation. The administrators have disabled installations for non-administrator users.

    I know on linux you can simply do "gcc file.cpp" to complile it, but I was unable to find something like that for windows xp. (I can use the terminal to compile something).

    Any help will be greatly appreciated,

    Thanks,

    Matt N
    ~guitarist809~

  2. #2
    Unregistered User Yarin's Avatar
    Join Date
    Jul 2007
    Posts
    2,158
    Disabled installations how? There most likely is a way around it.

    I don't think you have to install TurboC, but it's very old.

  3. #3
    Registered User
    Join Date
    Mar 2006
    Location
    USA::Colorado
    Posts
    155
    I don't know how they did it. I've tried to install many programs (such as firefox, bloodshed c++ compiler) and it says "You do not have the proper privleges to install this. Contact you system administrator for more information." Or something along those lines.

    There's gotta be a compler that you can just copy the execuable and necessary library files and then just make a batch file to do "gcc file.cpp".

    I'll give TurboC a try
    ~guitarist809~

  4. #4
    Officially An Architect brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,396
    MinGW might be usable without "installation." Failing that maybe you can find a gcc binary out there somewhere, but you still need a standard library (headers and library archives). A compiler binary all by itself isn't enough to create useful programs.

    Have you tried asking if you can install something? If they expect you to write code, it seems reasonable that they should let you install a compiler.

  5. #5
    Registered User
    Join Date
    Mar 2006
    Location
    USA::Colorado
    Posts
    155
    It's a weird situation. Usually im in the "tech" lab writing out the code, but thats full so I'm stuck in the library to do my work. I asked and they said to ask the tech person - no idea who that is...

    I was just hoping there was a .zip file with the library headers and a compler =\
    ~guitarist809~

  6. #6
    Officially An Architect brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,396
    Quote Originally Posted by guitarist809 View Post
    It's a weird situation. Usually im in the "tech" lab writing out the code, but thats full so I'm stuck in the library to do my work. I asked and they said to ask the tech person - no idea who that is...

    I was just hoping there was a .zip file with the library headers and a compler =\
    Do you have access to a UNIX account somewhere? You could just ssh there and do development remotely.

  7. #7
    Registered User
    Join Date
    Mar 2006
    Location
    USA::Colorado
    Posts
    155
    I don't even think DOS supports ssh. My school's blocked all ports except 80, i think ssh is either 22 or 23 =[
    ~guitarist809~

  8. #8
    Officially An Architect brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,396
    Quote Originally Posted by guitarist809 View Post
    I don't even think DOS supports ssh. My school's blocked all ports except 80, i think ssh is either 22 or 23 =[
    You might be able to find a web-proxy that lets you shuttle an ssh connection over port 80

  9. #9
    Deathray Engineer MacGyver's Avatar
    Join Date
    Mar 2007
    Posts
    3,210
    Don't use Turbo C. Don't use real DOS. Use Windows XP or something modern.

  10. #10
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    http://clusty.com/search?query=onlin...Mozilla-search

    Or get your own machine and do whatever you want to do.

    Or complain to the college about not providing enough resources.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  11. #11
    Registered User mikeman118's Avatar
    Join Date
    Aug 2007
    Posts
    183
    Well, if you really wanted me to I could put the entire Microsoft Visual Studio Express Edition (which is free) into a zip file, however, that could possibly be illegal/bad so does anyone have an idea whether or not that's bad?

  12. #12
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    Obvioulsy, the term "installation" can be interpreted in many ways, but I believe that ALL compilers require installation in some way or another. Certainly gcc on Linux does - it just happens to be part of what is often installed by default.

    You are very unlikely to find any compiler that can be installed without "installing". Now there's of course a question as to what the system admin software constitutes as "installation", and what is just copying files from one place to another. Without knowing that, it's almost impossible to give you a "right answer".

    For example, I'm 100% sure that any of the gcc-variants (mingw for example) that run on Windows can be "instlaled" entirely without touching any files in \windows (or \winnt in relevant cases), which may be one reason for requiring "installation".

    On the other hand if "copying executable files or DLL's" to the machine is what's considered "installing", then the likely answer is that "you can't do that".

    Edit: Mikeman: "Redistributing" Visual Studio Express is definitely outside the allowed activities in the End User License Agreement.

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  13. #13
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,895
    Windows doesn't have umasks as far as I know, so nothing can stop the user from copying an executable to his home directory and executing it. Installation actions that require admin access are copying files to the Windows directory and modifying the registry tree outside the user-specific root.

    MinGW ought to work without these, but actually getting it to run could be tricky.
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

  14. #14
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    Quote Originally Posted by CornedBee View Post
    Windows doesn't have umasks as far as I know, so nothing can stop the user from copying an executable to his home directory and executing it. Installation actions that require admin access are copying files to the Windows directory and modifying the registry tree outside the user-specific root.

    MinGW ought to work without these, but actually getting it to run could be tricky.
    Actually, windows support ACL (Access Control Lists) which theoretically can be used to restrict anyone from doing just about any file access model ever considered [and a few no one would ever even dream of in a high fever nightmare, probably].

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  15. #15
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,895
    Didn't think of that, yeah. You can stop a user from executing files except in special directories. (I was thinking about masking the permissions, though. Which is different, in a way.)
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Best C compiler (free)
    By esbo in forum C Programming
    Replies: 11
    Last Post: 06-11-2007, 10:38 PM
  2. "if you love someone" :D
    By Carlos in forum A Brief History of Cprogramming.com
    Replies: 12
    Last Post: 10-02-2003, 01:10 AM
  3. Compiler Design... Anyone That Can Help!
    By ComputerNerd888 in forum C++ Programming
    Replies: 3
    Last Post: 09-27-2003, 09:48 AM
  4. EzWindows and Borland 5.5 free compiler
    By savageag in forum C++ Programming
    Replies: 0
    Last Post: 09-15-2003, 09:49 PM
  5. free c++ compiler?
    By sayword in forum C++ Programming
    Replies: 4
    Last Post: 09-06-2003, 10:49 PM