New notices during bootstrap

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

New notices during bootstrap

Rik-4
jwe,

I upgraded to Kubuntu 18.04 so I am suddenly using much more modern build
tools.  I'm getting a few new notices from the bootstrap procedure that I
thought deserve a look.

Notice from module strftime:
  This module is obsolete. Use module 'nstrftime' instead.

The fix for this is to use 'nstrftime' in the top-level file
bootstrap.conf.  But I don't know if this would have negative consequences
for someone with old hardware/software where gnulib has not yet defined the
module nstrftime.

Second, notice is this one

Notice from module localcharset:
  If your package's tests make use of the locale_charset() function directly or
  indirectly, you may need to define the CHARSETALIASDIR environment variable,
  so that "make check" works before "make install". In Makefile.am syntax:
  TESTS_ENVIRONMENT += @LOCALCHARSET_TESTS_ENVIRONMENT@

Octave does use the wrapped locale_charset() function directly in 4 places:

libinterp/corefcn/strfns.cc:760:    = (tmp.empty () ?
octave_locale_charset_wrapper () : tmp.c_str ());
libinterp/corefcn/strfns.cc:812:    = (tmp.empty () ?
octave_locale_charset_wrapper () : tmp.c_str ());
libinterp/corefcn/input.cc:539:              ?
octave_locale_charset_wrapper () : m_mfile_encoding;
libinterp/corefcn/input.cc:1121:         ? octave_locale_charset_wrapper ()
: mfile_encoding);

I don't whether this is a problem or not.

Third thing,

Don't forget to
  - mention "-I m4" in ACLOCAL_AMFLAGS in Makefile.am,

I don't see that we are adding '-I m4' anywhere.  On the other hand, it
seems to be getting included anyways.

running: AUTOPOINT=true LIBTOOLIZE=true autoreconf --verbose --install
--force -I m4  --no-recursive

Do you have an opinion on any of these recommendations?

--Rik


Reply | Threaded
Open this post in threaded view
|

Re: New notices during bootstrap

Mike Miller-4
On Thu, Oct 18, 2018 at 08:50:40 -0700, Rik wrote:
> Third thing,
>
> Don't forget to
>   - mention "-I m4" in ACLOCAL_AMFLAGS in Makefile.am,
>
> I don't see that we are adding '-I m4' anywhere.  On the other hand, it
> seems to be getting included anyways.

That advice is actually out of date, but probably still relevant for
gnulib users with older versions of Automake. We can safely ignore it
since we require Automake 1.14 or later.

From https://www.gnu.org/software/automake/manual/html_node/Local-Macros.html

| The second possibility, which we do recommend, is to write each macro in
| its own file and gather all these files in a directory. This directory
| is usually called m4/. Then it’s enough to update configure.ac by adding
| a proper call to AC_CONFIG_MACRO_DIRS:
|
| AC_CONFIG_MACRO_DIRS([m4])
|
| aclocal will then take care of automatically adding m4/ to its search
| path for m4 files.

So adding '-I m4' is redundant, and I think if you add it back in,
either Automake or another tool will warn about it being legacy or
unnecessary.

--
mike

signature.asc (849 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: New notices during bootstrap

John W. Eaton
Administrator
In reply to this post by Rik-4
On 10/18/2018 11:50 AM, Rik wrote:

> jwe,
>
> I upgraded to Kubuntu 18.04 so I am suddenly using much more modern build
> tools.  I'm getting a few new notices from the bootstrap procedure that I
> thought deserve a look.
>
> Notice from module strftime:
>    This module is obsolete. Use module 'nstrftime' instead.
>
> The fix for this is to use 'nstrftime' in the top-level file
> bootstrap.conf.

I'll look at making this change.

> But I don't know if this would have negative consequences
> for someone with old hardware/software where gnulib has not yet defined the
> module nstrftime.

Unless you are doing something special to get gnulib from some source
other than Octave's subrepo, then it should not be a problem because we
control the gnulib version.

> Second, notice is this one
>
> Notice from module localcharset:
>    If your package's tests make use of the locale_charset() function directly or
>    indirectly, you may need to define the CHARSETALIASDIR environment variable,
>    so that "make check" works before "make install". In Makefile.am syntax:
>    TESTS_ENVIRONMENT += @LOCALCHARSET_TESTS_ENVIRONMENT@
>
> Octave does use the wrapped locale_charset() function directly in 4 places:
>
> libinterp/corefcn/strfns.cc:760:    = (tmp.empty () ?
> octave_locale_charset_wrapper () : tmp.c_str ());
> libinterp/corefcn/strfns.cc:812:    = (tmp.empty () ?
> octave_locale_charset_wrapper () : tmp.c_str ());
> libinterp/corefcn/input.cc:539:              ?
> octave_locale_charset_wrapper () : m_mfile_encoding;
> libinterp/corefcn/input.cc:1121:         ? octave_locale_charset_wrapper ()
> : mfile_encoding);
>
> I don't whether this is a problem or not.

I don't know either.  I'll have to check what TESTS_ENVIRONMENT does and
how it is used.

> Third thing,
>
> Don't forget to
>    - mention "-I m4" in ACLOCAL_AMFLAGS in Makefile.am,
>
> I don't see that we are adding '-I m4' anywhere.  On the other hand, it
> seems to be getting included anyways.

I think this works because we have

   AC_CONFIG_MACRO_DIR([m4])

in configure.ac.  But I don't mind adding ACLOCAL_AMFLAGS in Makefile.am
to silence the warning.  I can do that.

jwe

Reply | Threaded
Open this post in threaded view
|

Re: New notices during bootstrap

John W. Eaton
Administrator
In reply to this post by Mike Miller-4
On 10/18/2018 12:47 PM, Mike Miller wrote:

> On Thu, Oct 18, 2018 at 08:50:40 -0700, Rik wrote:
>> Third thing,
>>
>> Don't forget to
>>    - mention "-I m4" in ACLOCAL_AMFLAGS in Makefile.am,
>>
>> I don't see that we are adding '-I m4' anywhere.  On the other hand, it
>> seems to be getting included anyways.
>
> That advice is actually out of date, but probably still relevant for
> gnulib users with older versions of Automake. We can safely ignore it
> since we require Automake 1.14 or later.
>
>  From https://www.gnu.org/software/automake/manual/html_node/Local-Macros.html
>
> | The second possibility, which we do recommend, is to write each macro in
> | its own file and gather all these files in a directory. This directory
> | is usually called m4/. Then it’s enough to update configure.ac by adding
> | a proper call to AC_CONFIG_MACRO_DIRS:
> |
> | AC_CONFIG_MACRO_DIRS([m4])
> |
> | aclocal will then take care of automatically adding m4/ to its search
> | path for m4 files.
>
> So adding '-I m4' is redundant, and I think if you add it back in,
> either Automake or another tool will warn about it being legacy or
> unnecessary.

OK, then let's ignore the warning here.

I'll make the nstrftime module change.

jwe



Reply | Threaded
Open this post in threaded view
|

Re: New notices during bootstrap

John W. Eaton
Administrator
In reply to this post by Rik-4
On 10/18/2018 11:50 AM, Rik wrote:

> Second, notice is this one
>
> Notice from module localcharset:
>    If your package's tests make use of the locale_charset() function directly or
>    indirectly, you may need to define the CHARSETALIASDIR environment variable,
>    so that "make check" works before "make install". In Makefile.am syntax:
>    TESTS_ENVIRONMENT += @LOCALCHARSET_TESTS_ENVIRONMENT@
>
> Octave does use the wrapped locale_charset() function directly in 4 places:
>
> libinterp/corefcn/strfns.cc:760:    = (tmp.empty () ?
> octave_locale_charset_wrapper () : tmp.c_str ());
> libinterp/corefcn/strfns.cc:812:    = (tmp.empty () ?
> octave_locale_charset_wrapper () : tmp.c_str ());
> libinterp/corefcn/input.cc:539:              ?
> octave_locale_charset_wrapper () : m_mfile_encoding;
> libinterp/corefcn/input.cc:1121:         ? octave_locale_charset_wrapper ()
> : mfile_encoding);
>
> I don't whether this is a problem or not.

I don't see anywhere in the Octave sources (from hg or generated by the
build) that TESTS_ENVIRONMENT or LOCALCHARSET_TESTS_ENVIRONMENT is used.
  So I think we can ignore this one.

jwe