unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Danny Milosavljevic <dannym@scratchpost.org>
To: Ricardo Wurmus <rekado@elephly.net>
Cc: guix-devel@gnu.org
Subject: Re: [PATCH v6 2/2] gnu: Add arduino-makefile.
Date: Wed, 31 Aug 2016 22:34:57 +0200	[thread overview]
Message-ID: <20160831223457.236a77d9@scratchpost.org> (raw)
In-Reply-To: <8737lkbtao.fsf@elephly.net>

Hi Ricardo,

On Wed, 31 Aug 2016 22:02:55 +0200
Ricardo Wurmus <rekado@elephly.net> wrote:
> > +             (let ((avr-gcc (assoc-ref inputs "avr-gcc-5"))
> > +                   (avr-binutils (assoc-ref inputs "avr-binutils")))
> > +              (substitute* "bin/ard-reset-arduino"
> > +                (("#!/usr/bin/env python") "#!/usr/bin/python3"))  
> 
> This looks unnecessary.  When “python-wrapper” is among the inputs the
> shebang would be replaced automatically.

It's impossible for anyone to reliably detect the major Python version that
the script expects.

Therefore, this clarifies that we need Python3 for it.
The shebang will then be automatically updated correctly.

> > +              (substitute* "Arduino.mk"
> > +                (("#    => ARDUINO_DIR.*")
> > +                   (string-append "ARDUINO_DIR = "
> > +                                  (assoc-ref %build-inputs "arduino-libraries")  
> 
> Could you use “inputs” instead of “%build-inputs” here?

Yes. What's the difference?

> > +                ; What about ld ?  
> 
> What about it?  :)

I don't know. Seems to work without it but it just irks me.
There's no variable for ld's name in the makefile.

> I’m a little confused about this.  Why is avrdude among the inputs?  Why
> python-pyserial?  Nothing is built here.  You just copy the files.

It's supposed to be something like an arduino-toolchain. You just install it
and it will pull the compiler, flasher etc and use it for your projects
automagically as long as they "include Arduino.mk".

> If “bin/ard-reset-arduino” or any other script uses pyserial you will
> probably have to wrap the executables such that they set the PYTHONPATH
> to include the output of python-pyserial.  Otherwise they won’t be able
> to find anything.

Probably.

> Please break this line.  Is this really just a Makefile?  What else is
> there?

Yeah, huge makefile. Allows you to build and flash the stuff.

> > +    ;(supported-systems '("avr"))  
> 
> This should be removed.

As I said I'm not a fan of obfuscating what system this is for.
It is *good* for maintenance to have little hints of what to expect.

If it worked usefully, I'd even make the (supported-system '("avr")) active!

> > +    (license license:lgpl2.1)))  
> 
> Only version 2.1, or does it have the “or later” clause?

lgpl2.1+

Thanks,
    Danny

  reply	other threads:[~2016-08-31 20:35 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-30 19:01 [PATCH v6 0/2] gnu: Add Arduino tools Danny Milosavljevic
2016-08-30 19:01 ` [PATCH v6 1/2] gnu: Add arduino-libraries Danny Milosavljevic
2016-08-31 20:08   ` Ricardo Wurmus
2016-08-31 20:40     ` Danny Milosavljevic
2016-08-30 19:01 ` [PATCH v6 2/2] gnu: Add arduino-makefile Danny Milosavljevic
2016-08-31 20:02   ` Ricardo Wurmus
2016-08-31 20:34     ` Danny Milosavljevic [this message]
2016-09-01 14:57       ` Ricardo Wurmus
2016-09-01 18:44         ` Danny Milosavljevic
2016-09-01 18:52           ` Danny Milosavljevic

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160831223457.236a77d9@scratchpost.org \
    --to=dannym@scratchpost.org \
    --cc=guix-devel@gnu.org \
    --cc=rekado@elephly.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).