Re: Remove dhclient(8) from base

2018-06-21 Thread Martin Husemann
On Thu, Jun 21, 2018 at 05:19:32PM +0200, Julian Coleman wrote: > Hi, > > > The release of NetBSD-8 is probably imminent, now is probably the best time > > to do this. > > Will it suprise people that dhclient has gone from base? Maybe deprecate it > in the 8.0 release notes and remove it from cu

Re: "%m" formatting code and "syslog like"

2018-08-31 Thread Martin Husemann
On Fri, Aug 31, 2018 at 01:23:51PM +0100, Roy Marples wrote: > This allows dhcpcd to be compiled with full warnings, but I've disabled the > check for specific functions. This is actually self defeating as it's just > the kind of function the warnings are for, but as best I can tell it's > impossib

Re: "%m" formatting code and "syslog like"

2018-08-31 Thread Martin Husemann
On Fri, Aug 31, 2018 at 02:10:12PM +0100, Roy Marples wrote: > The function is currently marked as __printflike. > If I re-enable the warning gcc warns me that it should be marked as > __sysloglike because it calls syslog. If I change it to __sysloglike > then it warns me that it should be __p

Re: Providing access to USB devices

2018-09-20 Thread Martin Husemann
On Thu, Sep 20, 2018 at 10:41:01AM +0200, Pierre Pronchery wrote: > Would it make sense to create a _usb group, and setting the permissions > of /dev/ugen* and maybe also /dev/usb* to mode 0660 root:_usb? > > With this we should also be able to run services like pcscd (from > pkgsrc) without requi

OpenSSL vs. getauxval()

2018-09-29 Thread Martin Husemann
Hey folks, openssl on arm uses a weak symbol reference to "getauxval", and if the symbol is available, calls it to get hardware information about the current cpu. We never make this kind of hardware information availble via flags in the exec auxval vector, but use sysctl instead. We also do not p

Re: ld.elf_so compatibility for ancient ELF binaries (pre-2.0)

2018-10-04 Thread Martin Husemann
On Wed, Oct 03, 2018 at 10:40:32PM +0200, Joerg Sonnenberger wrote: > The list of platforms where ELF was enabled by default can be found in > https://anonhg.netbsd.org/src/file/897109941a9a/share/mk/bsd.own.mk#l96 > Note that this also includes sparc64. This makes no sense as the dynamic > linker

Re: Moving telnet/telnetd from base to pkgsrc

2018-12-15 Thread Martin Husemann
On Sat, Dec 15, 2018 at 09:49:06AM +0100, Micha? Górny wrote: > To be honest, I don't think you can pull this. Not because telnet is > necessary but because Windows-origin users are used to think of telnet > as netcat, and rarely realizing all the dragons hidden there. Changing > your habits is h

Re: Moving telnet/telnetd from base to pkgsrc

2018-12-16 Thread Martin Husemann
On Sat, Dec 15, 2018 at 10:43:14PM +0100, Marc Balmer wrote: > To me it looks like one or two people don't like telnet and have become > very vocal and loud about removing it and did not invest a lot of thought > in to the cause. Yes, I call them *** Name calling and other personal insul

Re: Pressure sensors

2019-01-02 Thread Martin Husemann
On Wed, Jan 02, 2019 at 06:38:21PM +, David Holland wrote: > Most of the world uses millibars and occasionally labels them hPa. > Since judging by the patch the framework isn't up to handling both, > the best course is probably to use and label as millibars and just > duck the occasional brickb

Re: Is safe to memset to zero a structure with doubles?

2019-01-14 Thread Martin Husemann
On Mon, Jan 14, 2019 at 10:42:22PM +0100, Jose Luis Rodriguez Garcia wrote: > Is safe to memset to zero a structure with double types in the archs > supported by NetBSD? Yes, that works for all our supported architectures. Martin

Re: Lua shared object asymmetry loading Xlib.

2019-01-20 Thread Martin Husemann
On Sun, Jan 20, 2019 at 10:06:33AM +0100, Marc Balmer wrote: > Why are atexit handlers run after dlclosing loaded libraries? That sounds > wrong to me, but is there a reason? They are run at exit(1) time, the application (or in this case library) is responsible of removing them if it dlclose()s

Re: Lua shared object asymmetry loading Xlib.

2019-01-20 Thread Martin Husemann
On Sun, Jan 20, 2019 at 10:32:43AM +0100, Kamil Rytarowski wrote: > I find it as workaround of our libc behavior. I disagree, there is no clean way to implement the call-on-dlclose semantics (i.e. it needs disgusting ld.elf_so hacks and layer violations). But maybe we should document the __cxa_at

Re: Lua shared object asymmetry loading Xlib.

2019-02-03 Thread Martin Husemann
On Sun, Feb 03, 2019 at 05:58:02PM -0900, Phil Rulon wrote: > In order to make it work right the loader will have to keep track of each > heap address in the DSO and determine if it is also referenced elsewhere. > The only other option is to maintain separate heaps for each DSO and a > global heap

Re: Possible slight speedup to non-interactive /bin/sh startup

2019-02-11 Thread Martin Husemann
On Mon, Feb 11, 2019 at 09:36:57AM +0700, Robert Elz wrote: > 1. it needs a way to find out what the correct name for the libedit > shared library to use is, from the build system, other Makefiles, > or something (it currently just has "libedit.so.3" embedded in it, > with no path, and simply knowi

Re: colorls in base

2019-02-17 Thread Martin Husemann
On Sun, Feb 17, 2019 at 09:56:56PM +, Alexander Nasonov wrote: > New features should start from the installer ;-) > > IMO, the installer should offer two choices of colour and > the selected choice should become a default for other tools. I strongly object to adding non-essenital choices to t

Re: namespace pollution by curses

2019-03-08 Thread Martin Husemann
On Fri, Mar 08, 2019 at 10:41:51PM +0900, Rin Okuyama wrote: > I've found that this is because curses uses a global variable "state": > https://nxr.netbsd.org/xref/src/lib/libcurses/getch.c#50 > https://nxr.netbsd.org/xref/src/lib/libcurses/get_wch.c#52 Can both variants of inkey() co-exist? I wo

Re: namespace pollution by curses

2019-03-10 Thread Martin Husemann
On Mon, Mar 11, 2019 at 02:01:44PM +0900, Rin Okuyama wrote: > (3) Put "state" struct __window (suggested by uwe) I prefer this one too. Martin

Re: find and limits

2019-04-04 Thread Martin Husemann
On Thu, Apr 04, 2019 at 10:12:35AM +, co...@sdf.org wrote: > wanting to write a portable version, I have to limit myself to what > POSIX find and POSIX xargs support, which isn't much :-/ > I got this in the end: > > ${FIND} ${WRKSRC} -iname '*.ttf' -print | \ > ${XARGS} -I

Re: dynamic symbol resolving preference (was: SHA384_Update symbol clash with libgs)

2019-04-06 Thread Martin Husemann
On Sat, Apr 06, 2019 at 09:49:22AM +0200, Edgar Fuß wrote: > 1. The dynamic linker should be able to notice that two libraries are > pulled in which export conflicting symbols and warn about it, no? > That would have saved me three working days. No, this is how ELF works - one library can overri

Re: /etc/rc.d/local starts not last

2019-04-13 Thread Martin Husemann
On Sat, Apr 13, 2019 at 11:15:49AM +0200, tlaro...@polynum.com wrote: > So my guess is that Vnc reinject keyboard and mouse events and so need > wsmoused to run (and it is after). rc.local is not run last, see rc(8): rc.local is a command script to which local boot-time actions can be a

Re: Having to define _STANDALONE to get standard

2019-04-18 Thread Martin Husemann
On Wed, Apr 17, 2019 at 08:27:02PM +0200, tlaro...@polynum.com wrote: > In order to have only standard definitions in , I have to > define not standard macro _STANDALONE due to inclusion of > (that does not only contain declarations but definitions of functions? > In a header?). It only includes

Re: Patch to make reentrant by default

2019-04-27 Thread Martin Husemann
On Fri, Apr 26, 2019 at 11:36:00PM +0200, Kamil Rytarowski wrote: > We keep detecting that more software is happy to just pick -lpthread > (like LLVM OpenMP) and prebuilt software works by an accident. That would be easily catchable in pkgsrc wrappers (i.e. remove all "-lpthread" or similar args i

libm symbol addition (Was: CVS commit: src)

2019-05-01 Thread Martin Husemann
I have two questions for the change below: > Module Name: src > Committed By: kamil > Date: Sat Apr 27 23:04:32 UTC 2019 > > Modified Files: > src/distrib/sets/lists/comp: mi > src/lib/libm: Makefile > src/lib/libm/man: nextafter.3 > src/lib/libm/src: s_nextafterl

Re: NetBSD truss(1), coredumper(1) and performance bottlenecks

2019-05-24 Thread Martin Husemann
On Fri, May 24, 2019 at 10:02:56PM +0700, Robert Elz wrote: > I wonder what this is doing... The variable is documented: "make" variables Several variables control the behavior of NetBSD builds. Unless otherwise specified, these variables may be set in either the process environ

Re: malloc() exceeds RLIMIT_DATA

2019-07-08 Thread Martin Husemann
On Mon, Jul 08, 2019 at 06:06:34PM -0700, Graham Percival wrote: > Thomas Klausner (wiz@) suggested that I write to this list. It appears that > NetBSD's malloc() will allocate more than RLIMIT_DATA's rlim_max. The classical "data segment" (limited by RLIMIT_DATA) is not used much nowadays in Net

Re: pthread_setname_np API is bad

2019-08-09 Thread Martin Husemann
On Fri, Aug 09, 2019 at 04:00:02PM +0200, Kamil Rytarowski wrote: > On 09.08.2019 15:32, Christos Zoulas wrote: > > My worry is that someone will call pthread_setname_np() with a > >  "%thread%s" name argument and get a core dump on a NetBSD system since > > the string will be interpreted as a form

Re: pthread_setname_np API is bad

2019-08-09 Thread Martin Husemann
On Fri, Aug 09, 2019 at 07:09:01PM +0200, Kamil Rytarowski wrote: > Delayed adoption of a standardized version of pthread_setname() > pthread_getname() will result in no API & ABI breakage with any existing > code as we will keep our own _np() invention, at least until we will > bump major number f

Re: stdio.h's P_tmpdir definition - make it /tmp?

2019-08-30 Thread Martin Husemann
On Fri, Aug 30, 2019 at 08:13:37AM -0400, Thor Lancelot Simon wrote: > > most of the toolchain consumers that create temp files don't > > use $TMPDIR from the env but use stdio.h's P_tmpdir defintion This is a bug (and differs from gcc documentation). We should analyze and fix that bug first (and

Re: stdio.h's P_tmpdir definition - make it /tmp?

2019-08-30 Thread Martin Husemann
On Fri, Aug 30, 2019 at 01:38:02PM -, Valery Ushakov wrote: > Greg Troxel wrote: > > > It seems that long long ago, /tmp was small and on /, and /var was often > > bigger, and people used /var/tmp for larger stuff. Also I remember a > > notion of clearing /tmp on boot and not clearing /var/

Re: Leak Sanitizer - how to suppress leaks

2019-09-13 Thread Martin Husemann
On Fri, Sep 13, 2019 at 08:33:31AM +0200, Thomas Klausner wrote: > I'm sorry, I totally do not get it the problem with -- in general -- > writing the code in such a way that it properly frees any allocations > it made. > > I suspect there will be corner cases where it will be really hard, and > we

Re: Solving the syslogd problem

2020-01-29 Thread Martin Husemann
On Wed, Jan 29, 2020 at 11:33:22AM +0100, Joerg Sonnenberger wrote: > On Tue, Jan 28, 2020 at 09:21:23PM +, Roy Marples wrote: > > To fix this, I suggest that we split syslogd into syslogd and > > syslogd-network. > > We could also do a much simpler and more radical decision and stop > splitt

Re: pam_krb5.c - -Werror=format-overflow

2020-02-06 Thread Martin Husemann
On Thu, Feb 06, 2020 at 05:01:55AM -0500, Santhosh Raju wrote: > --- dependall-pam_krb5 --- > /home/fox/projects/netbsd/obj-wip/destdir.amd64/usr/include/security/pam_modules.h: > In function 'pam_sm_setcred': > /home/fox/projects/netbsd/src-wip/lib/libpam/modules/pam_krb5/pam_krb5.c:489:6: > error

Re: pam_krb5.c - -Werror=format-overflow

2020-02-06 Thread Martin Husemann
On Thu, Feb 06, 2020 at 05:16:05AM -0500, Santhosh Raju wrote: > I am guessing the build cluster does not run with MKLIBCSANITIZER=yes > in the build.sh? No, but why would that make a difference here? If it does, it sounds like a gcc bug. Martin

Re: pam_krb5.c - -Werror=format-overflow

2020-02-06 Thread Martin Husemann
On Thu, Feb 06, 2020 at 05:39:53AM -0500, Santhosh Raju wrote: > Alright the solution would be to 'fix gcc' I suppose? :P It might be a makefile bug passing different options to this build step (unintendely). > Will wait for other opinions (to see if there are any). If not will > add the flag to

Re: Expose max_align_t unconditionally

2020-03-09 Thread Martin Husemann
Stupid question: if that libc+++ is only designed to be C++11 and newer, in what real world scenarios does it require exposing max_align_t? For sure you can easily compile the libc++.so* itself with proper standard flags passed to the compiler, so it must be something else - or I'm missing somethi

Re: Expose max_align_t unconditionally

2020-03-09 Thread Martin Husemann
On Mon, Mar 09, 2020 at 02:49:23PM -0400, Greg Troxel wrote: > I am not really following the issue, but I don't understand why what the > default C++ sublanguage is matters. It would seem that behavior should > be correct for any --std passed to compilers, per that sublanguages's > specification,

Re: Expose max_align_t unconditionally

2020-03-09 Thread Martin Husemann
On Mon, Mar 09, 2020 at 08:28:58PM +0100, Micha? Górny wrote: > ATF-C++ forces -std=gnu++98. We could remove that but then we fail > on deprecated auto_ptr use. We should fix that, independently of the issue at hand. Martin

Re: package build failures on netbsd-8 using nbtar, pax, bsdtar

2020-03-09 Thread Martin Husemann
On Mon, Mar 09, 2020 at 08:10:04PM -0400, Greg Troxel wrote: > The package is /usr/pkgsrc/textproc/py-sphinxcontrib-serializinghtml > which was recently updated to 1.1.4. The 1.1.3 tarball looks fine with > NetBSD's /bin/tar but the 1.1.4 throws lots of: I think this pkg needs: EXTRACT_USING=bsd

Re: getrandom and getentropy

2020-05-02 Thread Martin Husemann
On Sat, May 02, 2020 at 12:22:20PM +, m...@netbsd.org wrote: > Having compat shims in libc is as good as having compat shims in syscall > because it isn't possible to share raw syscall code between NetBSD and > other operating systems -- our calling convention is different. I can't parse that

Re: posix_spawnp() and PATH - change code or manual ?

2020-05-06 Thread Martin Husemann
On Wed, May 06, 2020 at 02:33:41PM +0700, Robert Elz wrote: > Either of those is fine with POSIX - but we should really have one consistent > policy. Changing either the manual or the code to match the other is also > easy. What is not so easy is to decide which of the two (or perhaps > somethi

Re: posix_spawnp() and PATH - change code or manual ?

2020-05-06 Thread Martin Husemann
On Wed, May 06, 2020 at 02:29:07PM +0200, Joerg Sonnenberger wrote: > I'm not sure. There is normally no way to force an empty environment > variable, so if you want to not use PATH, the behavior of the current > code is more useful. But you can then just use posix_spawn() instead. Martin

Re: posix_spawnp() and PATH - change code or manual ?

2020-05-06 Thread Martin Husemann
On Wed, May 06, 2020 at 02:51:28PM +0200, Joerg Sonnenberger wrote: > The environment is under the control of the user, the code isn't. Ok, but you can set PATH to : or something. Martin

Re: PATCH libatomic

2020-05-06 Thread Martin Husemann
On Thu, May 07, 2020 at 05:43:02AM +0200, Kamil Rytarowski wrote: > I propose the following patch: > > http://netbsd.org/~kamil/patch-00250-libatomic.txt +__inline static int +__futex(volatile uint32_t *uaddr, int op, int val, const struct timespec *timeout, +volatile uint32_t *uaddr2, i

Re: PATCH libatomic

2020-05-08 Thread Martin Husemann
On Fri, May 08, 2020 at 02:26:45PM +0200, Kamil Rytarowski wrote: > With _Atomic() we can mark any arbitrary struct to have serialized > accesses. As I said, with your attitude we shall remove FPU support (and > softfloat) as they are not async safe, not safe in virtualization for > MMU accesses an

Re: PATCH libatomic

2020-05-08 Thread Martin Husemann
On Fri, May 08, 2020 at 10:24:43PM +, m...@netbsd.org wrote: > The indirection only applies to the first call. The magic is within > rtld. You are comparing PLT calls with ifunc (where even normal PLT calls have initial resolution overhead, but very tiny - while ifuncs may have arbitrary first

Re: getrandom and getentropy

2020-05-12 Thread Martin Husemann
On Tue, May 12, 2020 at 10:00:20AM +0300, Andreas Gustafsson wrote: > we have entropy when we don't. Adding more sources could mean > reintroducing some timing based sources after careful analysis, but > also things like having the installer install an initial random seed > on the target machine (

Re: getrandom and getentropy

2020-05-14 Thread Martin Husemann
On Thu, May 14, 2020 at 03:12:13PM +0200, Joerg Sonnenberger wrote: > I'd strongly argue that the only category where it really matters > potentially are long term key generators. I would at the same time > consider creating the ssh host keys as part of sysinst, but that's > already setting up the

Re: Addition of ppoll(2), a wrapper around pollts(2)

2020-05-24 Thread Martin Husemann
On Mon, May 25, 2020 at 04:32:14AM +0530, Apurva Nandan wrote: > Hi all, > I have added ppoll(2) implementation to libc/sys, which is a wrapper around > pollts(2) function (basically, pollts(2) and ppoll(2) are aliases, and > NetBSD has pollts(2)). Why not just add a weak alias for the function? I

Re: Addition of ppoll(2), a wrapper around pollts(2)

2020-05-25 Thread Martin Husemann
On Mon, May 25, 2020 at 12:20:53PM +0530, Apurva Nandan wrote: > The problem with __weak_alias is that they only work inside the same C file > where the original symbol is defined, and don't work outside that file for > that symbol. That is not true. > I have created _ppoll internal function in l

Re: Addition of ppoll(2), a wrapper around pollts(2)

2020-05-25 Thread Martin Husemann
On Mon, May 25, 2020 at 10:22:12AM +0200, Kamil Rytarowski wrote: > This is a non-standard extension, but everybody mainstream (except > macosx that lacks it?) settled on the name ppoll. ... which is probably the worst name anyone could come up with. Can you explain what alias issues you have? Th

Re: Addition of ppoll(2), a wrapper around pollts(2)

2020-05-25 Thread Martin Husemann
On Mon, May 25, 2020 at 11:24:14AM +0200, Joerg Sonnenberger wrote: > On Mon, May 25, 2020 at 10:06:22AM +0200, Martin Husemann wrote: > > On Mon, May 25, 2020 at 12:20:53PM +0530, Apurva Nandan wrote: > > > The problem with __weak_alias is that they only work inside the

Re: Addition of ppoll(2), a wrapper around pollts(2)

2020-05-25 Thread Martin Husemann
On Mon, May 25, 2020 at 03:09:09PM +0530, Apurva Nandan wrote: > I meant that I can't create a __weak_alias ppoll(2) to pollts(2) in libc as > pollts(2) has its definition in sys/sys. But yes the resulting weak alias > symbol works from everywhere. The syscall stabs are generated code, but we have

Re: Addition of ppoll(2), a wrapper around pollts(2)

2020-05-25 Thread Martin Husemann
On Tue, May 26, 2020 at 01:37:41AM +0200, Kamil Rytarowski wrote: > I agree here with Joerg. > > At this point it's good to just add a wrapper as in the proposed patch. > Once we will bump libc major, we can rename the syscall and remove > pollts references. > > Weak alias would still be nicer, b

Restrict mtree to specific directories

2020-06-02 Thread Martin Husemann
I have a small issue with mtree(8), that I am not quite sure how to fix best. I would like to create directory hierachies from mtree spec files, but restrict this to selected hierachies (where the mtree files contain a bit more). Example: mkdir /tmp/test && cd /tmp/test && mtree -f /etc/

Re: Restrict mtree to specific directories

2020-06-03 Thread Martin Husemann
On Tue, Jun 02, 2020 at 04:14:20PM +0200, Martin Husemann wrote: > So in above example I could create a "onlyfile" containing something like: > > ./var > ./var/* > ./var/*/* > ./var/*/*/* > ./var/*/*/*/* > ./var/*/*/*/*/* >

mountcritlocal rcorder (Was: Restrict mtree to specific directories)

2020-06-03 Thread Martin Husemann
On Thu, Jun 04, 2020 at 05:48:34AM +0700, Robert Elz wrote: > And of course, I should have really read mtree(1) before replying, > so the suggested method would just be > > grep whatever original-spec-file [ | grep otherstuff ] | mtree I ended up not using mtree for this, as it was getting

Re: mountcritlocal rcorder (Was: Restrict mtree to specific directories)

2020-06-07 Thread Martin Husemann
I implemented the split and it works nicely for me. I can now just add things like "populate_var" into rc.d which REQUIRE: mountcritlocal and have BEFORE: MOUNTCRITLOCAL to fill the /var tmpfs that has just been mounted. While there I found that random_seed play special tricks and we might consid

Re: Weekday abbreviations in output of cal(1)

2020-06-30 Thread Martin Husemann
On Tue, Jun 30, 2020 at 10:53:38AM +0200, Michael Siegel wrote: > Also, to the best of my knowledge, parsing the output of cal(1) is about > the only method to get certain calendar information in Unix shell > scripts. Now that makes me curious - can you give an example? I think almost always "dat

Re: Weekday abbreviations in output of cal(1)

2020-06-30 Thread Martin Husemann
On Tue, Jun 30, 2020 at 11:24:51AM +0200, Michael Siegel wrote: > Well, how would you use date(1) to return the number of days in any > given month, for example? Good example, slightly complex but still close to cal|wc ;-) Martin --8<-- #! /bin/sh YEAR=2020 MONTH=6 if [ $MONTH -lt 12 ]; then

Re: recent changes to pthread_fork.c:fork() cause static linking to fail if the app provides its own malloc()

2020-07-13 Thread Martin Husemann
On Tue, Jul 14, 2020 at 02:49:00AM +0200, Joerg Sonnenberger wrote: > Replacing malloc is just as invalid from a strict standard compliance > perspective, so *shrug* Why is that? We have e.g. shells/standalone-tcsh that does it. Is it broken now? Martin

Re: 9.1: nested functions crash

2020-10-23 Thread Martin Husemann
On Fri, Oct 23, 2020 at 10:56:50AM -0400, Mouse wrote: > Presumably this is NetBSD trying to break execute-out-of-the-stack > malware. This is not an unreasonable default, but, for this use case, > it's a crippling misfeature. How do I disable it? sysctl -a output > contains nothing promising (I

Re: Summary of man-page formatting

2020-11-14 Thread Martin Husemann
On Sun, Nov 15, 2020 at 03:10:08AM +0100, Kamil Rytarowski wrote: > 1. NetBSD base ships with two programs that can format manual pages from > base and most 3rd party software: BSD mandoc (newest) and GPLv2 groff > 1.19.2 (old, from 2005). Ignoring pkgsrc and most parts of what you listed in the p

Re: wsmoused broken since 9.1

2020-12-23 Thread Martin Husemann
On Wed, Dec 23, 2020 at 06:56:31AM +, RVP wrote: > /usr/sbin/wsmoused has been non-working since slightly > before 9.1 was released. Specifically, any button click > or release generates: Can you narrow down the pullup that broke it? Is it still broken in -current? I see nothing obvious in CHA

Re: wsmoused broken since 9.1

2020-12-26 Thread Martin Husemann
On Sat, Dec 26, 2020 at 08:50:22AM +, RVP wrote: > I'm surprised that nobody's noticed this breakage since Aug 2007. > Is console + wsmoused so little used? ;) I have to admit I only ever use it to shut up stupid USB mice from reconnecting every minute on setups where I boot with serial consol

Re: wsmoused broken since 9.1

2020-12-26 Thread Martin Husemann
On Sat, Dec 26, 2020 at 08:49:22AM -0500, Mouse wrote: > > I have to admit I only ever use it to shut up stupid USB mice from > > reconnecting every minute on setups where I boot with serial console > > How does it affect that? There's a 9.1 system at work where (certain) > USB mice will randomly

Re: vndconfig vs mount_cd9660

2020-12-28 Thread Martin Husemann
On Mon, Dec 28, 2020 at 10:43:10PM +0100, Thomas Klausner wrote: > I wanted to mount an ISO image (on 9.99.77/amd64), so I did, following the > guide: > > # vnconfig -c vnd0 file.iso > # mount -t cd9660 /dev/vnd0a /mnt > mount_cd9660: /dev/vnd0a on /mnt: Invalid argument May this image contain a

Re: vndconfig vs mount_cd9660

2020-12-29 Thread Martin Husemann
On Tue, Dec 29, 2020 at 11:35:15AM +0100, Thomas Klausner wrote: > That did the trick: > > # vnconfig vnd0 file.iso 2048/1/1/1 > # mount_udf -o ro /dev/vnd0a /mnt > >

Re: Waiting for Randot (or: nia and maya were right and I was wrong)

2021-01-11 Thread Martin Husemann
On Mon, Jan 11, 2021 at 01:25:36AM +, Taylor R Campbell wrote: > We might also do something similar with the motd -- add a single line, > citing entropy(7) for more details, if there's not enough entropy. Please don't - that is one of the least usefull places to put such a note. I still think

Re: Waiting for Randot (or: nia and maya were right and I was wrong)

2021-01-14 Thread Martin Husemann
On Thu, Jan 14, 2021 at 10:15:41AM +, nia wrote: > I don't think more options should be added to the installer (it has > too many things that are confusing to a new user already), This is the thinking that gets us to fully automated no choice tools like the auto resizing usb images that I find

Re: tolower()/islower() and char

2021-01-14 Thread Martin Husemann
On Thu, Jan 14, 2021 at 12:14:28PM +0100, Manuel Bouyer wrote: > Any comment about this ? I'm not familiar with these details ... man ctype and search for CAVEATS Martin

Re: tolower()/islower() and char

2021-01-14 Thread Martin Husemann
On Thu, Jan 14, 2021 at 12:28:57PM +0100, Manuel Bouyer wrote: > Does the standard explicitely state that the value should either be > EOF or >= 0 ? Yes, Section 7.4 paragrah 1 second sentence (ISO C 2018): > In all cases the argument is an int, the value of which shall be > representable as an u

Re: Waiting for Randot (or: nia and maya were right and I was wrong)

2021-01-15 Thread Martin Husemann
On Fri, Jan 15, 2021 at 09:25:41AM +0100, Manuel Bouyer wrote: > > If a machine doesn't have any unpredictable inputs, well, there's no > > magic we can do -- you can copy a seed over from another machine (on a > > Yes. I just want to make sure this will remain an option. > For this to work the ma

Re: Waiting for Randot (or: nia and maya were right and I was wrong)

2021-01-15 Thread Martin Husemann
On Fri, Jan 15, 2021 at 12:12:05AM +, Taylor R Campbell wrote: > > On Mon, Jan 11, 2021 at 01:25:36AM +, Taylor R Campbell wrote: > > > We might also do something similar with the motd -- add a single line, > > > citing entropy(7) for more details, if there's not enough entropy. > > > > Pl

Re: Waiting for Randot (or: nia and maya were right and I was wrong)

2021-01-15 Thread Martin Husemann
On Fri, Jan 15, 2021 at 03:04:21PM +0100, Reinoud Zandijk wrote: > Can we create a random stream for all such situations instead of a file? Say > open a TCP/IP connection to some NetBSD server that spits out a X number of > random bytes by its random generator and then closes the stream? You want

Re: Waiting for Randot (or: nia and maya were right and I was wrong)

2021-01-16 Thread Martin Husemann
On Sat, Jan 16, 2021 at 01:21:21PM +0100, Kamil Rytarowski wrote: > Can we overload the ENOSYS return value and return it for CPUs without > hardware assisted random number generator? You mean: with not enough entropy available? The availablility of a hardware random number generator does not rea

Re: text layout in sysinst

2021-02-06 Thread Martin Husemann
On Fri, Feb 05, 2021 at 09:12:32PM +0100, Roland Illig wrote: > When I start sysinst from an installed system though, the language > selection is skipped completely (which I didn't understand from reading > the code) This means the message catalog files have not been found - I thought I fixed that

Re: Adding ?

2021-05-13 Thread Martin Husemann
On Thu, May 13, 2021 at 12:51:45PM +0200, Jaromír Dole?ek wrote: > On the contrary, Linux explicitely #undefs alloca(), then > #define alloca() as __builtin_alloca(), so it always works, regardless > which -std. But isn't that obviously wrong and our version the correct one? (Well, maybe we shoul

Re: Strange pthread_self() return value

2021-06-11 Thread Martin Husemann
On Fri, Jun 11, 2021 at 04:41:51PM +, nia wrote: > However, this value comes from the return value of pthread_self(): You did not link with -pthread (so you get the libc stub of pthread_self()). Martin

Re: possible opendir bug?

2021-07-10 Thread Martin Husemann
On Sun, Jul 11, 2021 at 12:47:53AM -0400, Mouse wrote: > I'm not sure to what extent use of uninitialized memory is considered a > bug when, as here, the code is correct regardless of what value it > contains. It is a bug (and should be detected in builds with proper -fsanitize= compiler options i

Re: Fwd: Release Maintenance Policy

2021-08-08 Thread Martin Husemann
On Sun, Aug 08, 2021 at 09:16:08AM -0400, matthew sporleder wrote: > FYI we need to pull up a newer version of OpenLDAP More important: we need a new version in HEAD before we branch for netbsd-10 (and it better be 2.6 already). We can not pull up a new release if a major bump of the library is n

Re: [PATCH 1/3] gcc: Add missing parentheses around ternary operator

2021-08-28 Thread Martin Husemann
On Sun, Aug 29, 2021 at 01:42:22PM +1000, Damien Zammit wrote: > --- a/external/gpl3/gcc/dist/libcpp/files.c > +++ b/external/gpl3/gcc/dist/libcpp/files.c > @@ -233,7 +233,7 @@ open_file (_cpp_file *file) > } >else > file->fd = open (file->path, O_RDONLY | O_NOCTTY | O_BINARY > -

Re: openssl 3

2021-09-30 Thread Martin Husemann
On Thu, Sep 30, 2021 at 08:44:22AM -0400, Greg Troxel wrote: > What are people thinking about > > updating openssl to 3.0.0 in current Yes, someone(tm) should do that! Early to catch fallout quickly, but we'd need commitment from the pkgsrc team to make pkgsrc usefull with that. I don't think w

Re: openssl 3

2021-09-30 Thread Martin Husemann
On Thu, Sep 30, 2021 at 09:18:23AM -0400, Greg Troxel wrote: > The real question is what kind of pace of update is best, as maintained > upstreams are going to make releases that work with openssl3, and not > being first makes life easier. > > I suspect in a few weeks we'll have a better idea. I

Re: possible bug in fseek of buffered files shared between processes (example uses stdin)

2021-11-02 Thread Martin Husemann
On Tue, Nov 02, 2021 at 10:53:55AM -0700, Carlo Arenas wrote: > Note that the failure in this case can be "fixed" by instead calling > lseek directly, removing the buffer or skipping this early return in > src/lib/libc/stdio/fseeko.c (lines 210 to 228), and that I am showing > below (might be mangl

Re: stack overflow in getaddrinfo(3) with a small-sized stack in pthreads

2021-12-04 Thread Martin Husemann
On Sat, Dec 04, 2021 at 11:20:26AM +0100, Havard Eidnes wrote: > > Joerg Sonnenberger wrote in > > : > > |On Mon, Nov 29, 2021 at 08:38:35PM +0700, Robert Elz wrote: > > |> DNS queries (via UDP) are limited to max 512, as that is what the > > |> protocol always required, so can be handled by ev

Re: brandelf(1)

2022-01-17 Thread Martin Husemann
On Mon, Jan 17, 2022 at 12:28:51PM +0100, Manuel Bouyer wrote: > Hello, > so, to be able to run linux binaries with don't have the Linux type > in its ELF header, I have ported FreeBSD's brandelf(1): > https://www.unix.com/man-page/freebsd/1/brandelf/ > brandelf -- mark an ELF binary for a spec

Re: installboot: Old BPB too big, use -f (may invalidate filesystem)

2022-02-14 Thread Martin Husemann
On Mon, Feb 14, 2022 at 07:25:37PM +0100, Edgar Fuß wrote: > What does > installboot: Old BPB too big, use -f (may invalidate filesystem) > mean? > > I have a RAIDframe level 1 RAID consisting of /dev/sd0e and /dev/sd1e. > Now, sd0 failed. I replaced the disc, fdisk'ed and disklabel'ed it an

Re: installboot: Old BPB too big, use -f (may invalidate filesystem)

2022-02-14 Thread Martin Husemann
On Mon, Feb 14, 2022 at 09:20:45PM +0100, Edgar Fuß wrote: > > If you are trying to setup the machine for NetBSD only use > It's NetBSD only. > > > - if you are UEFI booting from a FAT partition > No, it's plain old BIOS boot (the server is from 2005). > > > - if you really want ffsv1 boot code

Re: crypt_r()?

2022-02-16 Thread Martin Husemann
On Wed, Feb 16, 2022 at 10:27:08AM -0500, Mouse wrote: > That sounds like a recipe for disaster. It is a complete fail for > heterogenous environments where the same hash needs to be checkable on > widely disparate hardware, where a small machine may not have the > resources to perform the check _

Re: ZFS - mounting filesystems (Was CVS commit: src/etc)

2022-03-15 Thread Martin Husemann
On Tue, Mar 15, 2022 at 08:30:11AM -0400, Greg Troxel wrote: > I still don't understand and object to this "zfs is special" notion. It is special because it just does not use /etc/fstab (usually). I don't like this part either, but we probably don't want to make our ZFS different from others (or f

Re: inetd tests failing

2022-03-15 Thread Martin Husemann
On Wed, Mar 16, 2022 at 07:53:09AM +1030, Brett Lymn wrote: > They wait on stdin, they don't need to signal done. How does inetd replace their stdin once the connection is established? Many deamons will do socket operations (e.g. querying the peer) early on startup - that would fail (or deliver bo

Re: inetd tests failing

2022-03-17 Thread Martin Husemann
On Thu, Mar 17, 2022 at 04:58:56PM +1030, Brett Lymn wrote: > Perhaps a shim program that manages a socket between it and the > underlying daemon - the shim can talk to inetd to coordinate the handoff > of an incoming connection and also being put back onto the idle pool > when the connection close

Re: ZFS - mounting filesystems (Was CVS commit: src/etc)

2022-03-17 Thread Martin Husemann
On Thu, Mar 17, 2022 at 12:52:03PM +, Taylor R Campbell wrote: > Does anyone actually do this -- have local mounts on top of remote > mounts? I do, but all machines affected have / on NFS which makes the setup trivial. Martin

Re: Checking whether an rc.d script was invoked from rc

2022-04-12 Thread Martin Husemann
On Tue, Apr 12, 2022 at 12:09:40PM +0200, Edgar Fuß wrote: > Alternatively, I could copy na6 to /local/bin (or whatever). It only needs > libc, libpcap and libm, which are all in /lib, but ldd say the binary > references /usr/lib. How do I change that? Make the script require CRITLOCALMOUNTED (i

Re: Checking whether an rc.d script was invoked from rc

2022-04-12 Thread Martin Husemann
On Tue, Apr 12, 2022 at 12:53:00PM +0200, Edgar Fuß wrote: > > Make the script require CRITLOCALMOUNTED (in -current, or mountcritlocal > > in older versions)? > I don't get that. That wouldn't mount /usr, no? Duh, right - I have /usr in critical_filesystems_local on all machines where it is a sep

Re: sysupgrade in src?

2022-04-15 Thread Martin Husemann
On Fri, Apr 15, 2022 at 08:21:00AM +, nia wrote: > There's been a few discussions over the years about the need for a > usable-over-ssh binary upgrade tool for NetBSD, but they haven't gone > very far. I don't object to your idea (and I have never used it). My own prefered method requires non

Re: cmake core dumps in -6 emulation

2022-06-30 Thread Martin Husemann
On Thu, Jun 30, 2022 at 07:29:18PM +0200, Edgar Fuß wrote: > #8 0x77a601860ac0 in err () from /usr/lib/libc.so.12 > #9 0x77a60280c47b in pthread__init () from /usr/lib/libpthread.so.1 Ktrace it - there are 3 err() calls in pthread__init(), one after sysctl hw.ncpu failed, one if _lwp_unp

Re: cmake core dumps in -6 emulation

2022-07-01 Thread Martin Husemann
On Fri, Jul 01, 2022 at 02:20:02PM +0200, Edgar Fuß wrote: > > Ktrace it > As mentioned, that doesn't work (well, it works, which is the problem). > > > there are 3 err() calls in pthread__init() > > Starting with > #8 0x71b551460ac0 in err () from /usr/lib/libc.so.12 > #9 0x000

Re: /rescue/tar needing liblzma.so.2

2022-07-04 Thread Martin Husemann
On Mon, Jul 04, 2022 at 07:43:41PM +0200, Edgar Fuß wrote: > So why does something in /rescue need a shared library? It doesn't, but it exec's gzip via $PATH and finds /usr/bin/gzip - and that needs /usr/lib/liblzma.so.2. Try with PATH=/rescue, that should avoid the issue. Martin

Re: /rescue/tar needing liblzma.so.2

2022-07-04 Thread Martin Husemann
On Mon, Jul 04, 2022 at 06:58:39PM +, Emmanuel Dreyfus wrote: > On Mon, Jul 04, 2022 at 08:32:02PM +0200, Martin Husemann wrote: > > Try with PATH=/rescue, that should avoid the issue. > > Shouldn't /rescue binaries have /rescue prepended to their PATH? Tricky - isn&#

  1   2   3   >