Compiling in Linux - Printable Version +- VadaVaka (https://vadavaka.com/forums) +-- Forum: General Forums (https://vadavaka.com/forums/forumdisplay.php?fid=5) +--- Forum: IT-Geeks Hang Out (https://vadavaka.com/forums/forumdisplay.php?fid=42) +---- Forum: Programming (https://vadavaka.com/forums/forumdisplay.php?fid=27) +---- Thread: Compiling in Linux (/showthread.php?tid=2786) Pages:
1
2
|
Compiling in Linux - evil_admin - 06-23-2003 Well, I have started down the road of being a GNU Geek. I have Redhat 8.0 installed on a dual boot computer with Win2000. I am getting the feel of the KDE GUI and thought I was ready to play with the C++ compiler to get kermit's and my changes onto GRITS servers, thought being the operative word. Here is the short version. Apparently to compile any half-life, an old version of the GCC compiler is required. I have found and d/l and now need to install. Next I will start trying to compile the Makefile but from talking to other coders on the HLCoder email list it will not be easy. I have yet to hear from anyone who has actually done it...not to say they aren't out there, they obviously are but it will not be a quick an easy process. Just wanted to keep everyone up on what I was doing. Other than any server/admin fires, this is my number one focus. desNotes Compiling in Linux - Guest - 06-23-2003 hmm. If you want, provide me with the links to what you have used, and I will see how bad it actually is... I am interested in this as I want to make sure that the script I've done will actually compile before I send it over... and I wouldn't mind locally testing it first.:) Compiling in Linux - evil_admin - 06-23-2003 Here is what Valve says about compiling in Linux: HL SDK 2.3 Linux compile notes ------------------- The source code distributed with the HL SDK contains two portions that may be compiled under Linux: the game DLL and the server launcher. The game DLL code is located in the dlls/ directory and the server launcher code is located in the dedicated/ directory. A Makefile has been provided for each of these. One issue that needs to be addressed before compiling under Linux is DOS style carriage return (^M) characters. DOS (and hence MS Windows) text files contain this carriage return character at the end of every line, in addition to the standard linefeed character. Most compilers, preprocessors, and make utilities that are used under Linux are confused by these characters, emitting strange warning and error messages when compiling is attempted. The solution is to remove these characters from all source, header, and makefile files. One way to do this is to use an FTP utility to transfer each source, header, and makefile file individually in ASCII transfer mode (as opposed to binary mode, which is often the default) to the Linux development machine. Another way of removing these unwanted characters is using an application designed specifically to remove them. Many people have written programs to do this. A simple search on any major Internet search site (such as http://www.google.com) for 'dos2unix' or other related keywords should turn up useful information about obtaining one of these programs. The other area of concern when compiling under Linux is the compiler itself. The Half-Life source code seems to be problematic for many compiler versions. The recommended compiler to use is EGCS 1.1.2, or a GCC version based on EGCS 1.1.2 (if using gcc, try 'gcc -v' to see version information). Newer and/or older versions of GCC/EGCS (or other compilers) may or may not work. If problems are encountered with another compiler version, the EGCS 1.1.2 compiler can be found on the GCC project's FTP server, or on any of its mirrors. A mirror list can be found at http://gcc.gnu.org/mirrors.html. EGCS 1.1.2 will be located in an 'old-releases' section on any mirror site. Compiling in Linux - GRITS - 06-23-2003 :heartbeat::wub::heartbeat: Compiling in Linux - PIX - 06-23-2003 Keep on talkin Evil....I'm gettin hot now...:P Compiling in Linux - GRITS - 06-23-2003 Not nice to pick on the Queen.:P Compiling in Linux - PIX - 06-23-2003 who's pickin on j00?? Shop talk gives me............ Compiling in Linux - Guest - 06-23-2003 That's quite useful, thanks pix..:) Compiling in Linux - PIX - 06-23-2003 You should be welcome...I just saved my post from being edited.:P Compiling in Linux - kermit - 06-23-2003 you ever saw the movie "airplane". anyways, i'm going to paraphrase leslie nielson and say the following regarding the urgent need to compile a working server .dll in linux: "i just wanted to let you guys know...good luck and that we are all counting on you" ^_^ anytime you get frustrated w/ the whole thing...remember that! Compiling in Linux - PIX - 06-23-2003 "A HOSPITAL...what is it doctor???? " "It's a big building with lots of patients, but that's not important right now." One of my favorite movies. OJ was a great actor in it....he wasn't even killing anybody. Compiling in Linux - Guest - 06-24-2003 Smoking or non-smoking? Compiling in Linux - GRITS - 06-24-2003 Ok I am getting ready to split this topic to "off topic" I wanna see some real answers here please Compiling in Linux - Guest - 06-24-2003 Ok, seriously, I am going to have to check disk space usage, etc, as I only have a 1GB hard drive... so I don't get to install all the necesities of KDE, etc. Now, though, I'm wondering if that is actually a requirement... gonna read up on all the SDK stuff tonight. Compiling in Linux - Guest - 06-24-2003 TuxPortal is an interseting website, and Slack ( [email protected] ) has a few things to say about compiling, most of which are repeated from all the readme's actually, but I think I might fire an email off and see if I can get any other info about what's going on. I did notice, however, that he said he had to go back to an older compiler under Slackware after upgrading from 7.1 and as I have 9... then I guess that means I'll have to too... Out of interest evil, what happens when you do gcc -v? Compiling in Linux - evil_admin - 06-24-2003 I will have to give you the details when I get home but when I did that the version is much higher than the readme's are saying to use. Since I am such a newbie at this I am having trouble just installing the older version of the gcc compiler. Compiling in Linux - PIX - 06-24-2003 Have you tried to edit the code manually with Notepad and NO NO NO DON'T use wordpad. Word pad will put in those carrage returns, notepad wont. Can you not physically edit these flaws and then upload in ASCII mode using ftp client. Can you not do the editing ON the linux box using Pico or vi. I always prefer to do my edits and Makefile fine tuning right on the box. I guess the key is you have a windows based SDK and you are making all changes through that. Then you are uploading the source to the linux box for compiling. Do they make a SDK for linux?? Lemme check something. BRB. I'm putting this on to our development engineers here to see wut they think also. We'll get a brotha hooked up G. lol I was told that the dos2unix program is what you need. plain and simple. Compiling in Linux - Guest - 06-24-2003 Nooooo... simply upload all the source files to your server in ASCII mode. Provided that is done, the extra ^m characters are stripped automatically. Now, as for editing on windows a file that's on there, I'd suggest textpad since it can do color coding, etc. And if you need a *cough* key *cough* let me know....:) Compiling in Linux - Guest - 06-24-2003 Oh, I forgot to mention that Textpad will recognise UNIX style formatting (ie, without the ^m characters). FTP in ascii mode is the way to go. I'm firing up Slackware now... give me an hour and I'll see what I've got onto the box.:) Compiling in Linux - Guest - 06-24-2003 Ok, I would have, but even to get something simple on my system seems to require half a dozen stuff I didn't bother, so I have a feeling I am going to have to reinstall, which means in turn that it won't be tonight nor tomorrow.... :/ I really do need to see if I can find a larger HD too... Compiling in Linux - Guest - 06-25-2003 Steps I took on Windows: [*]Downloaded SDK and installed to C:\HalfLife\SDK [*]Uploaded the Multiplayer Sources to Slackware 9 using FTP in ASCII mode (I use LeechFTP) Steps I took on Slackware 9: [*]Downloaded egcs-1.1.2.tar.gz [*]unpackaged using: tar -zvxf egcs-1.1.2.tar.gz [*]configured using: ./configure [*]compiled using: make My next step was to: [*]get dressed as it was 9:30 [*]head to work as it's now past 9:30 :-D [*]long to do more as I was getting somewhere Compiling in Linux - Guest - 06-25-2003 Did you get: Code: /root/egcs-1.1.2/gcc/xgcc -B/root/egcs-1.1.2/gcc/ -c -g -O2 -fvtable-thunks -D_GNU_SOURCE -fno-implicit-templates -I. -I. -nostdinc++ -D_IO_MTSAFE_IO indstream.cc Compiling in Linux - Guest - 06-25-2003 Having done a bit of a google search on the above errors, I found that Tim Price had something to say about this... though I think he overlooked that some software requires it for legacy's sake.... tried that.. gonne check on it shortly to see how it got on. Compiling in Linux - Guest - 06-25-2003 Code: make[2]: Entering directory `/root/egcs-1.1.2/i586-pc-linux-gnubio' Still seems to be a problem with libio... Time to read the documentation in full me thinks. Compiling in Linux - Guest - 06-25-2003 found some useful Configuration and Build FAQ's that are under the INSTALL directory. Reading the specific configuration page, it suggests that for NeXT's OS, you should be doing: [*]cd objdir [*]make all-texinfo all-bison all-byacc all-binutils all-gas all-ld [*]cd gcc [*]make bootstrap [*]make install-headers-tar [*]cd .. [*]make bootstrap3 The same *might* be true for backwards compatibility... testing now. Compiling in Linux - Guest - 06-25-2003 And guess what....... Compiling in Linux - PIX - 06-25-2003 FASTER......FASTER NetIV......work faster !!!!;) Compiling in Linux - Guest - 06-25-2003 Whose this NetIV guy? A fourth incarnation of me? Anyway, it didn't work :/ Compiling in Linux - PIX - 06-25-2003 sorry old chap....i just type faster than i think. Comes with the age ya know. ;) Compiling in Linux - Guest - 06-25-2003 I know, I'm getting there, sometimes words and even whole sentences disappear and I haven't a clue what I did with them... |