Closed Bug 427092 Opened 16 years ago Closed 16 years ago

Dehydra/Treehydra: remove Dehydra->Treehydra dep in Require

Categories

(Developer Infrastructure :: Source Code Analysis, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: dmandelin, Assigned: dmandelin)

References

Details

Attachments

(1 file)

My implementation of the pass option for the require builtin introduced a dependence of Dehydra on Treehydra. I thought it was just a bit ugly, but it causes real problems for the Mac port, because they don't have Treehydra at all yet.

I plan to fix the problem by making require table-driven, so that each tool can install its own function pointers into the table. The goal is to have direct dependences only of Treehydra on Dehydra.
Blocks: 423898
Attached patch Fix, so to speakSplinter Review
Well, this fix isn't entirely nondisgusting, but I think it will work. A definitive fix awaits the multiplexing system. 

I included the work of bug 426893 inside this patch because it's needed to test this functionality (and, more to the point, because I was unaware that 426893 had been filed). Let me know if you want it split out, but I don't think it's a big deal.
Comment on attachment 313700 [details] [diff] [review]
Fix, so to speak

>diff -r 591ce7705222 test/Makefile
>--- a/test/Makefile	Fri Apr 04 12:49:27 2008 -0700
>+++ b/test/Makefile	Fri Apr 04 14:47:57 2008 -0700
>@@ -8,9 +8,12 @@ CXXFLAGS = $(PLUGINARG) -fplugin-arg=$(S
> 
> all: test.o assign.o typedef.o operator_new.o destr_order.o init.o virtual.o constructor.o types.o templ-spec.o constructor.o stack_fieldOf.o templ-simple.o longevity.o finalizers.o unit_tests
> 
>-# Treehydra unit tests
>+# Unit tests
> unit_tests:
>-	python unit_test_harness.py "$(CC1PLUS) -fplugin=../gcc_%s.so -o /dev/null -fplugin-arg=%s %s"
>+	python unit_test_harness.py both "$(CC1PLUS) -fplugin=../gcc_%s.so -o /dev/null -fplugin-arg=%s %s"
>+
>+dehydra_unit_tests:
>+	python unit_test_harness.py dehydra "$(CC1PLUS) -fplugin=../gcc_%s.so -o /dev/null -fplugin-arg=%s %s"
> 
> %.o: %.cc $(PLUGIN)
> 	$(CC1PLUS) $(CXXFLAGS) $< -o /dev/null

Careful here. Can't make both the default since treehydra isn't built by default. 
My recent commit added unit_tests to all: so this is bad.
(In reply to comment #2)
> Careful here. Can't make both the default since treehydra isn't built by
> default. 
> My recent commit added unit_tests to all: so this is bad.
 
OK, I changed the 'all' line to run dehydra_unit_tests instead. Is that OK? 

I'd like to get this pushed because it changes the unit test harness design, making it bitrot every time the unit test harness script changes.
Don't worry for my permission on pushing test stuff. Go ahead. Can always fix tests later.
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Product: Core → Firefox Build System
Product: Firefox Build System → Developer Infrastructure
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: