From 249b92793c7452bcb09c667555d48f0a1f0fc560 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Michael=20Schr=C3=B6der?= Date: Fri, 14 Sep 2007 16:31:05 +0000 Subject: [PATCH] - add sl10.3 config [#310089] - also look for BuildRequires in subpackage definitions [#305568] - allow removal of more config parameters --- Build.pm | 24 +++- Build/Rpm.pm | 5 +- configs/default.conf | 2 +- configs/sl10.3.conf | 316 +++++++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 341 insertions(+), 6 deletions(-) create mode 100644 configs/sl10.3.conf diff --git a/Build.pm b/Build.pm index c9c76dd..0bf4633 100644 --- a/Build.pm +++ b/Build.pm @@ -144,7 +144,11 @@ sub read_config { my $l0 = lc($ll); if ($l0 eq 'macros:') { $l =~ s/.*?\n//s; - $config->{'rawmacros'} .= $l; + if ($l =~ /^!\n/s) { + $config->{'rawmacros'} = substr($l, 2); + } else { + $config->{'rawmacros'} .= $l; + } next; } if ($l0 eq 'preinstall:' || $l0 eq 'vminstall:' || $l0 eq 'required:' || $l0 eq 'support:' || $l0 eq 'keep:' || $l0 eq 'prefer:' || $l0 eq 'ignore:' || $l0 eq 'conflict:' || $l0 eq 'runscripts:') { @@ -161,14 +165,26 @@ sub read_config { } elsif ($l0 eq 'substitute:') { next unless @l; $ll = shift @l; - $config->{'substitute'}->{$ll} = [ @l ]; + if ($ll eq '!*') { + $config->{'substitute'} = {}; + } elsif ($ll =~ /^!(.*)$/) { + delete $config->{'substitute'}->{$1}; + } else { + $config->{'substitute'}->{$ll} = [ @l ]; + } } elsif ($l0 eq 'optflags:') { next unless @l; $ll = shift @l; $config->{'optflags'}->{$ll} = join(' ', @l); } elsif ($l0 eq 'order:') { - for (@l) { - $config->{'order'}->{$_} = 1; + for my $l (@l) { + if ($l eq '!*') { + $config->{'order'} = {}; + } elsif ($l =~ /^!(.*)$/) { + delete $config->{'order'}->{$1}; + } else { + $config->{'order'}->{$l} = 1; + } } } elsif ($l0 eq 'repotype:') { $config->{'repotype'} = [ @l ]; diff --git a/Build/Rpm.pm b/Build/Rpm.pm index 057130c..069681a 100644 --- a/Build/Rpm.pm +++ b/Build/Rpm.pm @@ -133,6 +133,7 @@ sub parse { my @macros = @{$config->{'macros'}}; my $skip = 0; my $main_preamble = 1; + my $preamble = 1; my $inspec = 0; my $hasif = 0; while (1) { @@ -322,7 +323,7 @@ sub parse { } next; } - if ($main_preamble && ($line =~ /^(BuildRequires|BuildConflicts|\#\!BuildIgnore):\s*(\S.*)$/i)) { + if ($preamble && ($line =~ /^(BuildRequires|BuildConflicts|\#\!BuildIgnore):\s*(\S.*)$/i)) { my $what = $1; my $deps = $2; $ifdeps = 1 if $hasif; @@ -389,10 +390,12 @@ sub parse { } else { push @subpacks, "$packname-$2" if defined $packname; } + $preamble = 1; } if ($line =~ /^\s*%(package|prep|build|install|check|clean|preun|postun|pretrans|posttrans|pre|post|files|changelog|description|triggerpostun|triggerun|triggerin|trigger|verifyscript)/) { $main_preamble = 0; + $preamble = 0; } # do this always? diff --git a/configs/default.conf b/configs/default.conf index f718672..50e4aee 120000 --- a/configs/default.conf +++ b/configs/default.conf @@ -1 +1 @@ -sl10.2.conf \ No newline at end of file +sl10.3.conf \ No newline at end of file diff --git a/configs/sl10.3.conf b/configs/sl10.3.conf new file mode 100644 index 0000000..03b71c0 --- /dev/null +++ b/configs/sl10.3.conf @@ -0,0 +1,316 @@ +%define gcc_version 42 + +Preinstall: aaa_base acl attr bash coreutils diffutils +Preinstall: filesystem fillup glibc grep insserv libacl libattr +Preinstall: libbz2-1 libgcc%{gcc_version} libxcrypt m4 ncurses pam +Preinstall: permissions popt libreadline5 rpm sed tar zlib + +Runscripts: aaa_base + +VMinstall: util-linux perl-base libdb-4_5 libvolume_id + +Required: autoconf automake binutils bzip2 gcc gcc%{gcc_version} +Required: gettext glibc libtool ncurses perl rpm zlib + +Support: audit-libs cpio cpp cpp%{gcc_version} cracklib cvs +Support: file findutils gawk gdbm gettext-devel +Support: glibc-devel glibc-locale groff gzip info less +Support: libbz2-devel libdb-4_5 +Support: libltdl-3 libmudflap%{gcc_version} libstdc++%{gcc_version} +Support: libvolume_id libxcrypt libzio +Support: linux-kernel-headers make man mktemp netcfg +Support: net-tools pam-modules patch perl-base sysvinit +Support: texinfo timezone util-linux +%ifarch ia64 +Support: libunwind libunwind-devel +%endif + +Keep: audit-libs binutils bzip2 cpp cracklib file findutils gawk gcc gcc-ada gcc-c++ +Keep: gdbm glibc-devel glibc-locale gzip libada +Keep: libunwind libunwind-devel libzio make mktemp pam-devel pam-modules +Keep: patch perl-base perl rcs timezone +Keep: cpp%{gcc_version} gcc%{gcc_version} gcc%{gcc_version}-ada libstdc++%{gcc_version} +Keep: cpp41 gcc41 gcc41-ada libstdc++41 + +Prefer: libreadline5 +Prefer: libdb_java-4_5 libltdl-3 libicu +Prefer: cracklib-dict-small postfix +Prefer: jta libpng fam mozilla mozilla-nss +Prefer: unixODBC libsoup glitz +Prefer: java-1_5_0-sun java-1_5_0-sun-jdbc java-1_5_0-sun-devel java-1_5_0-bea-devel +Prefer: gnome-panel desktop-data-SuSE gnome2-SuSE +Prefer: mono-nunit gecko-sharp2 +Prefer: apache2-prefork Mesa openmotif-libs ghostscript-mini ghostscript-library +Prefer: gtk-sharp2 glib-sharp2 glade-sharp2 +Prefer: libzypp-zmd-backend novell-NLDAPsdk zaptel-kmp-default +Prefer: hbedv-dazuko-kmp-default dazuko-kmp-default vmware-wkstnmods-kmp-default +Prefer: virtualbox-kmp-default +Prefer: libstdc++%{gcc_version} libgcc%{gcc_version} libmudflap%{gcc_version} + +Prefer: gnome-sharp2:art-sharp2 gnome-sharp:art-sharp +Prefer: ifolder3:gnome-sharp2 ifolder3:gconf-sharp2 +Prefer: nautilus-ifolder3:gnome-sharp2 inkscape:gtkmm24 +Prefer: gconf-sharp2:glade-sharp2 gconf-sharp:glade-sharp +Prefer: saxon:java-1_4_2-cacao gjdoc:antlr +Prefer: tomboy:gconf-sharp2 tomboy:gnome-sharp2 +Prefer: zmd:libzypp-zmd-backend +Prefer: yast2-packagemanager-devel:yast2-packagemanager +Prefer: glitz-32bit:Mesa-32bit +Prefer: poppler-tools +Prefer: banshee:banshee-engine-gst helix-banshee:helix-banshee-engine-gst +Prefer: java-1_5_0-ibm:java-1_5_0-ibm-alsa +Prefer: java-1_5_0-ibm-devel +Prefer: microcode_ctl:kernel-default +Prefer: notification-daemon +Prefer: pkg-config gtk-doc wlan-kmp-default lua-libs +Prefer: gnu-jaf gnu-javamail avahi-compat-mDNSResponder yast2-control-center-qt +Prefer: vim-normal myspell-american wine +Prefer: eclipse-platform eclipse-scripts +Prefer: yast2-theme-openSUSE + +Prefer: -bundle-lang-kde-de -bundle-lang-kde-en -bundle-lang-kde-es +Prefer: -bundle-lang-kde-fr -bundle-lang-kde-pt +Prefer: -bundle-lang-kde-zh -bundle-lang-kde-ja -bundle-lang-kde-ru -bundle-lang-kde-pl +Prefer: -bundle-lang-kde-sv -bundle-lang-kde-ko -bundle-lang-kde-fi -bundle-lang-kde-da +Prefer: -bundle-lang-kde-cs -bundle-lang-kde-nl -bundle-lang-kde-hu -bundle-lang-kde-nb +Prefer: -bundle-lang-kde-it -bundle-lang-kde-ca -bundle-lang-kde-ar +Prefer: -bundle-lang-gnome-es -bundle-lang-gnome-de -bundle-lang-gnome-fr +Prefer: -bundle-lang-gnome-pt -bundle-lang-gnome-en +Prefer: -bundle-lang-gnome-zh -bundle-lang-gnome-ja -bundle-lang-gnome-ru -bundle-lang-gnome-cs +Prefer: -bundle-lang-gnome-ko -bundle-lang-gnome-da -bundle-lang-gnome-nl -bundle-lang-gnome-hu +Prefer: -bundle-lang-gnome-pl -bundle-lang-gnome-fi -bundle-lang-gnome-nb -bundle-lang-gnome-sv +Prefer: -bundle-lang-gnome-it -bundle-lang-gnome-ca -bundle-lang-gnome-ar +Prefer: -bundle-lang-common-es -bundle-lang-common-de -bundle-lang-common-fr +Prefer: -bundle-lang-common-pt -bundle-lang-common-en +Prefer: -bundle-lang-common-ja -bundle-lang-common-zh -bundle-lang-common-cs -bundle-lang-common-ru +Prefer: -bundle-lang-common-nl -bundle-lang-common-hu -bundle-lang-common-pl -bundle-lang-common-da +Prefer: -bundle-lang-common-ko -bundle-lang-common-nb -bundle-lang-common-fi -bundle-lang-common-sv +Prefer: -bundle-lang-common-it -bundle-lang-common-ca -bundle-lang-common-ar +Prefer: -libgcc-mainline -libstdc++-mainline -gcc-mainline-c++ +Prefer: -libgcj-mainline -viewperf -compat -compat-openssl097g +Prefer: -zmd -OpenOffice_org -pam-laus -libgcc-tree-ssa -busybox-links +%if ! 0%{?opensuse_bs} +Prefer: -crossover-office -java-1_5_0-ibm -java-1_5_0-ibm-jdbc +Prefer: -java-1_4_2-gcj-compat -java-1_4_2-gcj-compat-devel +%endif +Prefer: -java-1_4_2-cacao -java-1_4_2-cacao-devel -java-1_4_2-ibm -java-1_4_2-ibm-devel +Prefer: -NX -xaw3dd -db43 +Prefer: -xerces-j2-xml-resolver -xerces-j2-xml-apis +Prefer: -vmware-player +Prefer: -libgcc41 -libgcc41-32bit -libgcc41-64bit +Prefer: -libffi41 +Prefer: -libgcc43 -libgcc43-32bit -libgcc43-64bit +Prefer: -libffi43 -libgomp43 +Prefer: -libnetpbm -libcdio7-mini -libiso9660-5-mini +Prefer: -libcdio-mini -faac-mini + +Conflict: ghostscript-library:ghostscript-mini + +Ignore: cracklib:cracklib-dict +Ignore: aaa_base:aaa_skel,suse-release,logrotate,ash,mingetty,distribution-release,udev +Ignore: gettext-devel:libgcj,libstdc++-devel,libgcj41,libstdc++41-devel,libgcj42,libstdc++42-devel +Ignore: libgcj43,libstdc++43-devel +Ignore: pwdutils:openslp +Ignore: pam-modules:resmgr +Ignore: rpm:suse-build-key,build-key +Ignore: bind-utils:bind-libs +Ignore: alsa:dialog,pciutils +Ignore: portmap:syslogd +Ignore: fontconfig:freetype2 +Ignore: fontconfig-devel:freetype2-devel +Ignore: xorg-x11-libs:freetype2 +Ignore: xorg-x11:x11-tools,resmgr,xkeyboard-config,xorg-x11-Mesa,libusb,freetype2,libjpeg,libpng +Ignore: xorg-x11-server:xorg-x11-driver-input,xorg-x11-driver-video +Ignore: apache2:logrotate +Ignore: arts:alsa,audiofile,resmgr,libogg,libvorbis +Ignore: kdelibs3:alsa,arts,pcre,OpenEXR,aspell,cups-libs,mDNSResponder-lib,krb5,libjasper +Ignore: kdelibs3-devel:libvorbis-devel +Ignore: kdebase3:kdebase3-ksysguardd,OpenEXR,dbus-1,dbus-1-qt,hal,powersave,openslp,libusb +Ignore: kdebase3-SuSE:release-notes +Ignore: jack:alsa,libsndfile +Ignore: libxml2-devel:readline-devel +Ignore: gnome-vfs2:gnome-mime-data,desktop-file-utils,cdparanoia,dbus-1,dbus-1-glib,hal,libsmbclient,fam,file_alteration +Ignore: libgda:file_alteration +Ignore: gnutls:lzo,libopencdk +Ignore: gnutls-devel:lzo-devel,libopencdk-devel +Ignore: pango:cairo,glitz,libpixman,libpng +Ignore: pango-devel:cairo-devel +Ignore: cairo-devel:libpixman-devel +Ignore: libgnomeprint:libgnomecups +Ignore: libgnomeprintui:libgnomecups +Ignore: orbit2:libidl +Ignore: orbit2-devel:libidl,libidl-devel,indent +Ignore: qt3:libmng +Ignore: qt-sql:qt_database_plugin +Ignore: gtk2:libpng,libtiff +Ignore: libgnomecanvas-devel:glib-devel +Ignore: libgnomeui:gnome-icon-theme,shared-mime-info +Ignore: scrollkeeper:docbook_4 +Ignore: gnome-desktop:libgnomesu,startup-notification +Ignore: python-devel:python-tk +Ignore: gnome-pilot:gnome-panel +Ignore: gnome-panel:control-center2 +Ignore: gnome-menus:kdebase3 +Ignore: gnome-main-menu:rug +Ignore: libbonoboui:gnome-desktop +Ignore: postfix:pcre +Ignore: docbook_4:iso_ent,xmlcharent +Ignore: control-center2:nautilus,evolution-data-server,gnome-menus,gstreamer-plugins,gstreamer,metacity,mozilla-nspr,mozilla,libxklavier,gnome-desktop,startup-notification +Ignore: docbook-xsl-stylesheets:xmlcharent +Ignore: liby2util-devel:libstdc++-devel,openssl-devel +Ignore: yast2:yast2-ncurses,yast2_theme,perl-Config-Crontab,yast2-xml,SuSEfirewall2 +Ignore: yast2-core:netcat,hwinfo,wireless-tools,sysfsutils +Ignore: yast2-core-devel:libxcrypt-devel,hwinfo-devel,blocxx-devel,sysfsutils,libstdc++-devel +Ignore: yast2-packagemanager-devel:rpm-devel,curl-devel,openssl-devel +Ignore: yast2-devtools:libxslt +Ignore: yast2-installation:yast2-update,yast2-mouse,yast2-country,yast2-bootloader,yast2-packager,yast2-network,yast2-online-update,yast2-users,release-notes,autoyast2-installation +Ignore: yast2-bootloader:bootloader-theme +Ignore: yast2-packager:yast2-x11 +Ignore: yast2-x11:sax2-libsax-perl +Ignore: yast2-network:yast2-inetd +Ignore: openslp-devel:openssl-devel +Ignore: java-1_4_2-sun:xorg-x11-libs +Ignore: java-1_4_2-sun-devel:xorg-x11-libs +Ignore: tetex:xorg-x11-libs,expat,fontconfig,freetype2,libjpeg,ghostscript-x11,xaw3d,gd,dialog,ed +Ignore: texlive-bin:ghostscript-x11 +Ignore: texlive-bin-omega:ghostscript-x11 +Ignore: yast2-country:yast2-trans-stats +Ignore: tpb:tpctl-kmp +Ignore: tpctl:tpctl-kmp +Ignore: zaptel:zaptel-kmp +Ignore: mkinitrd:pciutils + +Ignore: libgcc:glibc-32bit +Ignore: libgcc41:glibc-32bit +Ignore: libgcc42:glibc-32bit +Ignore: libgcc43:glibc-32bit +Ignore: libstdc++:glibc-32bit +Ignore: libstdc41++:glibc-32bit +Ignore: libstdc42++:glibc-32bit +Ignore: libstdc43++:glibc-32bit + +Ignore: susehelp:susehelp_lang,suse_help_viewer +Ignore: mailx:smtp_daemon +Ignore: cron:smtp_daemon +Ignore: hotplug:syslog +Ignore: pcmcia:syslog +Ignore: openct:syslog +Ignore: avalon-logkit:servlet +Ignore: jython:servlet +Ignore: ispell:ispell_dictionary,ispell_english_dictionary +Ignore: aspell:aspel_dictionary,aspell_dictionary +Ignore: smartlink-softmodem:kernel,kernel-nongpl +Ignore: OpenOffice_org-de:myspell-german-dictionary +Ignore: OpenOffice_org:OpenOffice_org-i18n +Ignore: mediawiki:php-session,php-gettext,php-zlib,php-mysql,mod_php_any +Ignore: squirrelmail:mod_php_any,php-session,php-gettext,php-iconv,php-mbstring,php-openssl + +Ignore: simias:mono(log4net) +Ignore: zmd:mono(log4net) +Ignore: horde:mod_php_any,php-gettext,php-mcrypt,php-imap,php-pear-log,php-pear,php-session,php + +Ignore: xerces-j2:xml-commons-apis,xml-commons-resolver +Ignore: xdg-menu:desktop-data +Ignore: nessus-libraries:nessus-core +Ignore: evolution:yelp + +Ignore: mono-tools:mono(gconf-sharp),mono(glade-sharp),mono(gnome-sharp),mono(gtkhtml-sharp),mono(atk-sharp),mono(gdk-sharp),mono(glib-sharp),mono(gtk-sharp),mono(pango-sharp) +Ignore: gecko-sharp2:mono(glib-sharp),mono(gtk-sharp) + +Ignore: vcdimager:libcdio.so.6,libcdio.so.6(CDIO_6),libiso9660.so.4,libiso9660.so.4(ISO9660_4) +Ignore: libcdio:libcddb.so.2 + +Ignore: gnome-libs:libgnomeui +Ignore: nautilus:gnome-themes +Ignore: gnome-panel:gnome-themes +Ignore: gnome-panel:tomboy +Ignore: NetworkManager:NetworkManager-client +Ignore: libbeagle:beagle +Ignore: glib2:glib2-lang +Ignore: gtk2:gtk2-lang +Ignore: gtk:gtk-lang +Ignore: atk:atk-lang +Ignore: hal:pm-utils +Ignore: MozillaThunderbird:pinentry-dialog +Ignore: seamonkey:pinentry-dialog + +Ignore: icecream:gcc-c++ +Ignore: no +Ignore: package +Ignore: provides + +%if 0%{?opensuse_bs} +Substitute: java2-devel-packages gcc-java java-1_4_2-gcj-compat-devel +%else + %ifnarch s390 s390x ppc ppc64 ia64 +Substitute: java2-devel-packages java-1_5_0-sun-devel unzip update-alternatives + %else + %ifarch s390 s390x ppc ppc64 +Substitute: java2-devel-packages java-1_5_0-ibm-devel unzip update-alternatives + %endif + %ifarch ia64 +Substitute: java2-devel-packages java-1_5_0-bea-devel unzip update-alternatives + %endif + %endif +%endif + +%ifarch x86_64 ppc64 s390x sparc64 +Substitute: glibc-devel-32bit glibc-devel-32bit glibc-32bit +%else + %ifarch ppc +Substitute: glibc-devel-32bit glibc-devel-64bit + %else +Substitute: glibc-devel-32bit + %endif +%endif + +%ifarch %ix86 +Substitute: kernel-binary-packages kernel-default kernel-smp kernel-bigsmp kernel-debug kernel-xen kernel-xenpae +%endif +%ifarch ia64 +Substitute: kernel-binary-packages kernel-default kernel-debug +%endif +%ifarch x86_64 +Substitute: kernel-binary-packages kernel-default kernel-smp kernel-xen +%endif +%ifarch ppc +Substitute: kernel-binary-packages kernel-default kernel-kdump kernel-ppc64 kernel-iseries64 +%endif +%ifarch ppc64 +Substitute: kernel-binary-packages kernel-ppc64 kernel-iseries64 +%endif +%ifarch s390 +Substitute: kernel-binary-packages kernel-s390 +%endif +%ifarch s390x +Substitute: kernel-binary-packages kernel-default +%endif + +%ifarch ppc64 +Substitute: mono-devel mono-devel mono-biarchcompat +Substitute: mono-basic mono-basic mono-biarchcompat +Substitute: mono-tools mono-tools mono-biarchcompat +%endif + + +Optflags: i586 -march=i586 -mtune=i686 -fmessage-length=0 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector +Optflags: i686 -march=i686 -mtune=i686 -fmessage-length=0 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector +Optflags: x86_64 -fmessage-length=0 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector +Optflags: ppc -fmessage-length=0 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector +Optflags: ppc64 -fmessage-length=0 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector + +Optflags: * -O2 + +%define suse_version 1030 + +Macros: +%insserv_prereq insserv sed +%fillup_prereq fillup coreutils +%suseconfig_fonts_prereq perl aaa_base +%install_info_prereq info +%kernel_module_package_buildreq kernel-source kernel-syms +%suse_version 1030 +%sles_version 0 +%ul_version 0 +%do_profiling 1 +%_vendor suse -- 2.7.4