Disabling priorities allowed "yum install httpd-devel" to work.
PS: i now have priorities as
priority = 10 [asl-3.0]
priority = 10 [asl-3.0-testing]
priority = 20 [virtualmin]
priority = 20 [virtualmin-universal]
priority = 30 [base]
priority = 30 [updates]
priority = 40 [extras]
priority = 50 [epel]
does this seem ok?
The question is about using RPM metadata to retrieve information about package specific compile time options. The information you're looking for isn't present in the RPM metadata. Either you need to have more than just an RPM (ideally a package build log or some of the files from the build directory), or you need to use a package specific way.
I don't know the location of build information for CentOS, for Fedora it would be:
http://koji.fedoraproject.org/
For squid, the package specific way is fairly easy:
# squid -v
Squid Cache: Version 3.4.5
configure options: '--build=x86_64-redhat-linux-gnu' '--host=x86_64-redhat-linux-gnu' '--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' '--sharedstatedir=/var/lib' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--exec_prefix=/usr' '--libexecdir=/usr/lib64/squid' '--localstatedir=/var' '--datadir=/usr/share/squid' '--sysconfdir=/etc/squid' '--with-logdir=$(localstatedir)/log/squid' '--with-pidfile=$(localstatedir)/run/squid.pid' '--disable-dependency-tracking' '--enable-eui' '--enable-follow-x-forwarded-for' '--enable-auth' '--enable-auth-basic=DB,LDAP,MSNT,MSNT-multi-domain,NCSA,NIS,PAM,POP3,RADIUS,SASL,SMB,getpwnam' '--enable-auth-ntlm=smb_lm,fake' '--enable-auth-digest=file,LDAP,eDirectory' '--enable-auth-negotiate=kerberos' '--enable-external-acl-helpers=LDAP_group,time_quota,session,unix_group,wbinfo_group' '--enable-storeid-rewrite-helpers=file' '--enable-cache-digests' '--enable-cachemgr-hostname=localhost' '--enable-delay-pools' '--enable-epoll' '--enable-icap-client' '--enable-ident-lookups' '--enable-linux-netfilter' '--enable-removal-policies=heap,lru' '--enable-snmp' '--enable-ssl' '--enable-ssl-crtd' '--enable-storeio=aufs,diskd,ufs' '--enable-wccpv2' '--enable-esi' '--enable-ecap' '--with-aio' '--with-default-user=squid' '--with-dl' '--with-openssl' '--with-pthreads' 'build_alias=x86_64-redhat-linux-gnu' 'host_alias=x86_64-redhat-linux-gnu' 'CFLAGS=-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -fpie' 'LDFLAGS=-Wl,-z,relro -pie -Wl,-z,relro -Wl,-z,now' 'CXXFLAGS=-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -fpie' 'PKG_CONFIG_PATH=%{_PKG_CONFIG_PATH}:/usr/lib64/pkgconfig:/usr/share/pkgconfig'
(the above output has been made using a Fedora rawhide version of squid)
For other packages, there may or may not be a command to show build time configuration. For downloading, extracting and examining the SRPM to guess compiled in features from the .spec
file, see the end of the other answer.
Best Answer
You'll have to grab the package's source RPM. For example, with apache httpd:
You can extract just the spec file from the source rpm with:
Then, search for the %build section in the RPM spec file.
Sadly, CentOS doesn't appear to keep their spec files in any kind of public repository that I can find on their web site. You'll have to use the above steps to determine how the package is built.
edit: CentOS publishes their specs in Git, so my earlier answer isn’t true now. Here is the httpd spec file:
https://git.centos.org/rpms/httpd/blob/c7/f/SPECS/httpd.spec