On 08/17/2017 06:10 PM, Amadeus W.M. wrote: > On Thu, 17 Aug 2017 09:30:11 +0800, Ed Greshko wrote: > >> On 08/17/2017 09:22 AM, Amadeus W.M. wrote: >>> Actually I compiled, out of curiosity, the tar file that came with the >>> srpm, with >>> >>> ./configure --without-all --with-x-toolkit=no --without-x >>> >>> and worked very well. So these are valid options. Don't know why >>> rpmbuild doesn't like those. It would have been nice to have an rpm but >>> I'll take what I can. >> >> >> I don't think I was very clear..... >> >> Yes, the options are valid for "configure" and you need to pass those >> options in the rpmbuild command. >> >> BUT, the option is preceded by the options of rpmbuild and they are.... >> >> rpmbuild-options >> [--buildroot DIRECTORY] [--clean] [--nobuild] >> [--rmsource] [--rmspec] [--short-circuit] [--build-in-place] >> [--noprep] [--noclean] [--nocheck] >> [--target PLATFORM] >> [--with OPTION] [--without OPTION] >> >> >> Soo.......you probably need something like this... >> >> rpmbuild --rebuild emacs-25.2-3.fc25.src.rpm --without (a space goes >> here!!!) without-all > > > I tried rpmbuild --rebuild both --with without-all and also --without > without-all and it didn't work. I think that would be equivalent to > > ./configure --with without-all or > ./configure --without without-all > > respectively. Neither one is valid for configure. I think there's nothing > that can be done here. You have to bugger the spec file to accommodate conditionals. Using the rpmbuild ... --with fnork (note the space between "with" and "fnork) will cause an rpmbuild macro, "_with_fnork" to be created with the value "--with-fnork". To use this macro, you have to modify your spec file to something like: ./configure \ %{?_with_fnork} \ --with-somethingelse \ ... With that change in place in the spec file, had you done rpmbuild ... --with fnork then the configure would have been run as: ./configure \ --with-fnork \ --with-somethingelse \ ... And if you had NOT included "--with fnork" on the rpmbuild command: ./configure \ --with-somethingelse \ ... The construct "%{?_with_fnork}" in the spec file means "if the macro '_with_fnork' is defined (via "--with fnork" on the command line), use its value. Otherwise use null." There is a parallel using "--without fnork" (creating a "_without_fnork" macro with the value "--without-fnork"). Yes, it's a bit obtuse. For the gory details: http://rpm5.org/docs/api/conditionalbuilds.html Hope that helps. rpmbuild and spec files often make my brain bleed-- especially the "%files" section. I'm getting queasy just thinking of it! ---------------------------------------------------------------------- - Rick Stevens, Systems Engineer, AllDigital ricks@xxxxxxxxxxxxxx - - AIM/Skype: therps2 ICQ: 226437340 Yahoo: origrps2 - - - - "Microsoft is a cross between The Borg and the Ferengi. - - Unfortunately they use Borg to do their marketing and Ferengi to - - do their programming." -- Simon Slavin - ---------------------------------------------------------------------- _______________________________________________ users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx