• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 728
  • Last Modified:

Multi threading in console?????

Hiya there...
We have an application in DOS and we need to port it to linux console, i have few question about it:
First dose the console support multi threading and tasking???

It is important to us (as you know dos dose not support it and we need this support)

Second: what do i need to run minimal linux (somthing like dose, only the OS files and the libs that ill need)
it should be something about ~1mb of OS files
is it possible????

Thanks for any help.
kishk91
0
kishk91
Asked:
kishk91
1 Solution
 
interiotCommented:
Yes, and Yes.

A linux console program is no different than a linux GUI program, other than the mechanism for communicating with the user.  Console programs support threads, and multiple console programs can be running at once (for instance, several users can telnet in at once and run different programs).

There are many floppy-sized distributions available.  Check out http://directory.google.com/Top/Computers/Software/Operating_Systems/Linux/Distributions/Tiny/.
0
 
edvinkvCommented:
yes. you will have to write x-window code in motif or other x-widnow libarary.
Off late threading is possible in x-windows.

You can get a tool called sun sparc visual workshop which has all the tools and
libraries to code x-window threads.

and there are many micro kernel linuxes available these days. linux has even
been ported into a watch sized computer. just give a search for micro linux on
google.com

Thanks
Edvin.
0
 
garbouaCommented:
sure you could have multithread in console mode.  check out pthread, "man pthread" or check it on the web www.humanfactor.com/pthread.
edvinkv
you don't need x-window to run multi thread application.

check out pocket linux, it should install in 2.5 minutes,
http://www.tux.org/pub/distributions/tinylinux/pocket-linux/
0
 
kishk91Author Commented:
Hi thank you all for your answers..

Today we compile our dos based applicatin in GCC... do you think that ill have problem porting it to linux???
i know that linux has GCC too...

And please forgive me for dumb question.. programming in linux is new to me...

1000's thanks
kishk
0
 
garbouaCommented:
your code should be fairly clean from compiler's specific, but if it isn't, you will have to change your makefile anyway, you know directory structures and stuff "c:\some\src" and "/view/dosApp/src/"  as you can see the difference between the two.  
now if you dos code was written long ago, meaning folks did not pay attention to software engineering  standards about code being "portable" and not to use  OS specific functions and stuff.
it should port find, with some work from you side, but it should work okay, specially if it is a dos cosole.
Programming in linux in no difference than any platform, you just have to "wing it" :-), no once you get the hang of it, You will like the OS, and its ability to do what you desire.  the OS behave like its native language C, it would do what you tell it, regardless of what your intention were, so be carefull.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now