Sanitize python object -> tag number exception handling
[platform/upstream/rpm.git] / platform.in
index 9a6ba8d..4a23a9e 100644 (file)
@@ -3,12 +3,17 @@
 #==============================================================================
 # ---- per-platform macros.
 #
-%_arch                 @RPMRC_ARCH@
+%_arch                 @RPMCANONARCH@
 %_vendor               @RPMCANONVENDOR@
 %_os                   @RPMCANONOS@
+%_gnu                  @RPMRC_GNU@
 %_target_platform      %{_target_cpu}-%{_vendor}-%{_target_os}
 %optflags              @RPMRC_OPTFLAGS@
 
+%__isa_name            @ISANAME@
+%__isa_bits            @ISABITS@
+%__isa                 %{__isa_name}-%{__isa_bits}
+
 #==============================================================================
 # ---- configure macros.
 #
 %_bindir               @bindir@
 %_sbindir              @sbindir@
 %_libexecdir           @libexecdir@
+%_datarootdir          @datarootdir@
 %_datadir              @datadir@
 %_sysconfdir           @sysconfdir@
 %_sharedstatedir       @sharedstatedir@
 %_localstatedir                @localstatedir@
 %_lib                  @LIB@
-%_libdir               @LIBDIR@
+%_libdir               @exec_prefix@/@LIB@
 %_includedir           @includedir@
 %_oldincludedir                @oldincludedir@
 %_infodir              @infodir@
 %_mandir               @mandir@
-%_initrddir            %{_sysconfdir}/rc.d/init.d
+%_initddir             %{_sysconfdir}/rc.d/init.d
+# Deprecated misspelling, present for backwards compatibility.
+%_initrddir            %{_initddir}
+
+%_defaultdocdir                %{_datadir}/doc
 
-%_defaultdocdir                @DEFAULTDOCDIR@
+%_smp_mflags %([ -z "$RPM_BUILD_NCPUS" ] \\\
+       && RPM_BUILD_NCPUS="`/usr/bin/getconf _NPROCESSORS_ONLN`"; \\\
+       [ "$RPM_BUILD_NCPUS" -gt 1 ] && echo "-j$RPM_BUILD_NCPUS")
 
 #==============================================================================
 # ---- Build policy macros.
 #
-#------------------------------------------------------------------------
-#      Expanded at end of %install
+#---------------------------------------------------------------------
+#      Expanded at end of %install scriptlet.
 #
 
 %__arch_install_post   @ARCH_INSTALL_POST@
 
 %__os_install_post    \
-    @prefix@/lib/rpm/brp-compress \
-    @prefix@/lib/rpm/brp-strip \
-    @prefix@/lib/rpm/brp-strip-comment-note \
+    %{_rpmconfigdir}/brp-compress \
+    %{_rpmconfigdir}/brp-strip \
+    %{_rpmconfigdir}/brp-strip-static-archive \
+    %{_rpmconfigdir}/brp-strip-comment-note \
 %{nil}
 
 %__spec_install_post\
-     %{__arch_install_post}\
-     %{__os_install_post}\
+    %{?__debug_package:%{__debug_install_post}}\
+    %{__arch_install_post}\
+    %{__os_install_post}\
 %{nil}
 
-#------------------------------------------------------------------------
-#      Expanded at end of %prep
-#
-%__id_u                        @__ID_U@
-%__chown_Rhf           @__CHOWN_RHF@
-%__chgrp_Rhf           @__CHGRP_RHF@
-%_fixowner             [ `%{__id_u}` = '0' ] && %{__chown_Rhf} root
-%_fixgroup             [ `%{__id_u}` = '0' ] && %{__chgrp_Rhf} @ROOT_GROUP@
-%_fixperms             %{__chmod} -Rf @FIXPERMS@
+@redhat@#---------------------------------------------------------------------
+@redhat@#      Expanded at end of %prep
+@redhat@#
+@redhat@%__id_u                @__ID_U@
+@redhat@%__chown_Rhf   @__CHOWN_RHF@
+@redhat@%__chgrp_Rhf   @__CHGRP_RHF@
+@redhat@%_fixperms     %{__chmod} -Rf @FIXPERMS@
+@redhat@#---------------------------------------------------------------------
+@redhat@#      Always use %defattr(-,root,root) in %files (added in rpm-4.0.4)
+@redhat@#
+@redhat@#%files(n:f:)  %%files%{?-f: -f %{-f*}}%{?-n: -n %{-n*}} %{?1}\
+@redhat@#%defattr(-,root,root,-)\
+@redhat@#%{nil}
 
-@MULTILIBSTART@
-#------------------------------------------------------------------------
-#      Multilibs
-%_multilibno           @MULTILIBNO@
-%_multilibpatt         (/%{_lib}|/usr/%{_lib}(|/gconv)|/usr/local/%{_lib}|/usr/X11R6/%{_lib}|/opt/%{_lib})/[^/]*\\.([oa]|la|so[0-9.]*)$
-@MULTILIBEND@
 
-@mandrake@#------------------------------------------------------------------------
+@apple@#---------------------------------------------------------------------
+@apple@#       Apple Darwin vendor specific macros
+@apple@#
+@apple@%_use_internal_dependency_generator     0
+@apple@%__so   dylib
+
+
+@mandrake@#---------------------------------------------------------------------
 @mandrake@#    Mandrake vendor specific macros
 @mandrake@# XXX Add a support e-mail address here, please.
 @mandrake@#
-@mandrake@#
 @mandrake@# XXX These values, particularly vendor, need to be regularized, please.
 @mandrake@%_vendor             MandrakeSoft
 @mandrake@%_real_vendor                mandrake
 @mandrake@# XXX A copy of brp-mandrake, please. I'd suggest break down by
 @mandrake@#     functionality rather than vendor <shrug>.
 @mandrake@%__os_install_post    \
-@mandrake@    /usr/lib/rpm/brp-mandrake \
+@mandrake@    %{_rpmconfigdir}/brp-mandrake \
 @mandrake@%{nil}
 @mandrake@
 @mandrake@# make