code logs -> 2007 -> Sat, 13 Oct 2007< code.20071012.log - code.20071014.log >
--- Log opened Sat Oct 13 00:00:39 2007
00:01 Chalcedon is now known as ChalcyNap
01:03 Thaqui [~Thaqui@Nightstar-26433.jetstream.xtra.co.nz] has joined #code
01:03 mode/#code [+o Thaqui] by ChanServ
01:20 ChalcyNap is now known as Chalcedon
01:21 * gnolam sighs over GCC's need for the One True Linking Order.
01:45
<@Vornicus>
suck
01:47 gnolam [lenin@Nightstar-10613.8.5.253.static.se.wasadata.net] has quit [Quit: Z?]
02:14 Chalcedon is now known as ChalcyNap
02:27
< Mischief>
Is anyone able to make a skeleton for a 3D model?
03:50 ChalcyNap is now known as Chalcedon
05:03 Chalcedon is now known as ChalcyAFK
05:50 GeekSoldier|bed is now known as GeekSoldier
06:19 Vornicus is now known as Vornicus-Latens
06:22 Thaqui [~Thaqui@Nightstar-26433.jetstream.xtra.co.nz] has left #code [Leaving]
06:39 Vornicus-Latens [~vorn@ServicesOp.Nightstar.Net] has quit [Ping Timeout]
06:39 Mischief is now known as Felyn
06:52 You're now known as TheWatcher
07:54 Vornotron [~vorn@Admin.Nightstar.Net] has joined #code
07:55 Vornotron is now known as Vornicus-Latens
08:53 ChalcyAFK is now known as Chalcedon
09:21 Chalcedon [~Chalcedon@Nightstar-2310.ue.woosh.co.nz] has quit [Quit: Gone]
09:24 McMartin[NewYork] is now known as McMartin
10:03 Forj [~Forj@Nightstar-2310.ue.woosh.co.nz] has quit [Quit: Gone]
10:32
< Kyrre>
I am able, is this paid work?
10:33 gnolam [lenin@Nightstar-10613.8.5.253.static.se.wasadata.net] has joined #Code
10:33 mode/#code [+o gnolam] by ChanServ
11:12 ReivOut is now known as Reiver
12:20 GeekSoldier [~Rob@Nightstar-4759.pools.arcor-ip.net] has quit [Ping Timeout]
13:40 Reiver is now known as ReivZzz
13:54 GeekSoldier [~Rob@Nightstar-4629.pools.arcor-ip.net] has joined #code
14:21
<@ToxicFrog>
aaaaaagh
14:21
<@ToxicFrog>
Goatfucking ant!
14:22
< GeekSoldier>
java problems still?
14:22
<@ToxicFrog>
Yes.
14:22
<@ToxicFrog>
The project is code-complete.
14:22
<@ToxicFrog>
However, it needs to build under ant.
14:23
<@ToxicFrog>
...which has gcj as a dependency, which is, I admit, a problem with the Fedora maintainers and not ant per se...
14:24
<@ToxicFrog>
...and which insists on using gcj even though sun java is the one in PATH.
14:24
<@ToxicFrog>
Oh, and it has no man page.
14:25
< GeekSoldier>
ugh. so this is dependancy hell?
14:26
<@jerith>
ToxicFrog: Uninstall it and grab the one from jpackage?
14:26
<@ToxicFrog>
"jpackage"?
14:26
<@jerith>
jpackage is a third-party Java repo for Redhat/Fedora.
14:27
<@ToxicFrog>
Ooo
14:28
<@jerith>
Indeed.
14:29 * AnnoDomini eyes the asymmetric three-eyed monstrosity.
14:30
<@ToxicFrog>
...ok, jpackage looks like a hideous mess that doesn't support Java 1.6
14:30
<@jerith>
Pretty much.
14:30
<@ToxicFrog>
...
14:30
<@jerith>
But it's marginally less of a hideous mess than the default Fedora stuff.
14:30
<@ToxicFrog>
Why did you suggest it, then?
14:30
<@jerith>
Because it's marginally less of a hideous mess than the default Fedora stuff.
14:31
<@jerith>
Really, your best bet is to just not use rpms for any of the Java stuff.
14:31
<@jerith>
Or build the rpms yourself if you're on more than one box.
14:32
<@ToxicFrog>
Using the RPMs from Sun has, in fact, worked out pretty well.
14:33
<@jerith>
Last I checked the rpms from Sun didn't publish appropriate capabilities.
14:33
<@jerith>
So nothing could depend on them.
14:33
<@jerith>
Or something.
14:33
<@ToxicFrog>
Entire possible, however, I have yet to install anything that depends on them until now.
14:33 * jerith nods.
14:34
<@jerith>
The thing is, Fedora live entirely within the world of gcj.
14:34
<@jerith>
+s
14:42
<@ToxicFrog>
Having installed it by hand, ant is now working.
14:42
<@ToxicFrog>
Now comes the real pain.
14:46
<@jerith>
XML is not a programming language.
15:07
<@AnnoDomini>
Hm. What's the pseudocode operator for bit shifting?
15:08
<@jerith>
<< or >> for most stuff I've seen.
15:09
<@AnnoDomini>
Thanks.
15:49
<@gnolam>
Bitshifting is the only decent use of them.
15:50 * gnolam is not a fan of C++'s dirty hack of a stream system.
15:52 mode/#code [+oooooo Attilla EvilDarkLord GeekSoldier Kyrre ReivZzz Vornicus-Latens] by AnnoDomini
15:57
<@jerith>
I dunno. I quite like Erlang's binary syntax.
15:57
<@jerith>
<< 3/16, "foo" >>
16:00 Felyn is now known as Mischief
16:00
< Mischief>
Fear the Atomic Pickle!
16:00
< Mischief>
Sorry, that was completely random.
16:00 * jerith fears no pickle, no matter how atomic!
16:01
< Mischief>
You shall! When it blasts ye with gamma radiation!
16:01
< Mischief>
And turns you into some.. sick... pickle thrall
16:01
<@jerith>
I laugh in the face of gamma radiation!
16:02
< Mischief>
Well, I don't have anything to say about that.. Except..
16:02 * GeekSoldier would like a spectral pickle.
16:02
< Mischief>
Well, no, nothing. :P
16:02 * gnolam throws a vorpal gherkin at Mischief.
16:02 * Mischief dies?
16:03
<@gnolam>
If only. The vorpal gherkin is a fate worse than death.
16:03
< Mischief>
Doesn't it just dehead you?
16:03
< Mischief>
Inwhich, you have 5 seconds (or five minutes) aproximately to live.
16:04
< Mischief>
5 seconds of conciousness, five minutes until you're effectively mentally damaged. I think.
16:04
< Mischief>
Though, being deheaded, I don't the latter matters.
16:06 * Mischief tends to overcomplicate things, here, have a vorpal spectral atomic pickle +5 of Orc Slaying.
16:09
<@AnnoDomini>
Pickles can't be Vorpal.
16:09
<@jerith>
Why not?
16:12
<@AnnoDomini>
Because they don't do slashing damage.
16:15
< Mischief>
I don't know about your pickle, but my pickle has been sharpened
16:16
< Mischief>
It does 4d6 lethal pickle damage.
16:19
< Mischief>
Idly, morning everyone.
16:21
<@jerith>
Evening.
16:24 PZM [~PZM@Nightstar-6174.adsl196-15.iam.net.ma] has joined #Code
16:26 PZM [~PZM@Nightstar-6174.adsl196-15.iam.net.ma] has left #Code []
16:31 Zemyla [~nsJChat@168.53.174.ns-23174] has joined #code
16:44
<@ToxicFrog>
What the fuck, javadoc.
16:45
<@ToxicFrog>
class StoryElement;
16:45
<@ToxicFrog>
class MovableElement extends StoryElement;
16:45
<@ToxicFrog>
class Monster extends MovableElement implements Actor, Hittable, Hurtable;
16:45
<@ToxicFrog>
Javadoc generates:
16:45
<@ToxicFrog>
StoryElement
16:45
<@ToxicFrog>
+- Monster
17:28 * AnnoDomini is trying to grok how VHDL works, so far without much success.
17:29
<@jerith>
The main thing to remember is that by default, everything happens at the same time.
17:29
<@jerith>
Which is a bit confusing if you come from the world of sequential programming.
17:30
<@AnnoDomini>
Nono, I'm quite familiar with automatics and logic circuits.
17:30
<@AnnoDomini>
What I'm trying to understand is how VHDL translates into the mess of logic gates et all.
17:33
<@jerith>
Ah.
17:33
<@jerith>
Pretty much the same way a compiler turns code into asm.
17:35
<@AnnoDomini>
Perhaps I should rephrase. This explanation isn't going too well for me.
17:36
<@jerith>
I'm heading out now. Cheers all.
17:36
<@AnnoDomini>
I want to make an AND2 gate using VHDL, to get myself familiar with the language. So far, I don't really know where to start.
17:37
<@AnnoDomini>
The software I'm using is Altera MAX+plus II.
17:51
<@gnolam>
Well, are you trying to make an internal AND or should it interface with the outside world?
17:52
<@gnolam>
If the latter, you need to define an entity with the appropriate ports first.
17:54 * AnnoDomini looks at the exercise specification. Actually, an OR2, but no matter.
17:55
<@AnnoDomini>
gnolam: http://pastie.caboo.se/106905 <- Like this?
17:56 * gnolam nods.
17:57
<@AnnoDomini>
What now?
17:57
<@gnolam>
IIRC, the "entity" in "end entity" is superfluous though.
17:57
<@gnolam>
Ok, now you make an architecture.
17:59
<@AnnoDomini>
Where do I put it? Right after what I already have in the same file?
17:59
<@gnolam>
Yep.
17:59
<@gnolam>
Something like:
17:59
<@gnolam>
architecture wielki_cthulhu of or_2 is
17:59
<@gnolam>
--internal signals go here
17:59
<@gnolam>
begin
17:59
<@gnolam>
--do stuff
17:59
<@gnolam>
end wielki_cthulhu
17:59
<@AnnoDomini>
Wielki Cthulhu.
18:00 * AnnoDomini collapses in a fit of laughter.
18:00
<@gnolam>
+;
18:01
<@gnolam>
Well, I have to use what Polish I know, eh? ;)
18:01
<@AnnoDomini>
Yeah.
18:01
<@AnnoDomini>
How do I use bit_vectors?
18:02
<@AnnoDomini>
Or maybe I shouldn't use them yet. I'll stick to bits.
18:05
<@AnnoDomini>
Yay, more errors.
18:05
< Zemyla>
I know how to use bit vectors!
18:06
<@gnolam>
Either straight up by doing e.g. "if (my_vector = "00") then" or by index: "if (my_vector(0) = '1') then"
18:06
<@gnolam>
IIRc.
18:06
<@gnolam>
*IIRC
18:06
<@AnnoDomini>
Aha.
18:07
<@gnolam>
The first I'm sure of. The second could have a slightly different syntax. Been a while now. :)
18:07
<@AnnoDomini>
http://pastie.caboo.se/106908 <- What's wrong here?
18:10
<@gnolam>
Hmm. Missing semicolons in the port statement, no begins anywhere?
18:12 AD [AnnoDomini@Nightstar-28915.neoplus.adsl.tpnet.pl] has joined #Code
18:12
< AD>
Where should be semicolons be? I don't have a clue. What I did here is essentially copy/paste/modify variable names from a tutorial.
18:12
< AD>
Also, where should the begins we?
18:13 AnnoDomini [AnnoDomini@Nightstar-28966.neoplus.adsl.tpnet.pl] has quit [Ping Timeout]
18:13
<@gnolam>
One for the architecture, between lines 9 and 10, and one for the process.
18:16
< AD>
Could you please amend and repastie?
18:16 AD is now known as AnnoDomini
18:20
<@gnolam>
http://pastie.caboo.se/106909 ?
18:20 * gnolam is eating nachos and watching bad movies and is thus not quite paying attention right now.
18:21
< AnnoDomini>
Thank you kindly.
18:22
< AnnoDomini>
"Error: Node 'wy' missing source." <- That's what the compiler sez.
18:23
< AnnoDomini>
Nevermind. Finally grokked what I was doing.
18:27
< AnnoDomini>
Okay, it looks to be pretty much all in order, it compiled and built... but why the hell does it take whole 5 ns to change states?
18:28
<@ToxicFrog>
Simulator settings, probably.
18:28
<@ToxicFrog>
That kind of timing information is configured in the simulator.
18:35
< AnnoDomini>
Eh. I'll just get to making the other base gates so I have an easy time later.
20:24
< AnnoDomini>
Hrm. I want to use a previously made gates in a bigger project.
20:24
< AnnoDomini>
How do I do that?
20:24
< AnnoDomini>
The compiler says they're not declared.
20:29
< AnnoDomini>
Where and how should I declare them?
20:29
<@ToxicFrog>
You need a Component statement, as I recall
20:29
<@ToxicFrog>
Assuming this is VHDL
20:30
< AnnoDomini>
Yes.
20:30
<@ToxicFrog>
http://www.funkyhorror.net/toxicfrog/projects/cpu_vhdl.tar.gz -- there's some examples in here, I think
20:31 Vornicus-Latens is now known as Vornicus
20:32 Vornicus is now known as NSGuest-1571
20:32 NSGuest-1571 is now known as Vornicus
20:34 You're now known as TheWatcher[afk]
20:40 Forj [~Forj@Nightstar-2310.ue.woosh.co.nz] has joined #code
20:40 mode/#code [+o Forj] by ChanServ
20:46
< AnnoDomini>
Thanks.
21:05 mode/#code [+o AnnoDomini] by ChanServ
21:05
<@AnnoDomini>
http://pastie.caboo.se/106947 <- I keep getting an uknown error while trying to compile. What's wrong?
21:10
<@ToxicFrog>
"unknown error"?
21:10 GeekSoldier is now known as GeekSoldier|bed
21:12
<@AnnoDomini>
"Error: Unknown problem in...", etc.
21:12
<@ToxicFrog>
Never have I seen the like.
21:12
<@ToxicFrog>
What line?
21:15
<@AnnoDomini>
http://i24.tinypic.com/23tky0x.png
21:16
<@McMartin>
The etc. looks like a pretty specific problem
21:17
<@McMartin>
Though I know nothing of VHDL
21:17 Doctor_Nick [~nick@Nightstar-23600.hsd1.fl.comcast.net] has joined #code
21:18
<@ToxicFrog>
I have never seen an error like that and have no idea what it means.
21:19 * AnnoDomini neither.
21:19
< Doctor_Nick>
hey guys, i have a question about output redirection
21:21
< Doctor_Nick>
pastebin.ca/735650 <- this example closes stdout and opens up a file for output
21:21
< Doctor_Nick>
my question is, how do i reopen stdout after I'm done writing to the file?
21:22 mode/#code [+v Doctor_Nick] by gnolam
21:23 mode/#code [+o Doctor_Nick] by AnnoDomini
21:23
<@AnnoDomini>
gnolam: Can you see any obvious errors in my VHDL?
21:23
<@ToxicFrog>
Doctor_Nick: I'm not sure you can, but if you could, probably by opening /dev/tty
21:24
<@McMartin>
What happens if you dup stdout before closing fd 1?
21:24
<@ToxicFrog>
Also, why not use dup2() there?
21:24
<@Doctor_Nick>
mcmartin: lemme check
21:24
<@ToxicFrog>
Also also, why not dup2() stdout first?
21:24
<@ToxicFrog>
Also also also, why are you doing this rather than just opening the file in parallel?
21:25
<@ToxicFrog>
McMartin: it sticks around, if the man page is to be believed.
21:25
<@McMartin>
TF: You wouldn't dup2 stdout because you wouldn't want to *actually close* it.
21:25 Vornicus [~vorn@ServicesOp.Nightstar.Net] has quit [Ping Timeout]
21:25
<@Doctor_Nick>
ToxicFrog: You mean opening a file and then using write() to write to it?
21:25
<@ToxicFrog>
So you can dup2(1, 16); close(1); dup2(fd, 1); /* do stuff */; close(1); dup2(16, 1) /* now you have stdout back */
21:26
<@ToxicFrog>
McMartin: yes, exactly my point. By creating a duplicate first, close(1) merely frees the fd rather than closing stdout entirely.
21:26
<@ToxicFrog>
Doctor_Nick: quite.
21:26
<@McMartin>
Reading the description of dup and dup2, that doesn't seem to be the case, actually.
21:27
<@ToxicFrog>
Or using the 3-functions (fopen, fprintf) rather than the 2-functions (open, write)
21:27
<@Doctor_Nick>
good question
21:27
<@gnolam>
AnnoDomini: hmm.
21:27
<@Doctor_Nick>
ummm
21:27
<@McMartin>
close(1) appears to also close (16).
21:27
<@McMartin>
In your example, anyway.
21:27
<@ToxicFrog>
" If fd is the last copy of a particular file descriptor the resources associated with it are freed; if the descriptor was the last ref-
21:27
<@ToxicFrog>
erence to a file which has been removed using unlink(2) the file is deleted.
21:27
<@ToxicFrog>
"
21:27
<@ToxicFrog>
From close(2)
21:27
<@McMartin>
Er, my (1) was the line, not the man page section.
21:27
<@Doctor_Nick>
and I think fd2 opens up the new file stream automatically
21:28
<@gnolam>
Doctor_Nick: I have to ask. Why are you trying to close stdout?
21:28
<@ToxicFrog>
If I'm reading that right, that means that if you've copied the fd with dup() or dup2(), it won't actually close the underlying file associated with it - just the specific fd you called close() on
21:28
<@Doctor_Nick>
gnolam: output redirection for this shell program i'm working on
21:28
<@McMartin>
If it's in shell, redirect with > and <.
21:29
<@McMartin>
If it's in C, "redirect" by dumping the data on its own.
21:29
<@Doctor_Nick>
I'm writing A shell ;)
21:29
<@gnolam>
AnnoDomini: nope, can't see anything obviously wrong.
21:29
<@AnnoDomini>
Damn.
21:29
<@McMartin>
And if you aren't required to do so by an insane professor, for God's sake, use the stdio functions.
21:29
<@gnolam>
Remove the extra entity maybe? (Note: I'm just grasping at straws here)
21:29
<@Doctor_Nick>
McMartin: fopen, fclose?
21:29 * gnolam concurs with McMartin.
21:30
<@McMartin>
fopen, fclose, FILE *s, and their many, much more powerful output techniques.
21:30
<@gnolam>
Yes. fopen, fclose, fprintf, fwrite, etc.
21:30
<@McMartin>
Just remember to ensure that fprintf's second argument is always a constant string.
21:32
<@McMartin>
But the primary reason for using stdio is not for power, but because stdio is, unlike the UNIX system calls, actually standard across C implementations.
21:34
<@gnolam>
AnnoDomini: I'd try out some various changes myself, but I don't have anything VHDL-related on this computer. And I can't be arsed to unpack and boot up my university laptop.
21:34
<@McMartin>
If the line itself is OK, my guess is some kind of lexical error earlier on confused the Hell out of the Compiler.
21:35
<@McMartin>
Putting -- or forgetting -- the semicolon at the end of C++ class definitions was pretty famous for doing this.
21:35
<@gnolam>
Or it could just be general VHDL madness.
21:35
<@Doctor_Nick>
Toxic Frog: your example worked!
21:35
<@McMartin>
I have no experience with VHDL, but lots of experience with parsers~
21:35
<@ToxicFrog>
Doctor_Nick: excellent. Now throw it out and use stdio.
21:35
<@Doctor_Nick>
yeah
21:36
<@gnolam>
VHDL might have the worst internal consistency / syntax ratio of any language out there.
21:36
<@gnolam>
And the synthesizers tend to be... quirky.
21:36
<@McMartin>
TF: Incidentally, why would you dup2 stdio there? I can see dup2ing fd -- since you actually want it at point 1 -- but there seems to be no need to require your stdio backup to be in any specific location.
21:36
<@McMartin>
So you could just do oldstdio = dup(1).
21:37
<@McMartin>
gnolam: Hardware synthesis is, IIRC, actually an NP-Complete problem.
21:37
<@McMartin>
So they use randomized algorithms so that chjips can be built in our lifetimes.
21:38
<@McMartin>
There's no excuse for bad parsers, but quirky synthesizers are a Fact Of The Universe.
21:38
<@AnnoDomini>
gnolam: You're preaching the choir here. I had a project last semester where the simulation was completely wrong - meatspace testing on a real circuit showed that the the circuit I had to design and redesign for two weeks was fine. Just the fucking simulation was wrong.
21:38
<@ToxicFrog>
McMartin: right. Forgot that you get the new fd in the return value of dup().
21:38
<@ToxicFrog>
AnnoDomini: been there waaaay too often.
21:38
<@ToxicFrog>
Along with one memorable occasion where, when simulated, the outputs appeared 20ns before the inputs.
21:39
<@McMartin>
That sounds more like a fault of the sim~
21:39
<@EvilDarkLord>
Or TF invented time travel.
21:39 * gnolam once sat up 'til midnight trying to debug a circuit problem that, in the end, turned out to be caused by the Xilinx synthesizer "optimizing" away major portions of the code.
21:39
<@ToxicFrog>
No, the simulator sucked massively.
21:39
<@ToxicFrog>
Aah, Xilinx.
21:39
<@McMartin>
I'd say "quantum wormhole circuits!" but those actually exist.
21:39
<@ToxicFrog>
How I hate it.
21:40
<@McMartin>
(tunnel diodes)
21:40
<@gnolam>
Note that this wasn't "sat up 'til midnight in front of my computer" but "sat up 'til midnight locked up in the goddamned lab".
21:41
<@McMartin>
Oh, hey, http://freshmeat.net/projects/ophis/ went through
21:41
<@McMartin>
gnolam: I don't have fond memories of my digital design class either.
21:41
<@McMartin>
This is one reason I only took one
21:41
<@McMartin>
On the other hand, the guys before me had to do all that with ICs and enormous breadboards, so I was contractually forbidden from complaining.
21:44
<@gnolam>
I have very fond memories of mine. Just not very fond memories of VHDL.
21:44
<@ToxicFrog>
Likewise.
21:45
<@ToxicFrog>
I greatly enjoyed digital design, but given that we had to do it in VHDL, using motherfucking Xilinx, on the incredibly unstable windows machines in the engineering labs, it was like trying to build an airplane by relaying instructions through a blind, def, epileptic five-year-old.
21:45
<@ToxicFrog>
Deaf, even.
21:47
<@AnnoDomini>
We're doing DigiTech in Max+plus II - which is a pretty nice environment. One semester before, we did it in Electronics Workshop - which is also nice, but was kinda meant for Windows 3.x.
21:47
<@AnnoDomini>
The laboratory boxes have yet to crash on me.
21:49 GeekSoldier|bed [~Rob@Nightstar-4629.pools.arcor-ip.net] has quit [Ping Timeout]
21:52
<@AnnoDomini>
However, we've been given a link to a tutorial meant for a different environment than we're using, no instruction in VHDL, a week of time, and a pretty complex piece of homework for complete beginners.
21:53
<@AnnoDomini>
Half of us doesn't yet understand how to build structures out of a given variety of gates - those I pity. They're gonna have heaps of problems.
21:54
<@gnolam>
... wait, this is your /first/ DigiTech course?
21:54
<@AnnoDomini>
Nono. We've done two semesters.
21:55
<@AnnoDomini>
This is, however, the first one in which we're supposed to use VHDL.
21:55
<@AnnoDomini>
And like I said, we've received nil instruction.
21:56
<@AnnoDomini>
((Actually, this course is called Reprogrammable Digital Systems, not Digital Technology, but they're the same thing, essentially.))
21:56 GeekSoldier|bed [~Rob@Nightstar-4629.pools.arcor-ip.net] has joined #code
21:59 GeekSoldier|bed [~Rob@Nightstar-4629.pools.arcor-ip.net] has quit [Ping Timeout]
22:06
<@Doctor_Nick>
so
22:06
<@Doctor_Nick>
rm * is
22:15 GeekSoldier|bed [~Rob@Nightstar-4629.pools.arcor-ip.net] has joined #code
22:21 GeekSoldier|bed [~Rob@Nightstar-4629.pools.arcor-ip.net] has quit [Ping Timeout]
22:25 AnnoDomini [AnnoDomini@Nightstar-28915.neoplus.adsl.tpnet.pl] has quit [Quit: His gods were simple and understandable; Crom was their chief, and he lived on a great mountain, whence he sent forth dooms and death. It was useless to call on Crom, because he was a gloomy, savage god, and he hated weaklings. But he gave a man courage at birth, and the will and might to kill his enemies, which, in the Cimmerian's mind, was all any god should be expected to do.]
22:33 FBI_web0094 [FBI_pl0094@Nightstar-10997.vl-kot-as1.avtlg.ru] has joined #Code
22:34 FBI_web0094 [FBI_pl0094@Nightstar-10997.vl-kot-as1.avtlg.ru] has quit [Quit: ]
22:34
<@McMartin>
...
22:35 * McMartin finds a copy of vi for the C64
22:35
<@TheWatcher[afk]>
...
22:35
<@McMartin>
http://www.floodgap.com/retrotech/cbm/svicc/
22:36
< Zemyla>
....]
22:46
<@Doctor_Nick>
horray
22:50
<@Doctor_Nick>
how do you switch processes in linux?
22:51
<@McMartin>
That's an OS-level activity.
22:51
<@McMartin>
If you want to give up your timeslice if necessary, sleep(0);.
22:51 AnnoDomini [AnnoDomini@Nightstar-28915.neoplus.adsl.tpnet.pl] has joined #Code
22:51 mode/#code [+o AnnoDomini] by ChanServ
22:52
<@Doctor_Nick>
so, if you start a process running in the background, like "nano &", you can't bring it back to the foreground?
22:52 * AnnoDomini froths at the mouth at this insurmountable problem.
22:52
<@Doctor_Nick>
=(
22:52
< Zemyla>
fg nano
22:53
<@Doctor_Nick>
?
22:53
<@Doctor_Nick>
oh
22:54
<@McMartin>
I thought you meant "I'm a program; I want to hand control to another process"
22:54
<@McMartin>
Not "I'm the user"
22:54
<@Doctor_Nick>
naw
22:59
<@Doctor_Nick>
I'm trying to figure out how to start processes in the background
23:00
<@McMartin>
I think, by definition, everything is in background.
23:00
<@McMartin>
being "in foreground" just means the shell is blocking.
23:00
<@Doctor_Nick>
normally, after the fork, the child process will call execv() and run its stuff, while the parent process just waits for the child to finish executing
23:00
<@McMartin>
popen, on the other hand, does not do this, right?
23:01
<@McMartin>
Not sure if that's quite what you need, though
23:01
<@Doctor_Nick>
popen?
23:01
<@McMartin>
popen(3) - starts a child process and ties its stdin/out to FILE pointers.
23:01
<@Doctor_Nick>
oh, i think that's verboten
23:02
<@McMartin>
OK
23:02
<@McMartin>
Besides, it alone isn't strong enough.
23:03 * McMartin has an unholy love of Python's popen3 and popen4, especially since they actually work on Windows without Cygwin.
23:03
<@Doctor_Nick>
i tried just making the parent not wait, but that would result in some strange behavior and possible lockups
23:03
<@Doctor_Nick>
like, "nano &" would bring up the nano display but then it would lock up
23:03
<@McMartin>
Have you checked what say, bash does?
23:03
<@McMartin>
Hmm.
23:04
<@Doctor_Nick>
look at the code?
23:04
<@McMartin>
Yes.
23:04
<@McMartin>
I note that nano forces itself to stop if it doesn't have full terminal access.
23:24 Zemyla [~nsJChat@168.53.174.ns-23174] has quit [Quit: Nightstar's Java Chat http://www.nightstar.net]
--- Log closed Sun Oct 14 00:00:45 2007
code logs -> 2007 -> Sat, 13 Oct 2007< code.20071012.log - code.20071014.log >