libsmbclient-php icon indicating copy to clipboard operation
libsmbclient-php copied to clipboard

look for headers in include/samba-* for --with-libsmbclient

Open bachp opened this issue 6 years ago • 5 comments

This allows to specify a samba install directory via --with-libsmbclient where the header is located under include/samba-4.0/libsmbclient.h

bachp avatar Mar 02 '19 22:03 bachp

I think we should rather rely on pkg-config output, which is the proper way to get build option for a library (and which is now used more in new PHP version, especially in 7.4 with the new PKG_CHECK_MODULES macro)

remicollet avatar Mar 03 '19 07:03 remicollet

@remicollet I agree but now I think this solves the issue too and works with PHP7.0-7.3.

bachp avatar Mar 03 '19 15:03 bachp

Do you find this to still be required @bachp ? Where are you experiencing it? I run Fedora 33 and the header is under include/samba-4.0/ and it has been found fine without this path. Are you talking about specific cases when people install Samba somewhere else?

eduardok avatar Jan 26 '21 23:01 eduardok

@eduardok I encountered the issue while packaging for NixOS. There software is is always installed to an isolated non standard location. So all assumtions about library locations don't work there.

bachp avatar Jan 27 '21 21:01 bachp

@eduardok specifically with the nix package manager (used by NixOS) this header file will be located under a very strange location. For example, one location the libsmbclient headers are installed into on my machine is /nix/store/9i3gs34m1rl2mslmzc5v7nlfnrqy7xbs-samba-4.13.3-dev/include/samba-4.0. This works for most packages because pkg-config reports this or because when building software nix (the package manager which can compile software) can pass flags like --with-libsmbclient specifying a location. Unfortunately it looks like config.m4 is making a few too many assumptions here. It's there any additional information we can provide?

Your software is very useful and we would love to ship it with NixOS! 😃

aanderse avatar Feb 03 '21 01:02 aanderse