Commit Graph

3483 Commits

Author SHA1 Message Date
Stefan Rueger
a6b5acecf6 Merge pull request #1699 from stefanrueger/remove-port-array
Change port array in PROGRAMMER to be const char *
2024-02-25 13:52:26 +13:00
stefanrueger
8552760727 Add comment re use of libavrdude 2024-02-24 12:41:51 +13:00
stefanrueger
5c61b9e770 Update NEWS 2024-02-24 00:49:12 +13:00
Stefan Rueger
08d14154b7 Merge branch 'main' into remove-port-array 2024-02-24 00:28:30 +13:00
Stefan Rueger
2425ee98a6 Merge pull request #1689 from dbuchwald/serialupdi_doc_update
Updated section about NVM models support
2024-02-24 00:26:24 +13:00
Stefan Rueger
4b7da29cbe Merge pull request #1688 from ndim/libavrdude.h
libavrdude.h fixes and installation of libavrdude-avrintel.h
2024-02-24 00:26:08 +13:00
Stefan Rueger
27fe913c29 Merge pull request #1681 from ndim/improve-autotool-build
Improve autotool build (part 1/n)
2024-02-24 00:25:32 +13:00
stefanrueger
a83f3cf087 Update libavrdude major version 2024-02-23 13:36:27 +13:00
stefanrueger
a24e6eb74b Update libavrdude version 2024-02-22 21:13:14 +13:00
stefanrueger
75eccf7d8e Change port array in PROGRAMMER to be const char * 2024-02-22 15:33:49 +13:00
stefanrueger
5277e384af Harden against port string being NULL 2024-02-22 15:29:22 +13:00
Hans Ulrich Niedermann
8553d37c37 Move auto-added m4 files to auto-m4/ subdir
Have the autotools place their m4 files into the auto-m4/
subdir to separate them from our own m4 files.

Not using AC_CONFIG_MACRO_DIRS for backwards compatibility.
2024-02-21 09:33:50 +01:00
Hans Ulrich Niedermann
a690c40e5b Add GIT_COMMIT_HASH to autotools AVRDUDE_FULL_VERSION
Add the GIT_COMMIT_HASH to the version message printed by
"avrdude -?" and in the avrdude.conf avrdude_conf_version line.

So the autotools buildsystem now produces the identical
version message as the cmake buildsystem does.
2024-02-20 06:20:47 +01:00
Hans Ulrich Niedermann
dd9e4d2cf2 m4 quote macro args and set variable defaults
This m4 quotes many more macro arguments and deals with the
setting of variables.

  * Set variable default values to avoid accidental use of
    env var values from the caller of the configure script
  * rewrap some longer lines
  * Remove AC_SUBST([FOO], [$FOO]) type no-ops. AC_SUBST([FOO])
    does the same.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
cc94578803 Call it AVRDUDE_FULL_VERSION everywhere
Calling AVRDUDE_FULL_VERSION just VERSION in parts of the build
process, and AVRDUDE_FULL_VERSION in others, is unnecessarily confusing.

So call it AVRDUDE_FULL_VERSION everywhere.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
29695afebb gitignore: dist tarballs and distdir/ itself 2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
dc88ff42ad Add AM_PROG_AR before LT_INIT, removing AC_PROG_AR etc
Use AM_PROG_AR before LT_INIT to prevent occasional warnings.

AM_PROG_AR was introduced in the 1.11 to 1.12 timeframe,
and we require at least Automake 1.14.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
3ef9f7194a Move AM_SILENT_RULES directly after AM_INIT_AUTOMAKE 2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
6f11b88bcd Stop checking for AM_SILENT_RULES macro
There is no need to check for AM_SILENT_RULES.

AM_SILENT_RULES was introduced in automake 1.11, and we
require at least automake-1.14 now.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
8d73b0521d Remove unused TIME_WITH_SYS_TIME macro definition
The TIME_WITH_SYS_TIME C preprocessor macro is not found
anywhere in the source tree, so we do not need to define
it after all and can get rid of the obsoletion warning.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
f8bb5619b8 Use committer date for commit date and year
Quoting CMakeLists.txt: "[...] of latest commit"

"Latest commit" is better served by using the committer date %cd
instead of the author date %ad: The author date could be some time
last year with committer date being today.

Note this affects both autotools and cmake buildsystems to keep
the generated version message dates and year in sync.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
bccad9dfe6 Fix libreadline summary output
AC_CHECK_LIB([readline], [readline]) without an ACTION-IF-FOUND
results in the definition of the HAVE_LIBREADLINE C preprocessor
macro and the addition of -lreadline to LIBS, not a configure
script environment variable have_readline.

So this repeats what the default ACTION-IF-FOUND does (add
-lreadline to LIBS, AC_DEFINE the HAVE_LIBREADLINE macro),
and in addition defines the have_libreadline variable as
yes for later use inside configure.ac.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
d0a36e03b7 Fix accidentally inconsequential typo in variable name 2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
c076aa7f3b Consistently use x and quotes in test(1) calls 2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
5cbbf31852 Expand AC_PROG_AWK because we are using $(AWK) 2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
9b4a667fc2 Use newer AC_PROG_LEX invocation
As our src/config.c defines a "yywrap" function, there
is no need for AC_PROG_LEX to look for for a "yywrap"
function in LEXLIBS.

Therefore we add the "noyywrap" option to follow the more
modern AC_PROG_LEX invocation.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
84b649849c Require a certain baseline of tool versions
Require a certain baseline of tool versions, in this case
from around 2013 (autoconf 2.69 and automake 1.14).

This is a significant advancement over the old requirement
of autoconf 2.60 (from 2006) and no requirement on automake
which gives us features without needing a very recent system.

The exact versions to require might be up to debate.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
b6a47dddec Line wraps to improve human readability
Wrap some lines in src/configure.ac to improve readability.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
9b576c4c01 Raw result of running "autoupdate"
This is just the raw result of running "autoupdate" to update
the src/configure.ac file to a more recent standard.

Manual fixes to the autoupdate output will happen over the next
few commits.

This fixes some of the autoreconf time warnings, e.g. about AC_TRY_*
being used instead of AC_*_IFELSE.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
ed2bb82652 Pass bootstrap CLI arguments to autoreconf
For my convenience, pass all bootstrap CLI arguments on to autoreconf.

This is useful when testing with e.g. -Wall and -Werror arguments.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
b4402bd334 Have bootstrap script work only in its own directory
When called from a working directory different from the directory
where the bootstrap script is located, make the bootstrap script
only work on its own directory and not whatever the current working
directory just happens to be.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
2a6f415166 Have autoreconf deal with initializing GNU build system
Let the autoreconf tool handle the sequencing of tool calls.

The autoreconf tool has been dealing with calling tools like
aclocal, libtoolize, etc. quite well for about the last 20 years.

This keeps the "bootstrap" script around to keep the old way
of calling bootstrap working, i.e. maintain compatibility with the
existing workflows.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
c96032a57b Move all autotools helper scripts to auto-aux/
Move all autotools helper scripts and auxiliary files installed
automatically by the autotools to auto-aux/ (e.g. config.guess,
depcomp, install-sh, texinfo.tex, etc.).

Moving AC_CANONICAL_TARGET after AC_CONFIG_AUX_DIR works
around a silent bug in Autoconf 2.69 where the generated
configure script would not find the install-sh file which
has been placed in that given aux directory.

Moved AM_INIT_AUTOMAKE which must also happen after
AC_CONFIG_AUX_DIR.
2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
1b5f3935b6 Add example build script for autotools build tests 2024-02-19 06:10:33 +01:00
Hans Ulrich Niedermann
610330f0d9 Remove unused unnecessary commented build code
Remove unused unnecessary commented out build code from
"src/configure.ac".

I accidentally left those comments in commit d15c561a.
2024-02-18 16:21:25 +01:00
Hans Ulrich Niedermann
8fb73a1458 Add basic CI checks using the autotools build
This add some basic CI checks which exercise the autotools build:

  * make targets "all" "install" testing compilation and installation
  * run the same dry-run test-avrdude check as the cmake builds
  * make target "distcheck" testing that dist tarball contains all
    the necessary files
2024-02-18 16:21:19 +01:00
Dawid Buchwald
565a7238f4 Updated section about NVM models support 2024-02-16 09:38:52 +01:00
Hans Ulrich Niedermann
ec698b4e1a Include headers defining the used types
As libavrdude-avrintel.h uses not only uint32_t and related
types from stdint.h, but also size_t from stddef.h, we also
need to #include the latter into libavrdude.h before
libavrdude.h includes libavrdude-avrintel.h
2024-02-15 00:51:05 +01:00
Hans Ulrich Niedermann
df7c495fb7 Use proper C99 parameterless function declaration 2024-02-15 00:42:52 +01:00
Hans Ulrich Niedermann
efafa0ced0 Install libavrdude internal header libavrdude-avrintel.h 2024-02-15 00:42:52 +01:00
Hans Ulrich Niedermann
bfd9606d23 More stringent #include API checks 2024-02-15 00:42:47 +01:00
stefanrueger
5c1649dcee Update NEWS 2024-02-15 11:41:52 +13:00
Stefan Rueger
14d1560e52 Merge pull request #1680 from ndim/fix-Wcalloc-transposed-args
Fix -Wcalloc-transposed-args warning
2024-02-15 11:40:20 +13:00
Stefan Rueger
64f2a3ed22 Merge pull request #1686 from stefanrueger/avrintel.h
Make avrintel.h an internal header file for libavrdude
2024-02-15 11:39:27 +13:00
stefanrueger
a82679229a Update NEWS 2024-02-14 21:54:30 +13:00
Stefan Rueger
cdfc88dfc4 Merge pull request #1687 from mcuee/remove_msys2_32bit_build
Remove 32bit MSYS2 mingw32 and clang32 build
2024-02-14 21:53:28 +13:00
mcuee
2357f833e1 Remove 32bit MSYS2 mingw32 and clang32 build
MSYS2 has dropped 32bit binary packages for libusb, libusb-compat-git and libftdi.
2024-02-14 13:36:21 +08:00
stefanrueger
e2a10db193 Make avrintel.h an internal header file for libavrdude 2024-02-14 17:15:21 +13:00
Hans Ulrich Niedermann
e0188195a3 Fix -Wcalloc-transposed-args warning
The calloc(3) function has two arguments: the number of members,
and the size of one member.

sizeof(...) makes more sense as member size, and 1 as number
of members. At least that is what the gcc warning wants.

This was the only compiler warning I could get on my Fedora 40
test build (gcc 14) with CFLAGS="-Wall -Wextra -Werror".
2024-02-07 15:26:18 +01:00
stefanrueger
0179026e09 Add NEWS template for next version 2024-02-08 00:19:33 +13:00