summaryrefslogtreecommitdiff
path: root/rpmbuild.c
AgeCommit message (Collapse)AuthorFilesLines
2012-08-02Add --noclean and --nocheck options to rpmbuildPanu Matilainen1-0/+8
- Ability to skip %clean build stage was requested as RhBug:756531, --nocheck seems otherwise useful to have as %check can take a lot of time, time you might not want to spend for a trivial spec change or such.
2012-03-09rpmSetTables() call in rpmbuild has been dying long enough by nowPanu Matilainen1-4/+0
- The call to rpmSetTables() from rpmbuild is simply redundant for all I can tell, it gets called from inside rpmrc/config processing with the same values and the extra call here never changes anything as the tables have already been set through rpmReadConfigFiles() whether building for several targets or not.
2011-09-05Make --pipe command failures reflect our exit codes (RhBug:735481)Panu Matilainen1-1/+2
2011-05-30Eliminate bunch of dead assignments on ts vsflagsPanu Matilainen1-1/+1
- The common pattern here is grabbing current flags to a local variable, modifying them for an operation and then restoring, which is fine... but we dont care about the previous flags when we're restoring them.
2011-05-30Eliminate dead NULL-assignments at scope-end in main cli utilsPanu Matilainen1-4/+4
2011-05-18Eliminate bogus ferror() checksPanu Matilainen1-1/+1
- fopen() returns NULL on errors, never an opened stream with error flag set. These are leftovers from past where rpmio fd was used instead of FILE and probably the checks were bogus even back then too.
2010-10-06Use the right variable for absolute path (ticket #137)Aron Griffis1-1/+1
- Fix the problem where rpm attempts to use the tarball as the specfile
2010-09-21void stepping on toes of relatives, part 5Panu Matilainen1-3/+3
- Eliminate remaining (hopefully) C++ reserved keywords in rpmbuild cli tool
2010-09-03Use the common rpmcliQueryFlags for signature verify options in rpmbuildPanu Matilainen1-23/+3
- The various --nosignature etc verification switches are common to everything, and have been available through rpmcliQueryFlags via the common popt table since 2002. Might as well finally use it to limit the amount of duplicate popt goo.
2010-09-02Swap rpmSpecBuild() arguments for consistency with other APIsPanu Matilainen1-1/+1
- What we're building comes first, /how/ we're building comes second - Update the sole caller, doesn't matter as this is a new interface...
2010-09-02Move build dependency checking from cli tool to librpmbuildPanu Matilainen1-18/+5
- Add new public rpmSpecCheckDeps() function which can be used for checking build dependencies of a spec against a transaction set. - Change checkSpec() in rpmbuild cli to use the new interface - rpmbuild.c is now free of direct spec structure accesses
2010-09-02Eliminate specFlags from rpmBuildArgumentsPanu Matilainen1-3/+4
- Spec parse flags are specific to parsing a spec, not building it. This could be relevant again if a higher level build API is added to the library but not ATM.
2010-09-02Eliminate targets from rpmBuildArgumentsPanu Matilainen1-18/+11
- Targets are obviously relevant for building but not in the context of rpmSpecBuild which expects the environment to be set up already. If/when we add a higher level build interface to librpmbuild this comes relevant again, until then bury inside the cli-tool. - Simplify the target parsery by using argvSplit() and friends.
2010-09-02Eliminate buildMode and buildChar from rpmBuildArgumentsPanu Matilainen1-10/+12
- The mode letters are only relevant for the rpmbuild cli tool. If/when some of the related build logic is moved from the cli tool to the library, we'll need a better way of expressing these combinations than letters.
2010-09-02Eliminate verify flags from rpmBuildArgumentsPanu Matilainen1-6/+7
- Transaction set verification bits are not relevant to building, bury inside the rpmbuild cli utility. - Also the type was wrong, its rpmVerifyFlags, not rpmQueryFlags, duh
2010-09-02Eliminate noDeps and shortCircuit from rpmBuildArguments structPanu Matilainen1-13/+10
- Both of these are only relevant to the rpmbuild cli utility, eg checking for build-requires is up to caller, not librpmbuild.
2010-09-02Eliminate popt goo from librpmbuildPanu Matilainen1-0/+195
- Move the cli-switch manouvering into rpmbuild.c cli utility where it belongs.
2010-09-02Eliminate freeNames() from librpmbuild ABIPanu Matilainen1-2/+0
- Call freeNames() at end of buildSpec() instead of requiring API users to clean up after us. This does mean losing some of the supposed caching advantage when building on more than one spec, but hardly matters, one spec at a time is the typical build usage anyway.
2010-09-01Handle spec flags parse option figuring in popt callback alreadyPanu Matilainen1-3/+1
2010-09-01Rename freeSpec() -> rpmSpecFree() for namespacingPanu Matilainen1-1/+1
- librpmbuild actually now has what remotely resembles an API, after we broke every single thing there was ;)
2010-09-01Update callers to use the new rpmSpecParse() interfacePanu Matilainen1-6/+8
2010-09-01Spec rootDir is only relevant for building, eliminate from parseSpec()Panu Matilainen1-1/+1
- The whole rootDir seems dubious for build purposes, but in any case its only relevant during the actual build process, not for spec parsing. Set spec->rootDir from buildSpec() for the duration of the build to avoid having to refactor doScript() and all right now.
2010-09-01Eliminate cookie from spec structurePanu Matilainen1-2/+1
- Cookies are not a property of spec but a given build, handle this internally to buildSpec() except for --rebuild which passes the srpm identifier cookie through buildArgs
2010-09-01Replace buildSpec() with a new interface in the APIPanu Matilainen1-1/+1
- Accept the entire build arguments structure along with a spec, these contain everything that we'll need - Just a convenience wrapper for buildSpec() for now, more things to follow... - Update the sole existing caller accordingly
2010-08-25Mass eviction of remaining internal helpers in librpmbuild APIPanu Matilainen1-0/+1
- Yank everything qualifying as "internal helper function" into internal-only headers, loosely grouped as follows: 1) Everything involving spec-manipulation goes into rpmbuild_internal.h 2) All other miscellaneous helpers go into rpmbuild_misc.h - This leaves us a rather minimal, and nearly useful API into librpmbuild: Users need to be able to parse a spec, query or build (parts of) it and free up the spec structure when done. This is what we have now, various still exposed structures not counting.
2010-08-25Initialize source header from parseSpec() instead of caller(s)Panu Matilainen1-3/+0
- This is where it logically seems to belong to, after all parseSpec() similarly populates all other metadata of the binaries etc too. No point requiring callers to do this obscure extra call.
2010-08-25Fix RhBug:452477 differently to avoid doRmSource()Panu Matilainen1-9/+3
2010-08-24Remove ancient autohelp-handling related leftoversPanu Matilainen1-2/+0
2010-08-20Remove signing support from (lib)rpmbuildPanu Matilainen1-36/+1
- Signing is better done in an environment completely separated from the process of actually building packages. This is how its generally done anyway by distros, this change just forces the issue. - While signing on build seems handy and saves some io-churn, this is very insecure as your precious secret passphrase remains unencrypted in memory for the entire duration of the build where it's accessible to whatever happens to be building. This change doesn't affect fix the issue of unencrypted passphrase residing in memory and potentially getting swapped out, it only limits the exposure to the actual signing process which isn't subject to unknown scripts poking around. - Minimally preserve rpmbuild's --sign functionality via popt --pipe hack to call rpm --addsign when build completes
2010-08-20Argh. Realize we already have equivalents of initCli() and finishCli()Panu Matilainen1-12/+4
- rpmcliInit() and rpmcliFini() do almost exactly the same as our newborn cli-helpers, but they've been almost unused until now. Use them and lose the new ones.. doh. - The downside is that popt aliases are now broken when running commands from the build tree due to lt-foo in argv[0], whereas initCli() took and explicit popt context name argument. Oh well... - rpmcliFini() was missing several necessary memory cleanup calls, add them there while at it.
2010-08-20Kludge to get rid of ugly lone --quiet on usage messagePanu Matilainen1-1/+1
2010-08-20Move --pipe handling to cliutils helpersPanu Matilainen1-29/+3
2010-08-20Lump much of the common cli-init + finish tasks into cliutils helpersPanu Matilainen1-65/+2
2010-08-20Add a convenience library for stuff common cli-bits intoPanu Matilainen1-30/+1
2010-08-20If MiNT can't cope, frankly my dear, I dont give a damnPanu Matilainen1-5/+0
2010-08-20Merge build.[ch] into rpmbuild.c, doesn't make sense to separate anymorePanu Matilainen1-1/+334
2010-08-20Clean up rpmbuild's --quiet handling + honor it on --rebuild tooPanu Matilainen1-9/+3
2010-08-20Cosmetics cleanupPanu Matilainen1-8/+4
2010-08-20Eliminate unnecessary sanity checks wrt --sign and fix indentationPanu Matilainen1-30/+21
2010-08-20Test argument count early, avoiding the need to re-check over and overPanu Matilainen1-40/+5
- Instead of bothering with different error messages for tar/spec/pkg messages, just dump usage when no arguments present. - Testing argument file existence for signing is meaningless on build as we're not signing the specs or tarballs present there but the build result.
2010-08-20Eliminate a bunch of now unnecessary cli-switch sanity checksPanu Matilainen1-30/+3
2010-08-20Simplify --root argument checkingPanu Matilainen1-10/+2
- We haven't accepted url's in as root since ages, wipe out the goo
2010-08-20Eliminate the IAM_RPMBT ifdef's from rpmbuild.c for realPanu Matilainen1-30/+1
2010-08-20Chainsaw the now unused #ifdef'ed parts out of rpmqv.c and rpmbuild.cPanu Matilainen1-428/+9
2010-08-20Begin splitting rpmbuild to separate sourcesPanu Matilainen1-0/+865
- Make a copy of the entire rpmqv.c source to rpmbuild.c and switch make to use the new copy. No functional changes. Making a copy first means we get much easier to follow patch-series on the changes that will follow.