Re: [hackers] [farbfeld] Overhaul Build-system || Laslo Hunhold

From: Laslo Hunhold <dev_AT_frign.de>
Date: Thu, 30 Mar 2017 00:08:12 +0200

On Wed, 29 Mar 2017 23:24:33 +0200
Hiltjo Posthuma <hiltjo_AT_codemadness.org> wrote:

Hey Hiltjo,

> > -PNGLIB = /usr/local/lib
> > -PNGINC = /usr/local/include
> > -
> > -JPGLIB = /usr/local/lib
> > -JPGINC = /usr/local/include
>
> Personally I think it's useful to have these separated. It is also
> useful to specify PNGINC, JPGINC etc separately for building in
> different environments.

what moved me to put it all into one parameter was the thought that
even if the png and jpg library are in different places (same with the
includes) you can easily add two or more include/library search paths to
the compiler with the I- and L-flags. In this sense, it was logical to
me that having separate variables was overkill. Please tell me if I'm
missing something.

> > +png2ff ff2png: LDFLAGS += -lpng
> > +jpg2ff ff2jpg: LDFLAGS += -ljpeg
>
> This is invalid and breaks on OpenBSD (and other non-GNU make
> probably).

What a shame I hit this mine. It's even easier to hit GNUisms in make
than bashisms in Bash, and I really didn't give it enough thought and
just used target-specific variables. I'll do some further testing with
pmake (that's how the BSD-make is called on Gentoo) and fix my makefiles
to be portable.
Thanks for pointing out the issue and taking your time to write this
E-mail.

> I didn't see an issue with the previous Makefile and don't share the
> criticism. Just my 0.69 cents.

The old Makefile was okay, but it made it a bit hard to work with
requisites, which I plan on doing here. I really respect your opinion on
this matter. It was also admittedly a personal interest to write
something from scratch and just explore things a little. Seems like my
exploration continues; I learnt a lot today. :)

With best regards

Laslo

-- 
Laslo Hunhold <dev_AT_frign.de>
Received on Thu Mar 30 2017 - 00:08:12 CEST

This archive was generated by hypermail 2.3.0 : Thu Mar 30 2017 - 00:12:54 CEST