missing .depend files after make clean ?

1,022 views
Skip to first unread message

=JeffH

unread,
Jan 9, 2013, 3:22:10 PM1/9/13
to certificate-...@googlegroups.com
I've been trying to compile the CT code I've pulled from
<https://code.google.com/p/certificate-transparency/>

I did a "make clean" (in attempting to work around a different problem I
describe in a separate message), and now when I try to compile I get...

google/certificate-transparency/src[43]> make
Makefile:66: proto/.depend: No such file or directory
Makefile:67: merkletree/.depend: No such file or directory
Makefile:68: log/.depend: No such file or directory
Makefile:69: util/.depend: No such file or directory
g++ -I. -I /usr/local/include -Wall -Werror -g -O3 -MM -MG util/*.cc > util/.depend1
util/testing.cc:3:25: error: gtest/gtest.h: No such file or directory
make: *** [util/.depend] Error 1


The Makefile does indeed remove .depend files --- should it have a provision to
re-create them as-necessary ? Or is there some command I can use to do so ?

In nosing around I found the below stuff here (down near end)
<http://stackoverflow.com/questions/2481269/how-to-make-simple-c-makefile>:

###
CC=gcc
CXX=g++
RM=rm -f
CPPFLAGS=-g $(shell root-config --cflags)
LDFLAGS=-g $(shell root-config --ldflags)
LDLIBS=$(shell root-config --libs)

SRCS=tool.cc support.cc
OBJS=$(subst .cc,.o,$(SRCS))

all: tool

tool: $(OBJS)
g++ $(LDFLAGS) -o tool $(OBJS) $(LDLIBS)

depend: .depend

.depend: $(SRCS)
rm -f ./.depend
$(CXX) $(CPPFLAGS) -MM $^>>./.depend;

clean:
$(RM) $(OBJS)

dist-clean: clean
$(RM) *~ .dependtool

include .depend

Notice that

There are no longer any dependency lines for the source files!?!
There is some strange magic related to .depend and depend
If you do make then ls -A you see a file named .depend which contains
things that look like make dependency lines
###

Should some aspects of the above be included in
.../certificate-transparency/src/Makefile ?


thx

=JeffH

Emilia Kasper

unread,
Jan 10, 2013, 5:58:10 AM1/10/13
to certificate-...@googlegroups.com
The .depend files do automatically get recreated, as you can see from the output - your problem here appears to be a missing googletest (gtest) library.

Cheers,
Emilia





=JeffH

--



=JeffH

unread,
Jan 10, 2013, 2:07:46 PM1/10/13
to certificate-...@googlegroups.com
> your problem here appears to be a missing googletest (gtest)
> library.

doh

yeah, this worked (at least for fixing the .depend thing)..

> make GTESTDIR=/usr/local/src/google/gtest-1.6.0


thx

=JeffH


Reply all
Reply to author
Forward
0 new messages