C++ and JAVA in Suse 10.1 ??

Status
Not open for further replies.

DukeNukem

Come get Some
Hie Bro's an chicks

can any one tell me how to write and compile and run prog. made in c++ and java in Suse 10.1 from suse command prompt. (first part "write" i can do myself)
 

mehulved

18 Till I Die............
Use gc++ for c++ and for java you can use either sun-java or gcj.
GCC(GNU Compiler Collection) has lots of tools for various programming language.
Besides you can use IDE's like Ajunta.I guess Eclipse will be too slow to run on your system, but it's another good tool.
 
OP
DukeNukem

DukeNukem

Come get Some
Sir
can you please tell me the procedure (if any) to compile and run the Progs in suse command prompt
(like "bc.exe myfirst.cpp" or "javac file.java" or java file"")
 

mediator

Technomancer
1. Fire up the terminal
2. Change the directory to the working (c++ files containing) directory
3. If the file's name is something like
( C ) a. "dukenukem.c" , then type "gcc dukenukem.c -o dukenukem"
(C++) b. "dukenukem.cpp" then type "g++ dukenukem.cpp -o dukenukem"
4. "Enter" ur done!
5. To run the file now just type "./dukenukem" and enter! Bingo

Here dukenukem is output file name and can be given any name and "-o" is the ouput parameter. If u wont give the output paramtere and output filename then default output file created is "a.out"!

compiling java files is same as in windows!
 

mehulved

18 Till I Die............
for c++ *people.cs.uchicago.edu/~jacobm/linux_programming.html it's section 2,4 & 5 that you need to look at. Section 2 lists some CLI editors, but you can use GUI ones if you find CLI editors difficult to start with.
for java. use some package manager like yum or smart(i am using smart on suse 10 and it's good) and install sun-java-jdk or java-xxx-sun-devel, by whatever name it is listed. Then you can open up the terminal and you will have access to all the tools in sun's jdk.
 
OP
DukeNukem

DukeNukem

Come get Some
mediator said:
1. Fire up the terminal
2. Change the directory to the working (c++ files containing) directory
3. If the file's name is something like
( C ) a. "dukenumem.c" , then type "gcc dukenukem.c -o dukenukem"
(C++) b. "dukenukem.cpp" then type "g++ dukenukem.cpp -o dukenukem"
4. END

Here dukenukem is output file name and can be given any name and "-o" is the ouput parameter. If u wont give the output paramtere and output filename then default output file created is "a.out"!

compiling java is same as in windows!

Thanks A Lot Bro.
 
OP
DukeNukem

DukeNukem

Come get Some
tech_your_future said:
for c++ *people.cs.uchicago.edu/~jacobm/linux_programming.html it's section 2,4 & 5 that you need to look at. Section 2 lists some CLI editors, but you can use GUI ones if you find CLI editors difficult to start with.
for java. use some package manager like yum or smart(i am using smart on suse 10 and it's good) and install sun-java-jdk or java-xxx-sun-devel, by whatever name it is listed. Then you can open up the terminal and you will have access to all the tools in sun's jdk.


Thanks Sir thanks
 

Desi-Tek.com

In the zone
use vi editor to write program

eg fif file name is test.c

than compile it using following command

gcc - o test test.c

and type
./test
to run that program.

how to compile java program

javac javaFilename.java
 

JGuru

Wise Old Owl
For Java use NetBeans IDE 5.0 BlueJ Edition , download it from here
It's light-weight Java IDE , also very easy to use. For C/C++ use Anjuta.
Download Anjuta from here .There is also Eclipse IDE for Java & C++,
but it needs 512 MB RAM, also it consumes lot of resources.
 

aku

Gonna make it BiG
hey.. hw 2 work wid sql in linux.. since im havin rdbms and sql in my syllabus. btw, my school uses oracle.. so is there gonna be any diff. in case of sql (the default one in linux, not externally installed app) in linux and oracle in windows?
btw its oracle 8i
 

mehulved

18 Till I Die............
There's no such thing as internal sql. Most of the distros come with MySQL. See *dev.mysql.com/ for more on MySQL. Here's the link to MySQL manual *dev.mysql.com/doc/refman/5.1/en/index.html just compare it with Oracle and see. I don't have much clue. I am too bad at DBMS.
You also have other kinds of DBMS's on linux like PostgreSQL and even Oracle. Get oracle 10g Express Edition for linux from here *www.oracle.com/technology/products/database/xe/index.html
Also see this *linas.org/linux/db.html for more on DBMS in linux and do a little bit of googling for more answers.
 

mediator

Technomancer
@aku, mysql and oracle have only a minor difference! Neways oracle is still the best. But mysql is better for practising in mah opinion.

For running and working on mysql study this thread!
*www.thinkdigit.com/forum/showthread.php?t=36218&highlight=mysql

Have fun!
 

Desi-Tek.com

In the zone
@mediator mySql and oracle has majour difference not minor
Comparing mysql with Oracle
and
Why PostgreSQL can best SQLServer, as Oracle


*www.thinkdigit.com/forum/showpost.php?p=325660&postcount=8
 

mediator

Technomancer
^^Whateva u say sir! BUt that difference is not much visible to noobs to sql, does it? I know mysql has less features. But to start with mysql is best in my opinion and so is Postgresql. Also php stands nicely with mysql, remember the LAMP??
So u dont have to start a debate here for mysql Vs oracle as everybody knows which is the best!
 
Last edited:
Status
Not open for further replies.
Top Bottom