I'm using the Arch Linux and trying to create an AUR file that would download the source of a driver, compile and install it. What I wonder is - how can I check which packages are required for the compilation to succeed (just so I could declare those dependencies in my AUR)? Do I really have to analyze the very long configure file or is there a better way?Edit: or maybe I'm not supposed to add build-dependencies to the usage dependencies in AUR?Edit #2: I'm trying to create AUR for this: http://www.acs.com.hk/download-driver-unified/6258/ACS-Unified-Driver-Lnx-Mac-113-P.zip
Arch Linux: Finding out build-dependencies so they can be turned into AUR dependencies
arch linux;compiling;aur
Most packages want to be helpful when installing them so they will have some dependency information in the README or the INSTALL file.  Otherwise yes, checking the configure script it the only real option (Note: autoconf produces configure.log that enumerates dependencies, and several other configure scripts print a dependency summary at the end to make this easier for packagers).For the problem at hand the README is most useful, it says:Linux- pcsclite 1.8.3 or above- libusb 1.0.9 or above- flex- perl- pkg-configNow, let us have a look at that.  An AUR package can assume that base and base-devel groups of packages are installed, which make things easier to reason about.  Enumerating the dependencies we see:pkg-config: is in base-devel, we do not need to care about it.perl: is part of base, fine.flex: base-devel again.libusb 1.0.9 or above and pcsclite 1.8.3 or abovepacman -Ss libusbcore/libusb 1.0.20-1    Library that provides generic access to USB devicespacman -Ss pcsclitecommunity/pcsclite 1.8.16-1    PC/SC Architecture smartcard middleware libraryThe beauty of a rolling forward distribution is that you can assume that the user has the latest packages (if he is a sane user he will do pacman -Syu before installing your AUR package).  Therefore we can simply do (inside PKGBUILD):depends=(libusb pcsclite)Extra note: Sometimes it is not as easy to find the package a README or INSTALL talks about.  In this case google-fu is needed.  Yet, arch also has pkgfile which is the database of which files are in which packages.For finding dependencies to be added to AUR packages I strongly recommend installing pkgfile, i.e.pacman -S pkgfileAnd then you can query suspicious packages for libraries, e.g.pkgfile -l <package> | grep lib