%distinitials %(grep -i fedora.core /etc/redhat-release >/dev/null && echo "fc" || { grep -i fedora.release /etc/redhat-release >/dev/null && echo "f" || { grep -i "red hat enterprise linux" /etc/redhat-release >/dev/null && echo "el" || echo "RHL"; }; })
%disttaginitials %(grep -i fedora /etc/redhat-release >/dev/null && echo "fc" || { grep -i "red hat enterprise linux" /etc/redhat-release >/dev/null && echo "el" || echo "RHL"; })
%distversion %(rpm -qf --qf='%{VERSION}' /etc/redhat-release | sed -e's,^\\([0-9]*\\)[^0-9].*,\\1,') 
%disttagversion %(rpm -qf --qf='%{VERSION}' /etc/redhat-release | sed -e's,^\\([0-9]*\\)[^0-9].*,\\1,') 
%distname %(grep -i fedora.core /etc/redhat-release >/dev/null && echo "Fedora Core" || { grep -i fedora.release /etc/redhat-release >/dev/null && echo "Fedora" || { grep -i "red hat enterprise linux" /etc/redhat-release >/dev/null && echo "Red Hat Enterprise Linux" || echo "Red Hat Linux"; }; })
%distid %(echo %{distinitials}%{distversion} | sed -e's,\\.,_,g')
%disttag %(echo %{disttaginitials}%{disttagversion} | sed -e's,\\.,_,g')
%dist .%{distinitials}%{distversion}

%eversion	%{?epoch:%{epoch}:}%{version}
%evr		%{?epoch:%{epoch}:}%{version}-%{release}

%__find_requires        /usr/lib/rpm/atrpms/find-requires
%__find_provides        /usr/lib/rpm/atrpms/find-provides
%__os_install_post    \
    /usr/lib/rpm/atrpms/brp-compress \
    /usr/lib/rpm/atrpms/brp-strip %{__strip} \
    /usr/lib/rpm/atrpms/brp-strip-static-archive %{__strip} \
    /usr/lib/rpm/atrpms/brp-strip-comment-note %{__strip} %{__objdump} \
%{nil}

################################################################
%_initdir	%{_sysconfdir}/rc.d/init.d
%_initddir	%{_sysconfdir}/rc.d/init.d
%_varlibdir	%{_localstatedir}/lib
%_varcachedir	%{_localstatedir}/cache
%_logdir		%{_localstatedir}/log
%_rundir		%{_localstatedir}/run
%_subsysdir	%{_localstatedir}/lock/subsys
%_sysconfigdir	%{_sysconfdir}/sysconfig
%_logrotatedir	%{_sysconfdir}/logrotate.d

###

%sgmlbase	%{_datadir}/sgml
%sgmlcatdir	%{_sysconfdir}/sgml
%rootcat	%{sgmlcatdir}/catalog

%xmlbase	%{_datadir}/xml
%xmlcatdir	%{_sysconfdir}/xml
%rootxmlcat	%{xmlcatdir}/catalog

################################################################ python
# setup ... --root ...
%python_version	%(python -c "import sys; print sys.version[:3]")
#python_libdir	%(python -c "from distutils import sysconfig; print sysconfig.get_python_lib()")

#python_libdir  %(python -c "from distutils import sysconfig; print sysconfig.get_python_lib()" | sed -e's,/usr/lib/,%{_libdir}/,')
#python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")
#python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")

%python_libdir %{_libdir}/python%{python_version}/site-packages
%python_sitelib /usr/lib/python%{python_version}/site-packages
%python_sitearch %{_libdir}/python%{python_version}/site-packages


%python_burninversion %{nil}
#test -d %{buildroot} && find %{buildroot} -type f | xargs grep -l '^#!.*python' | xargs perl -pi -e's,^(#!.*python)[0-9.]*,${1}%python_version,'
################################################################ tex

%texmf           %{_datadir}/texmf
%texmflocal      %{_datadir}/texmf-local
%vartexmf        %{_datadir}/texmf-var


################################################################ (x)emacs
%emacspkgdir %{_datadir}/emacs/site-lisp

# >= RH9
%xemacspkgdir %{_datadir}/xemacs/site-packages
%vendorxemacspkgdir %{_datadir}/xemacs/xemacs-packages
%xemacssitestart %{_datadir}/xemacs/site-packages/lisp/site-start.d
# <= RH8_0
#xemacspkgdir %{_libdir}/xemacs/site-packages
#vendorxemacspkgdir %{_libdir}/xemacs/xemacs-packages
#xemacssitestart %{_libdir}/xemacs/xemacs-packages/lisp/site-start.d

%_x_prefix %(echo %{expand:%%_x_prefix_%{distid}} | grep '^%' > /dev/null && echo %{_prefix} || echo %{expand:%%_x_prefix_%{distid}})
%_x_includes %(echo %{expand:%%_x_includes_%{distid}} | grep '^%' > /dev/null && echo %{_includedir} || echo %{expand:%%_x_includes_%{distid}})
%_x_libraries %(echo %{expand:%%_x_libraries_%{distid}} | grep '^%' > /dev/null && echo %{_libdir} || echo %{expand:%%_x_libraries_%{distid}})
%_x_module_path %(echo %{expand:%%_x_module_path_%{distid}} | grep '^%' > /dev/null && echo %{_libdir}/xorg/modules || echo %{expand:%%_x_module_path_%{distid}})
%_x_bindir %(echo %{expand:%%_x_bindir_%{distid}} | grep '^%' > /dev/null && echo %{_bindir} || echo %{expand:%%_x_bindir_%{distid}})

%_x_prefix_el4 /usr/X11R6
%_x_includes_el4 /usr/X11R6/include
%_x_libraries_el4 /usr/X11R6/%{_lib}
%_x_module_path_el4 /usr/X11R6/%{_lib}/modules
%_x_bindir_el4 /usr/X11R6/bin
%_x_prefix_el3 /usr/X11R6
%_x_includes_el3 /usr/X11R6/include
%_x_libraries_el3 /usr/X11R6/%{_lib}
%_x_module_path_el3 /usr/X11R6/%{_lib}/modules
%_x_bindir_el3 /usr/X11R6/bin
%_x_prefix_fc4 /usr/X11R6
%_x_includes_fc4 /usr/X11R6/include
%_x_libraries_fc4 /usr/X11R6/%{_lib}
%_x_module_path_fc4 /usr/X11R6/%{_lib}/modules
%_x_bindir_fc4 /usr/X11R6/bin
%_x_prefix_fc3 /usr/X11R6
%_x_includes_fc3 /usr/X11R6/include
%_x_libraries_fc3 /usr/X11R6/%{_lib}
%_x_module_path_fc3 /usr/X11R6/%{_lib}/modules
%_x_bindir_fc3 /usr/X11R6/bin
%_x_prefix_fc2 /usr/X11R6
%_x_includes_fc2 /usr/X11R6/include
%_x_libraries_fc2 /usr/X11R6/%{_lib}
%_x_module_path_fc2 /usr/X11R6/%{_lib}/modules
%_x_bindir_fc2 /usr/X11R6/bin
%_x_prefix_fc1 /usr/X11R6
%_x_includes_fc1 /usr/X11R6/include
%_x_libraries_fc1 /usr/X11R6/%{_lib}
%_x_module_path_fc1 /usr/X11R6/%{_lib}/modules
%_x_bindir_fc1 /usr/X11R6/bin
%_x_prefix_rh9 /usr/X11R6
%_x_includes_rh9 /usr/X11R6/include
%_x_libraries_rh9 /usr/X11R6/%{_lib}
%_x_module_path_rh9 /usr/X11R6/%{_lib}/modules
%_x_bindir_rh9 /usr/X11R6/bin
%_x_prefix_rh8_0 /usr/X11R6
%_x_includes_rh8_0 /usr/X11R6/include
%_x_libraries_rh8_0 /usr/X11R6/%{_lib}
%_x_module_path_rh8_0 /usr/X11R6/%{_lib}/modules
%_x_bindir_rh8_0 /usr/X11R6/bin
%_x_prefix_rh7_3 /usr/X11R6
%_x_includes_rh7_3 /usr/X11R6/include
%_x_libraries_rh7_3 /usr/X11R6/%{_lib}
%_x_module_path_rh7_3 /usr/X11R6/%{_lib}/modules
%_x_bindir_rh7_3 /usr/X11R6/bin



%__spec_install_post\
    %{?__debug_package:%{__debug_install_post}}\
    %{?__lib_packages:%{__lib_install_post}}\
    %{?__devel_package:%{__devel_install_post}}\
    /usr/lib/rpm/atrpms/python_burninversion.sh\
    %{__arch_install_post}\
    %{__os_install_post}\
%{nil}

%prep \
%%prep\
LANG=C\
export LANG\
unset DISPLAY || :\
%{nil}

%build %%build\
LANG=C\
export LANG\
unset DISPLAY || :\
%{nil}

%install %{?_enable_debug_packages:%{?buildsubdir:%{debug_package}}}\
%{?__lib_packages:%{expand:%__lib_packages}}\
%{?_enable_devel_packages:%{devel_package}}\
%%install\
LANG=C\
export LANG\
unset DISPLAY || :\
%{nil}




################################################################ perl

# Two of these are already provided
#perl_archlib		%(eval "`perl -V:installarchlib`"; echo $installarchlib)
%perl_privlib		%(eval "`perl -V:installprivlib`"; echo $installprivlib)

#perl_sitearch		%(eval "`perl -V:installsitearch`"; echo $installsitearch)
%perl_sitelib		%(eval "`perl -V:installsitelib`"; echo $installsitelib)

%perl_vendorarch	%(eval "`perl -V:installvendorarch`"; echo $installvendorarch)
%perl_vendorlib		%(eval "`perl -V:installvendorlib`"; echo $installvendorlib)

%perl_bin		%(eval "`perl -V:installbin`"; echo $installbin)
%perl_script		%(eval "`perl -V:installscript`"; echo $installscript)
%perl_man1dir		%(eval "`perl -V:installman1dir`"; echo $installman1dir)
%perl_man3dir		%(eval "`perl -V:installman3dir`"; echo $installman3dir)

%perl_version		%(eval "`perl -V:version`"; echo $version)

%perl_module() %{expand:%%global pkgname %1}\
Requires: atrpms-perl-module-helper \
BuildRequires: perl, atrpms-perl-module-helper\
#Requires: perl(:MODULE_COMPAT_%perl_version) \
Requires: %(perl -MConfig -le 'if (defined $Config{useithreads}) { print "perl(:WITH_ITHREADS)" } else { print "perl(:WITHOUT_ITHREADS)" }')\
Requires: %(perl -MConfig -le 'if (defined $Config{usethreads}) { print "perl(:WITH_THREADS)" } else { print "perl(:WITHOUT_THREADS)" }')\
Requires: %(perl -MConfig -le 'if (defined $Config{uselargefiles}) { print "perl(:WITH_LARGEFILES)" } else { print "perl(:WITHOUT_LARGEFILES)" }')\
Name: perl-%1\
Version: %2\
Release: %3%{?dist}\
%{nil}

%perl_module_wo_prefix() %{expand:%%global pkgname %1}\
Requires: atrpms-perl-module-helper \
BuildRequires: perl, atrpms-perl-module-helper\
#Requires: perl(:MODULE_COMPAT_%perl_version) \
Requires: %(perl -MConfig -le 'if (defined $Config{useithreads}) { print "perl(:WITH_ITHREADS)" } else { print "perl(:WITHOUT_ITHREADS)" }')\
Requires: %(perl -MConfig -le 'if (defined $Config{usethreads}) { print "perl(:WITH_THREADS)" } else { print "perl(:WITHOUT_THREADS)" }')\
Requires: %(perl -MConfig -le 'if (defined $Config{uselargefiles}) { print "perl(:WITH_LARGEFILES)" } else { print "perl(:WITHOUT_LARGEFILES)" }')\
Name: %1\
Version: %2\
Release: %3%{?dist}\
%{nil}

#_perl_extra_path	%{buildroot}%{perl_sitearch}:%{buildroot}%{perl_sitelib}:%{perl_sitearch}:%{perl_sitelib}
%_perl_extra_path	%{buildroot}%{perl_vendorarch}:%{buildroot}%{perl_vendorlib}
%_perl5lib		test -z "$PERL5LIB" && export PERL5LIB=%{_perl_extra_path} || export PERL5LIB="$PERL5LIB":%{_perl_extra_path}

%_perl_buildroot	$(DESTDIR_REDIRECT)

# Install by default in vendor, add INSTALLDIRS=perl or site, if appropriate.
%perl_configure() %{_perl5lib} \
  test -z "$CFLAGS" && export CFLAGS="%{optflags}" \
  %{__perl} Makefile.PL 'PREFIX=%{_perl_buildroot}%{_prefix}' INSTALLDIRS=vendor %* \
  %{__perl} -pi -e 's/^\tLD_RUN_PATH=[^\s]+\s*/\t/' Makefile \
  %{nil}

%perl_make %{_perl5lib}\
  %{__make} OPTIMIZE="$RPM_OPT_FLAGS" \
  %{nil}


%perl_makecheck() %{_perl5lib}\
%if %{?_without_check:0}%{!?_without_check:1}\
%{__make} test %*\
%endif \
%{nil}


# removed second find, FC4's find looks broken ... (?)
%perl_makeinstall_nofc4() %{_perl5lib}\
%{__make} install DESTDIR_REDIRECT=%{buildroot} %*\
find %{buildroot} \\( -name .packlist -or -name perllocal.pod -or \\( -name '*.bs' -a -empty \\) \\) -exec /bin/rm -f {} \\;\
find %{buildroot} -type d -depth -empty -exec rmdir {} \\; \
%{nil}

%perl_makeinstall() %{_perl5lib}\
%{__make} install DESTDIR_REDIRECT=%{buildroot} %*\
find %{buildroot} \\( -name .packlist -or -name perllocal.pod -or \\( -name '*.bs' -a -empty \\) \\) -exec /bin/rm -f {} \\;\
%{nil}

# kflavour access only in lirc, deprecated

%kmdl_kernelsrcdir	/lib/modules/%(uname -r)/build
%_kernel		%(echo -e 'include Makefile\\nlkjh:\\n\\techo $(KERNELVERSION)\\n' | make -f /dev/stdin -sC %{kmdl_kernelsrcdir} lkjh)

%kmdl_userland		%(test "%{_kpkgname}" = "%%{_kpkgname}" && echo 1 || echo 0)

%_kflavour	%(echo %{_kernel} | grep -E '(smp|bigmem|hugemem|largesmp|xen0|xenU|xen|kdump|debug|PAE|PAEdebug)' | sed -e's/^.*\\(smp\\|bigmem\\|hugemem\\|largesmp\\|xen0\\|xenU\\|xen\\|kdump\\|debug\\|PAE\\|PAEdebug\\).*$/\\1/')

%_kversion1	%(echo %{_kernel} | sed -e's/^\\(.*\\)\\(smp\\|bigmem\\|hugemem\\|largesmp\\|xen0\\|xenU\\|xen\\|kdump\\|debug\\|PAE\\|PAEdebug\\).*$/\\1/')
%_kversion	%(echo %{expand:%%_kversion_%{distid}} | grep '^%' > /dev/null && echo %{_kversion1} || echo %{expand:%%_kversion_%{distid}})
%_kversion_f10	%(echo %{_kernel} | sed -e's/^\\(.*\\)\.[^.]*\.\\(smp\\|bigmem\\|hugemem\\|largesmp\\|xen0\\|xenU\\|xen\\|kdump\\|debug\\|PAE\\|PAEdebug\\).*$/\\1/')
%_kversion_f11	%(echo %{_kernel} | sed -e's/^\\(.*\\)\.[^.]*\.\\(smp\\|bigmem\\|hugemem\\|largesmp\\|xen0\\|xenU\\|xen\\|kdump\\|debug\\|PAE\\|PAEdebug\\).*$/\\1/')
%_kversion_f12	%(echo %{_kernel} | sed -e's/^\\(.*\\)\.[^.]*\.\\(smp\\|bigmem\\|hugemem\\|largesmp\\|xen0\\|xenU\\|xen\\|kdump\\|debug\\|PAE\\|PAEdebug\\).*$/\\1/')

%_kernelnoarch		%(echo %{expand:%%_kernelnoarch_%{distid}} | grep '^%' > /dev/null && echo %{_kernel} || echo %{expand:%%_kernelnoarch_%{distid}})
%_kernelnoarch_f10	%(echo %{_kernel} | sed -e's/\\.%{_target_cpu}//')
%_kernelnoarch_f11	%(echo %{_kernel} | sed -e's/\\.%{_target_cpu}//')
%_kernelnoarch_f12	%(echo %{_kernel} | sed -e's/\\.%{_target_cpu}//')

# The name of the kernel with flavour ("kernel", "kernel-smp", ...)
%_kname		%(echo kernel-%{_kflavour} | sed -e's/-$//')

# "kernel": the output of "uname -r" of the kernel to build for
# (default: the running one)
# "_kernelsrcdir": The directory of the sources used to build "kernel"
# (default: /lib/modules/%{_kernel}/build)

#
%kmdl_name_with_arch %{_kpkgname}-kmdl-%{_kernel}
%kmdl_name %{_kpkgname}-kmdl-%{_kernelnoarch}
%kmdl_nameof() %1-kmdl-%{_kernel}
%kmdl_namepure %{_kpkgname}-kmdl
%kmdl_namepureof() %1-kmdl
#
%kmdl_name_old kernel-module-%{_kpkgname}-%{_kernel}
%kmdl_nameof_old() kernel-module-%1-%{_kernel}
%kmdl_namepure_old kernel-module-%{_kpkgname}
%kmdl_namepureof_old() kernel-module-%1

%_kernelbuildreq %{nil}

%kmdl() \
%{expand:%%global _kpkgname %1} \
%_kernelbuildreq \
%{nil}

%kmdl_parentdependencies\
Requires: %{kmdl_namepure}-%{evr}

%kmdl_dependencies\
#Requires: atrpms-kmdl-helper \
#Requires: strictdep-%{_kname}-%{_target_cpu} = %{_kversion}\
Requires: /boot/vmlinuz-%{_kernel}\
#Doesn't work with kernel-suspend2\
#Requires: %{_kname} = %{_kversion}\
Requires: /sbin/depmod, modutils >= 2.4.14\
BuildRequires: %_kernelcompiler\
Provides: %kmdl_namepure-%{evr}\
Provides: %kmdl_namepure-%_kernel = %{evr}\
Provides: %kmdl_name_with_arch\
#\
# backward compatibility kernel-module-foo\
#Provides: %kmdl_namepure_old-%{evr}\
#Provides: %kmdl_namepure_old-%_kernel = %{evr}\
Obsoletes: %kmdl_namepure_old-%{evr}, %kmdl_namepure_old-%_kernel <= %{evr}

# Some distributions use a different compiler than the default one for
# building the kernel
%_kernelcompiler %(echo %{expand:%%_kernelcompiler_%{distid}} | grep '^%' > /dev/null && echo /usr/bin/gcc || echo %{expand:%%_kernelcompiler_%{distid}})
%_kernelcompiler_fc1 /usr/bin/gcc32

%kmdl_moduledir /lib/modules/%{_kernel}/updates

%kmdl_config\
export CC=%_kernelcompiler

%kmdl_desc\
This package contains the %kmdl_name kernel modules for the Linux kernel package:\
%{_kname}-%{_kversion}.%{_target_cpu}.rpm.

%_kernelname %{_kname}-%{_kversion}.%{_target_cpu}.rpm

%kmdl_install\
#%{_datadir}/atrpms/addcustomkmdl '/lib/modules/`uname -r`/updates'\
depmod -ae -F /boot/System.map-%{_kernel} %{_kernel} > /dev/null 2>&1 || :

%kmdl_remove\
depmod -ae -F /boot/System.map-%{_kernel} %{_kernel} > /dev/null 2>&1 || :

## Note^2: A modified copy to reflect different debuginfo packages for kmdls
%debuginfoname %(test "%{kmdl_userland}" = 1 && echo debuginfo || echo "-n %{kmdl_name}-debuginfo")

#	Template for debug information sub-package.
# NOTE: This is a copy from rpm to get the ifnarch noarch fix, it can be removed later
%debug_package \
%ifnarch noarch\
%global __debug_package 1\
%package %{debuginfoname} \
Summary: Debug information for package %{name}\
Group: Development/Debug\
%description %{debuginfoname}\
This package provides debug information for package %{name}.\
Debug information is useful when developing applications that use this\
package or when debugging this package.\
%files %{debuginfoname} -f debugfiles.list\
%defattr(-,root,root)\
%endif\
%{nil}

#
#       Path to script that creates debug symbols in a /usr/lib/debug
#       shadow tree.
%__debug_install_post   \
   /usr/lib/rpm/atrpms/find-debuginfo.sh %{_builddir}/%{?buildsubdir}\
%{nil}

#######################################################################################################
%__lib_name() lib%(echo %1 | grep '[0-9]$' > /dev/null && echo %{1}_%2 || echo %1%2)

%lib_package() \
%global __lib_dependencies %{?__lib_dependencies:%(echo -n %__lib_dependencies | sed -e's,%%,%%%%,g'),}%%%%{__lib_name %1 %2} = %{evr}\
%global __lib_packages %{?__lib_packages:%(echo %__lib_packages | sed -e's,%%,%%%%,g')}%%%%{__lib_package %1 %2}\
%global __lib_package_list %{?__lib_package_list:%(echo %__lib_package_list | sed -e's,%%,%%%%,g')} %1 %2


%__lib_package() \
%global _enable_devel_packages 1\
%global __the_lib_name lib%(echo %1 | grep '[0-9]$' > /dev/null && echo %{1}_%2 || echo %1%2)\
%package -n %__the_lib_name\
Summary: Shared libraries for package %{name}\
Group: System Environment/Libraries\
Provides: shared-library-package\
%(echo %__the_lib_name | grep -- - > /dev/null && echo "Obsoletes: %__the_lib_name" | sed -e's,-,,g')\
%description -n %__the_lib_name\
This package provides the shared libraries lib%1.so.%{2}* for the package %{name}.\
Shared libraries are required at runtime for software built against %{name}.\
Keeping shared libraries in a separate package enables their use as\
forward/backward compatibility packages.\
%post -n %__the_lib_name -p /sbin/ldconfig\
%postun -n %__the_lib_name -p /sbin/ldconfig\
%if %{kmdl_userland}\
%files -n %__the_lib_name -f %{__the_lib_name}.list \
%endif\
%{nil}

%lib_dependencies %{?__lib_dependencies:Requires: %{expand:%__lib_dependencies}}

%devel_extra_Requires() \
%global __devel_extra_Requires %{?__devel_extra_Requires:%__devel_extra_Requires, }%*

%devel_extra_Obsoletes() \
%global __devel_extra_Obsoletes %{?__devel_extra_Obsoletes:%__devel_extra_Obsoletes, }%*

%devel_extra_Provides() \
%global __devel_extra_Provides %{?__devel_extra_Provides:%__devel_extra_Provides, }%*

%devel_extra_Conflicts() \
%global __devel_extra_Conflicts %{?__devel_extra_Conflicts:%__devel_extra_Conflicts, }%*

#
%devel_package \
%global __devel_package 1\
%package devel\
Summary: Development files for building against the %{name} package\
Group: Development/Libraries\
%lib_dependencies\
%{?__devel_extra_Requires:Requires: %{__devel_extra_Requires}}\
%{?__devel_extra_Obsoletes:Obsoletes: %{__devel_extra_Obsoletes}}\
%{?__devel_extra_Provides:Provides: %{__devel_extra_Provides}}\
%{?__devel_extra_Conflicts:Conflicts: %{__devel_extra_Conflicts}}\
%description devel\
This package provides the files necessary for development against\
%{name}. Use this package if you need to build a package depending on\
%{name} at build time, or if you want to do your own development\
against %{name}.\
%if %{kmdl_userland}\
%files devel -f develfiles.list\
%defattr(-,root,root,-)\
%endif\
%{nil}

%__lib_install_post \
   /usr/lib/rpm/atrpms/find-lib.sh %{buildroot} %{_builddir}/%{buildsubdir} %{__lib_package_list} \
%{nil}

%__devel_install_post   \
   /usr/lib/rpm/atrpms/find-devel.sh %{buildroot} %{_builddir}/%{buildsubdir}\
%{nil}
# /etc/rpm/macros.bcond
# macros used in rpm 4.4, not available in previous versions
%bcond_with()		%{expand:%%{?_with_%{1}:%%global with_%{1} 1}}
%bcond_without()	%{expand:%%{!?_without_%{1}:%%global with_%{1} 1}}
%with()		%{expand:%%{?with_%{1}:1}%%{!?with_%{1}:0}}
%without()	%{expand:%%{?with_%{1}:0}%%{!?with_%{1}:1}}
