Subject: Re: pkg/31489
To: None <pkg-manager@netbsd.org, gnats-admin@netbsd.org,>
From: RUMI Szabolcs <rumi@rtfm.hu>
List: pkgsrc-bugs
Date: 10/06/2005 11:26:02
The following reply was made to PR pkg/31489; it has been noted by GNATS.

From: RUMI Szabolcs <rumi@rtfm.hu>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: pkg/31489
Date: Thu, 6 Oct 2005 13:25:11 +0200

 Next error I ran into:
 
 source='mntent_compat.c++' object='mntent_compat.o' libtool=no \
 depfile='.deps/mntent_compat.Po' tmpdepfile='.deps/mntent_compat.TPo' \
 depmode=tru64 /bin/ksh ../depcomp \
 cxx -DHAVE_CONFIG_H -D_POSIX_PII_SOCKET -D_BSD -I. -I. -I.. -I../include -DFAM_CONF=\"/usr/pkg/etc/fam.conf\"    -O2 -ieee -ieee -c -o mntent_compat.o `test -f 'mntent_compat.c++' || echo './'`mntent_compat.c++
 cxx: Error: mntent_compat.c++, line 100: identifier "MNT_RDONLY" is undefined
         res = catopt(res, (flags & MNT_RDONLY) ? "ro" : "rw");
 -----------------------------------^
 cxx: Error: mntent_compat.c++, line 101: identifier "MNT_SYNCHRONOUS" is
           undefined
         if (flags & MNT_SYNCHRONOUS)    res = catopt(res, "sync");
 --------------------^
 cxx: Error: mntent_compat.c++, line 102: identifier "MNT_NOEXEC" is undefined
         if (flags & MNT_NOEXEC)         res = catopt(res, "noexec");
 --------------------^
 cxx: Error: mntent_compat.c++, line 103: identifier "MNT_NOSUID" is undefined
         if (flags & MNT_NOSUID)         res = catopt(res, "nosuid");
 --------------------^
 cxx: Error: mntent_compat.c++, line 104: identifier "MNT_NODEV" is undefined
         if (flags & MNT_NODEV)          res = catopt(res, "nodev");
 --------------------^
 cxx: Error: mntent_compat.c++, line 105: identifier "MNT_UNION" is undefined
         if (flags & MNT_UNION)          res = catopt(res, "union");
 --------------------^
 cxx: Error: mntent_compat.c++, line 106: identifier "MNT_ASYNC" is undefined
         if (flags & MNT_ASYNC)          res = catopt(res, "async");
 --------------------^
 cxx: Error: mntent_compat.c++, line 150: class "statvfs" has no member
           "f_mntfromname"
         _mntent.mnt_fsname = mntbuf->f_mntfromname;
 -------------------------------------^
 cxx: Error: mntent_compat.c++, line 151: class "statvfs" has no member
           "f_mntonname"
         _mntent.mnt_dir = mntbuf->f_mntonname;
 ----------------------------------^
 cxx: Error: mntent_compat.c++, line 152: class "statvfs" has no member
           "f_fstypename"
         _mntent.mnt_type = mntbuf->f_fstypename;
 -----------------------------------^
 cxx: Error: mntent_compat.c++, line 180: argument of type "statvfs **" is
           incompatible with parameter of type "statfs **"
                 mntsize = getmntinfo (&mntbuf, MNT_NOWAIT);
 --------------------------^
 cxx: Info: 11 errors detected in the compilation of "mntent_compat.c++".
 gmake[2]: *** [mntent_compat.o] Error 1
 gmake[2]: Leaving directory `/home/admin/pkgsrc/work/sysutils/fam/work/fam-2.7.0/src'
 gmake[1]: *** [all-recursive] Error 1
 gmake[1]: Leaving directory `/home/admin/pkgsrc/work/sysutils/fam/work/fam-2.7.0'
 gmake: *** [all] Error 2
 *** Error code 2
 
 Stop.
 
 The mntent_compat.c++ prefers using struct statvfs over struct statfs and
 uses it as if they were interchangeable. On Tru64 they are not interchangeable
 at all. After doing some research I found that the struct members and the flag
 mask macros it is using are fully NetBSD specific. Then I found out that
 mntent_compat.c++ in it's entirety is a pkgsrc patch... So I was trying to fix
 the fix for NetBSD to work on Tru64 which is most probably not the right approach.
 Now I'm stuck.