drip doesn't exit when run under make...
jszakmeister opened this issue · comments
I haven't located the source of this problem (and have run out of time to try and track it down), but I do have a simple reproduction recipe.
Here's my Makefile
:
helloworld.jar: *.java
javac -cp . $^
jar cf $@ $(addsuffix .class,$(basename $^))
helloworld: helloworld.jar
drip -cp $< HelloWorld
all: helloworld.jar
.PHONY: helloworld
Here's HelloWorld.java
:
public class HelloWorld {
public static void main(String[] args) {
System.out.println("Hello World!");
}
}
When running make helloworld
with this setup, "Hello World!"
will get printed, but the process doesn't exit until I hit ctrl-c. I'm running under Mac OS X (Snow Leopard) with this version of java:
:: java -version
java version "1.6.0_51"
Java(TM) SE Runtime Environment (build 1.6.0_51-b11-457-10M4509)
Java HotSpot(TM) 64-Bit Server VM (build 20.51-b01-457, mixed mode)
The issue here might be that the spawned VMs are retaining a handle to make's stdout, stdin, and stderr. I recall running into a similar situation elsewhere (not with drip) where the parent process would fail to exit until the children gave up the handles.