Bug 2576 - Add EA support for FreeBSD
Summary: Add EA support for FreeBSD
Status: CLOSED FIXED
Alias: None
Product: Samba 3.0
Classification: Unclassified
Component: File Services (show other bugs)
Version: 3.0.13
Hardware: All FreeBSD
: P3 normal
Target Milestone: none
Assignee: Samba Bugzilla Account
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-04-05 18:16 UTC by Timur Bakeyev
Modified: 2005-08-24 10:17 UTC (History)
2 users (show)

See Also:


Attachments
EA supporting code (9.36 KB, patch)
2005-04-05 18:17 UTC, Timur Bakeyev
no flags Details
Required configure checks (1.35 KB, patch)
2005-04-05 18:23 UTC, Timur Bakeyev
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Timur Bakeyev 2005-04-05 18:16:53 UTC
Here is attached a proposed patch that adds EA support for FreeBSD 5.x and,
possibly, latest NetBSD versions.

It need to be verified for the usage of Samba-specific memory and string
management functions, but otherwise should be ok. It was already used with the
Samba port on FreeBSD as a default one and didn't create any problems.

For NetBSD absence of *_link functions may require additional stub code that
will implement them via readlink and *_file calls. Luke, can you, please check it?

Timur aka BaT
Comment 1 Timur Bakeyev 2005-04-05 18:17:49 UTC
Created attachment 1138 [details]
EA supporting code
Comment 2 Timur Bakeyev 2005-04-05 18:23:21 UTC
Created attachment 1139 [details]
Required configure checks
Comment 3 Alex Masterov 2005-04-08 03:14:30 UTC
I've applied patches to 3.0.14pre1-SVN-build-6243
It fails to compile with this error messages:

Compiling lib/system.c
In file included from include/includes.h:451,
                 from lib/system.c:22:
/usr/local/include/ldap.h:649: warning: declaration of 'oid' shadows a global
declaration
/usr/include/krb5_asn1.h:23: warning: shadowed declaration is here
lib/system.c: In function `sys_getxattr':
lib/system.c:1379: error: `EXTATTR_NAMESPACE_SYSTEM' undeclared (first use in
this function)
lib/system.c:1379: error: (Each undeclared identifier is reported only once
lib/system.c:1379: error: for each function it appears in.)
lib/system.c:1379: error: `EXTATTR_NAMESPACE_USER' undeclared (first use in this
function)
lib/system.c:1382: warning: implicit declaration of function `extattr_get_file'
lib/system.c: In function `sys_lgetxattr':
lib/system.c:1406: error: `EXTATTR_NAMESPACE_SYSTEM' undeclared (first use in
this function)
lib/system.c:1406: error: `EXTATTR_NAMESPACE_USER' undeclared (first use in this
function)
lib/system.c:1409: warning: implicit declaration of function `extattr_get_link'
lib/system.c: In function `sys_fgetxattr':
lib/system.c:1433: error: `EXTATTR_NAMESPACE_SYSTEM' undeclared (first use in
this function)
lib/system.c:1433: error: `EXTATTR_NAMESPACE_USER' undeclared (first use in this
function)
lib/system.c:1436: warning: implicit declaration of function `extattr_get_fd'
lib/system.c: At top level:
lib/system.c:1463: error: `EXTATTR_NAMESPACE_SYSTEM' undeclared here (not in a
function)
lib/system.c:1463: error: initializer element is not constant
lib/system.c:1463: error: (near initialization for `extattr[0].space')
lib/system.c:1463: error: initializer element is not constant
lib/system.c:1463: error: (near initialization for `extattr[0]')
lib/system.c:1464: error: `EXTATTR_NAMESPACE_USER' undeclared here (not in a
function)
lib/system.c:1464: error: initializer element is not constant
lib/system.c:1464: error: (near initialization for `extattr[1].space')
lib/system.c:1464: error: initializer element is not constant
lib/system.c:1464: error: (near initialization for `extattr[1]')
lib/system.c: In function `bsd_attr_list':
lib/system.c:1482: warning: implicit declaration of function `extattr_list_file'
lib/system.c:1487: warning: implicit declaration of function `extattr_list_link'
lib/system.c:1492: warning: implicit declaration of function `extattr_list_fd'
lib/system.c: In function `sys_removexattr':
lib/system.c:1672: warning: implicit declaration of function `extattr_delete_file'
lib/system.c: In function `sys_lremovexattr':
lib/system.c:1696: warning: implicit declaration of function `extattr_delete_link'
lib/system.c: In function `sys_fremovexattr':
lib/system.c:1720: warning: implicit declaration of function `extattr_delete_fd'
lib/system.c: In function `sys_setxattr':
lib/system.c:1750: warning: implicit declaration of function `extattr_set_file'
lib/system.c: In function `sys_lsetxattr':
lib/system.c:1778: warning: implicit declaration of function `extattr_set_link'
lib/system.c: In function `sys_fsetxattr':
lib/system.c:1806: warning: implicit declaration of function `extattr_set_fd'
*** Error code 1

Stop in /usr/home/alex/samba-3_0/source.
Comment 4 Alex Masterov 2005-04-08 03:17:04 UTC
FreeBSD 5.4-PRERELEASE
gcc version 3.4.2 [FreeBSD] 20040728
Comment 5 Jeremy Allison 2005-04-08 14:05:31 UTC
Applied - thanks a *lot* for this work !
Jeremy.
Comment 6 Alex Masterov 2005-04-10 19:38:29 UTC
EA support works with FreeBSD 5.4-RELEASE Samba 3.0.14pre1-SVN-build-6269
Comment 7 Gerald (Jerry) Carter (dead mail address) 2005-08-24 10:17:36 UTC
sorry for the same, cleaning up the database to prevent unecessary reopens of bugs.