Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

src/db_disk.c:198:24: error: variable has incomplete type 'struct stat64' #1

Closed
hdatma opened this issue Mar 7, 2019 · 9 comments
Closed
Labels
support Usage support question/request unreproducible This issue can't be reproduced on member's system.

Comments

@hdatma
Copy link

hdatma commented Mar 7, 2019

In file included from src/db_disk.c:38:
./include/gen_list.h:75:66: warning: declaration of 'struct stat64' will not be visible outside of this function [-Wvisibility]
db_line* get_file_attrs(char* filename,DB_ATTR_TYPE attr, struct AIDE_STAT_TYPE *fs);
                                                                 ^
./config.h:47:24: note: expanded from macro 'AIDE_STAT_TYPE'
#define AIDE_STAT_TYPE stat64
                       ^
src/db_disk.c:173:51: warning: declaration of 'struct stat64' will not be visible outside of this function [-Wvisibility]
static int get_file_status(char *filename, struct AIDE_STAT_TYPE *fs) {
                                                  ^
./config.h:47:24: note: expanded from macro 'AIDE_STAT_TYPE'
#define AIDE_STAT_TYPE stat64
                       ^
src/db_disk.c:175:12: warning: implicit declaration of function 'lstat64' is invalid in C99 [-Wimplicit-function-declaration]
    sres = AIDE_LSTAT_FUNC(filename,fs);
           ^
./config.h:32:25: note: expanded from macro 'AIDE_LSTAT_FUNC'
#define AIDE_LSTAT_FUNC lstat64
                        ^
src/db_disk.c:198:24: error: variable has incomplete type 'struct stat64'
        struct AIDE_STAT_TYPE fs;
                              ^
src/db_disk.c:198:9: note: forward declaration of 'struct stat64'
        struct AIDE_STAT_TYPE fs;
               ^
./config.h:47:24: note: expanded from macro 'AIDE_STAT_TYPE'
#define AIDE_STAT_TYPE stat64
                       ^
 
@hvhaugwitz
Copy link
Member

Thanks for your bug report.

Unfortunately I'm not able to reproduce your issue. Can you please provide more information about how to reproduce your issue (e.g. platform, distribution, source version, exact commands you used, to build AIDE, ....)

@hvhaugwitz hvhaugwitz added bug Something isn't working unreproducible This issue can't be reproduced on member's system. moreinfo This issue can't be addressed until more information is provided by the submitter labels Mar 8, 2019
@hdatma
Copy link
Author

hdatma commented Mar 8, 2019

macos
latest aide release from github

@hvhaugwitz
Copy link
Member

Can you please provide the ./configure command you used?

@hdatma
Copy link
Author

hdatma commented Mar 8, 2019

config_options="--prefix=$prefix \
   --sysconfdir=$etc \
   --mandir=$man \
   --docdir=$doc \
   --disable-static \
   --disable-lfs \
   --with-mhash \
   --without-zlib \
   --without-gcrypt"; 

@hvhaugwitz
Copy link
Member

Still cannot reproduce your issue (on MaOS Mojave (10.14.3)) using your ./configure options:

./aide --version
Aide 0.16.1

Compiled with the following options:

WITH_MMAP
WITH_PCRE
WITH_LSTAT
WITH_READDIR
WITH_MHASH
CONFIG_FILE = “/etc/aide.conf”

@hdatma hdatma closed this as completed Mar 8, 2019
@hdatma hdatma reopened this Mar 8, 2019
@hdatma
Copy link
Author

hdatma commented Mar 8, 2019

I'm on 10.13.

It looks like #include <sys/stat.h> is failing, or 10.14 introduced enough changes to break things. I will upload my file for a comparison.

@hvhaugwitz
Copy link
Member

Please contact the AIDE mailing list to get more help from other MacOS users.

I close this issue for now. It can be reopened later if needed.

@hvhaugwitz hvhaugwitz removed bug Something isn't working moreinfo This issue can't be addressed until more information is provided by the submitter labels Mar 16, 2019
@hdatma
Copy link
Author

hdatma commented Mar 16, 2019

Please diff it with your own /usr/include/sys/stat.h

stat.h.txt

@hvhaugwitz
Copy link
Member

I'm not a MacOS user and only have access to a Mac occasionally, so please contact the AIDE mailing list to get more help from other MacOS users.

@hvhaugwitz hvhaugwitz added the support Usage support question/request label Oct 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
support Usage support question/request unreproducible This issue can't be reproduced on member's system.
Projects
None yet
Development

No branches or pull requests

2 participants