[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Helper program best-practice

From: Bent Bisballe Nyeng
Subject: Helper program best-practice
Date: Sat, 25 Jul 2020 20:21:31 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0

I have a local noinst binary which is used before compilation to
generate some c code.

I have so far just created the binary target as noinst_PROGRAMS and then
depends on it in the target for creating the source file - something like:

noinst_PROGRAMS = myprog myhelper

myhelper_SOURCES =

myprog_SOURCES = $(top_builddir)/

$(top_builddir)/ myhelper$(EXEEXT)
        ./myhelper$(EXEEXT) > $@

I am now trying to make the program compile on windows using msys2 and
have noticed that the helper is created inside the .libs folder along
with a wrapper script.
A binary is also stored in the top_builddir but this has a different
size than the one in .libs and doesn't appear to do anything when
executed (the one in .libs works).
On linux/bsd the utility is simply generated directly in the
top_builddir and works.

Note: In order to have the helper compile at all on windows I had to add
the $(EXEEXT).

So what is best practice when working with such a helper/utility?

Kind regards
Bent Bisballe Nyeng

reply via email to

[Prev in Thread] Current Thread [Next in Thread]