Changes since 4.66:
- Fixed the stack overflow in Perl in long variable assignment lines.
- Improved the SUBST check.
- For all files in bin/ and sbin/, pkglint now complains if the package
does not have a manual page, too. (Only with -Wextra)
- Lists of pathnames may be used in .for loops, since they are _assumed_
to not contain any additional white-space.
- Some more small improvements.
filenames and pathnames may appear in .for loops. (Of course, this only
works for "nice" filenames, but the amount of false positive warnings would
just be too high.)
Added another warning for dependency patterns like 2.3*, which are
likely to be wrong: They match 2.3, 2.3nb4 and 2.30, but not 2.20, which
lies in between them.
- Shell commands in Makefiles may have leading white-space before the
[@-]*.
- Replaced the obsolete MASTER_SITES_SUBDIR with DIST_SUBDIR in the
variable order check. The variables aren't the same, but the position
is fine.
handled automatically by pkgsrc.
- Rewrote the PLIST parser a little bit, which revealed that PLIST
directives like @dirrm may be prefixed with ${FOR_...} or
${NOTFOR_...}.
- Added the -Cglobal option for inter-package checks (disabled by
default) that may consume a lot of memory.
- Adjusted pkglint to another change in the TOOLS framework which had
not been detected automatically.
- MD5 checksums are no longer deprecated, they are now obsolete.
This change includes all the things I thought of during the freeze of
2006Q2.
Some variables have disappeared from pkgsrc without notice. Marked them
deprecated to help the package authors at least a bit.
Renamed some ACL abbreviations in makevars.map and adjusted the variable
definitions.
Added the command line options -Dtrace, -Dunchecked and -Dunused.
Some variables may contain unexpected white-space and therefore should
not be used in .for loops.
The -Dmisc option replaces the --verbose option (and the log_info
subroutine), which does not exist any longer. This eliminates all
instances of "OK:" from the output, which I didn't like from the
beginning. The -Dmisc option also takes over many warnings that have
been issued by --debug before.
Improved the check for absolute pathnames. Especially, everything that
follows ${DESTDIR} or $(DESTDIR) in a Makefile is considered an absolute
pathname. This reveals many wrong uses of DESTDIR (as defined by the GNU
coding standards), for example $(DESTDIR)/$(prefix), which should be
$(DESTDIR)$(prefix) instead.
Almost every use of a make(1) variable is checked for spelling mistakes.
Before, only the definitions of variables have been checked.
Restricted the use of variables to specific files, which are defined in
makevars.map. This catches especially buildlink3.mk files with
unexpected side effects.
In shell commands, neither "echo" nor "echo -n" or "${ECHO} -n" should
be used. Since the INSTALL_*_DIR commands can only handle one directory
at a time, suggest to use INSTALLATION_DIRS instead.
Greatly improved the checks for dependency specifications, especially to
find foo-*, which should rather be foo-[0-9]*.
Fixed the incorrect handling of LICENSE_FILE (now using $line->text
instead of $line).
Improved the wording of the "plural names" warnings, so that for known
variables it is "The += operator should only be used with lists." now.
In buildlink3.mk files the uppercase and lowercase names of the package
should correspond with the package name. This catches many
copy-and-paste mistakes. Fixed many null pointer exceptions as well. In
addition, every buildlink3.mk file needs a definition of
BUILDLINK_API_DEPENDS.
In patch files, absolute pathnames and unportable macro names are
checked not only in added lines, but also in the context lines.
In the pkgsrc root directory and the category directories, the Makefiles
are checked like every other Makefile, too.
Fixed the place where the global variables for the package context are
defined and later undefined.
Variables that are mentioned in EVAL_PREFIX may be used in the current
file and are not flagged as "used but not defined".
When parsing shell words in Makefiles, recognize $<, $@, $^ and $/.
(The latter is used extensively by openoffice to represent a directory
separator.)
Fixed some minor bugs:
* $makevar had been defined unintentionally by using the -> operator.
Changes since 4.64:
- Many refinements of quoting checks and variable type definitions.
- Improved the wording of diagnostics and added some explanations.
- Adjusted pkglint to the many recent changes in the infrastructure part.
- Improved detection of absolute pathnames.
Updated during the freeze because the version number has not changed for
two weeks, but many features were added. Therefore the old version
number was not reliable for determining the real functionality of
pkglint exactly.
this one is defined in PkgLint::SubstContext instead of the main
package. Time will show whether this was a good decision. Since the
checking subroutines heavily modify the fields of the SubstContext, it
seems to be Done Right.
- The macro __sparc_v9__ is neither defined by gcc nor by SunPro. But
__sparcv9 is.
- Added some more commands that may be hidden using the "@" character.
- Don't let pkglint get confused by additional magic in the use of
MASTER_SITES. For example, devel/nspr uses ${MASTER_SITE:S/../../:=foo/}.
- Added an explanation for the ${WRKSRC}/.. warning, since it is not
documented anywhere else.
- Improved two diagnostics for buildlink3.mk files.
- Added a check to discover package name mismatches in
BUILDLINK_{ABI,API}_DEPENDS, as well as the version numbers.
list of shell words, or sometimes as a single shell word. Compare: ${LD}
${LDFLAGS} and ./configure -libs ${LDFLAGS:Q}. So in this case, the :Q
operator cannot be checked reliably.
unchecked before (mainly because of limitations in earlier pkglint
versions). Added ACL constants for user-defined, system-defined and
command-line variables.
Changes since 4.63:
- Many diagnostics for the :Q operator have been wrong. They are currently
left out, but will be re-added later. In the mean time, no diagnostics
are better than wrong ones.
- Made defining the permissions for variables easier by providing a way to
define "permission constants".
appear in an assignment of its own", since it had been misunderstood at
least once. Also, since the explanation is usually several lines long,
it does not hurt to add two extra empty lines to separate the
explanation from the actual warning.
Changes since 4.62:
- Improved checking of variable permissions.
- Improved detection of unused variables, for spell checking.
- Added warnings for variables that are used at load time but should not.
- Much code cleanup.
for lists of something, this can lead to unexpected behavior. Currently,
only the variables BUILDLINK_DEPENDS, BUILDLINK_PACKAGES and PKG_OPTIONS
may be looked at during load time.
This warning reveals the bad practice to "patch" CONFIGURE_ARGS at load
time, for example:
> CONFIGURE_ARGS:= ${CONFIGURE_ARGS:S/--disable-esd/--enable-esd/}
WARN: audio/bmp-esound/Makefile:14: CONFIGURE_ARGS should not be
evaluated at load time.
into a single subroutine, checkline_mk_varuse, which replaces the
various ad-hoc checks. Added the class PkgLint::VarUseContext that tries
to model the context in which a make(1) variable can appear. The checks
are much better now than before, but there's still work to do. Added a
new type FileMode for file permissions.
Currently no warnings are printed for untyped variables (that is,
user-defined and not following the common naming schemes). This includes
the iteration variables of .for loops. Since many of the warnings have
been overly strict, this is not a big loss.
deprecated.
- CONFLICT is just a spelling mistake and therefore should not appear
in the list of deprecated variables.
- Made handling of parameterized variables more uniform.
data types and permissions.
- Changed the way that permissions are determined a bit, so that
unspecified permissions can be detected.
- Renamed -Wacl to -Wperm.
- When no applicable permissions are found, "?" is returned.
- When checking for unused variables, parameterized variables don't have to
be matched exactly but only by basename.
- Added an explanation for the permissions warning.
- Renamed explain() to explain_warning() and added explain_info().
- Added some code to distinguish FOO from FOO.* in the makevars.map file.
- Allow an alternative form of checking the inclusion depth in
buildlink3.mk files.
- Added checks for deprecated and nonexistent licenses. (suggested by gdt)
- Added detection for /foo/s/bar/baz/ sed command that appears without a
leading "-e" in a SedCommands variable. (suggested by wiz)
- Aligned the ACL permission letters with the documentation. The old "c"
letter has been removed because from the definition's point of view,
there is no difference between the "=" and the ":=" operator. All the
differences lie on the right hand side, which will be covered later.
- Updated the variables in makevars.map with mk/defaults/mk.conf, 1.118.
- Added the -Wacl command line option, which is disabled by default.
- Extended the type definitions in makevars.map by ACLs, which specify
in which files the variables may be defined.
- Trailing white-space in DESCR files can be fixed automatically.
- Use of the $$ shell variable is not flagged as "strange" anymore.
- Added ACL-based checks for variable definitions.
- PKGREVISION should not be set to 0.
- Improved the diagnostics text for RESTRICTED.
- Added the types Unchecked and Version.
- Dashes are allowed in library names in wrapper reordering commands.
- More than one DISTFILES definition is allowed in the variable ordering
check.
Changes since 4.59:
- For many variables the :Q operator is not needed (by definition), for
example some pathnames, user names, group names.
- Improved the diagnostics for planned package updates.
- Various catch-ups to recent changes in the infrastructure, among them
BUILDLINK_ABI_DEPENDS and gettext.mk.
- When the PLIST contains a libtool archive, the *.a and *.so files don't
have to be mentioned explicitly.