Bug#718892: thansk for arduino-mk NMU

Bas Wijnen shevek at fmf.nl
Tue Aug 13 19:22:32 UTC 2013


Control: found -1 0.12.0-1
Control: tags -1 + patch

On Thu, Aug 08, 2013 at 10:13:21AM -0400, Scott Howard wrote:
> Upstream was in the middle of a transition between lead developers and
> there has been significant changes to the code base.

Yes, I knew that was coming up, but since the package didn't work at
all, I figured it'd be good to have that fixed anyway.

> I'm going to upload a new version that will include some of your
> changes.
> 
> Some, however, have been dropped (e.g., line_count.patch) since
> upstream now uses a different implementation entirely.

Yes, I heard that it wouldn't be needed anymore.  However, the library
dependency bug is still half-present: it doesn't crash on it anymore,
but it doesn't track .cc, .hh and .hpp files for libraries.

The problem is in this part:
$(LIB_DEP_FILE): $(OBJDIR) $(LOCAL_INO_SRCS) $(LOCAL_CPP_SRCS) $(LOCAL_C_SRCS) $(LOCAL_HEADERS) $(LOCAL_PDE_SRCS)
	grep -h '^[     ]*#[    ]*include[      ]*<' -- *.ino *.cpp *.c *.h *.pde|sed 's!^.*<\(.*\)\.h>.*!\1!'|sort -u|xargs -d '\n' echo 'ARDUINO_LIBS =' > $(LIB_DEP_FILE)
	echo >> $(LIB_DEP_FILE)

The first line of that should also include $(LOCAL_CC_SRCS).  It might
be best to just define $(LOCAL_SRCS) at the start which combines all of
them.

The second line (the grep command) should use the same variables as the
dependency list instead of *.ino etc; when any of the file types in the
list is not present (and *.ino and *.pde can never both be present), you
get a warning about it, which is not nice.  If the same list of
$(LOCAL_*_SRCS) as above is used (including $(LOCAL_CC_SRCS), of
course), that warning is gone and the new file types are used (*.hh and
*.hpp are already included in $(LOCAL_HEADERS)).

So for your convenience, here are those lines again, but now the way
they should be:
$(LIB_DEP_FILE): $(OBJDIR) $(LOCAL_INO_SRCS) $(LOCAL_CPP_SRCS) $(LOCAL_CC_SRCS) $(LOCAL_C_SRCS) $(LOCAL_HEADERS) $(LOCAL_PDE_SRCS)
	grep -h '^[     ]*#[    ]*include[      ]*<' -- $(LOCAL_INO_SRCS) $(LOCAL_CPP_SRCS) $(LOCAL_CC_SRCS) $(LOCAL_C_SRCS) $(LOCAL_HEADERS) $(LOCAL_PDE_SRCS)|sed 's!^.*<\(.*\)\.h>.*!\1!'|sort -u|xargs -d '\n' echo 'ARDUINO_LIBS =' > $(LIB_DEP_FILE)
	echo >> $(LIB_DEP_FILE)

Or perhaps better:
$(LIB_DEP_FILE): $(OBJDIR) $(LOCAL_SRCS) $(LOCAL_HEADERS)
	grep -h '^[     ]*#[    ]*include[      ]*<' -- $(LOCAL_SRCS) $(LOCAL_HEADERS)|sed 's!^.*<\(.*\)\.h>.*!\1!'|sort -u|xargs -d '\n' echo 'ARDUINO_LIBS =' > $(LIB_DEP_FILE)
	echo >> $(LIB_DEP_FILE)

With a definition of $(LOCAL_SRCS) at the top of the file, just after
the definitions of $(LOCAL_*_SRCS).

Thanks,
Bas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/debian-science-maintainers/attachments/20130813/ebb00226/attachment.sig>


More information about the debian-science-maintainers mailing list