Commit Graph

37 Commits

Author SHA1 Message Date
Panu Matilainen 38932d1d17 Export our own version of glob_pattern_p() as rpmIsGlob()
- Further preliminaries to hiding the glob() implementation
2012-05-31 16:45:32 +03:00
Christophe Fergeau 185596818f Add support for 7zip compressed tarballs
Teach %prep and %uncompress how to handle 7zip tarballs, with
the mingw toolchain landing in fedora, this may be useful when
crossbuilding Windows sources compressed using 7zip (CxImage is
one such project).
2012-05-22 13:48:01 +03:00
Ville Skyttä e254f9b9d4 Add lrzip support.
Signed-off-by: Panu Matilainen <pmatilai@redhat.com>
2011-04-29 08:49:05 +03:00
Ville Skyttä bcad08867d Add lzip support.
Signed-off-by: Panu Matilainen <pmatilai@redhat.com>
2011-04-29 08:48:56 +03:00
Panu Matilainen e104b67237 Eliminate use of pgpHashAlgo in rpmio interface arguments
- While its use would seem kinda obvious here, in rpm context this
  information often comes from header tags which are plain integers
  and would require conversion/casting to the enum. What matters is
  the integral value, not it being actual enum.
2010-10-22 12:22:44 +03:00
Panu Matilainen 8078d0ba24 LZMA -> XZ renaming
- what we support now in payloads is XZ, not the former LZMA format, rename
  user- and header-visible parts to match this
- rpmlib(PayloadIsXz) dependency versioned 5.2-1 to avoid unnecessary
  incompatibility with what rpm5 has and what Mandriva is already using
- only provide the rpmlib dependency if actually built with xz support
- rpmFileIsCompressed() attempts to guess the magicless old lzma format
  by file suffix, so it can handle both right now
2009-03-18 09:42:23 +02:00
Jindrich Novy 7acdfded4a Add md5->filedigest aliases (rhbz#487597)
- add %verify(nofiledigest) as %verify(nomd5) file attribute alias
- reference digests as digests not checksums
- make old md5 related symbols obsolete and use newer reference
- update man page accordingly
2009-02-27 14:34:39 +01:00
Panu Matilainen bafed0d85c Oops, missing wrappers for C++ in headers (ticket #12) 2008-12-09 09:51:17 +02:00
Panu Matilainen 9799e69263 Avoid "template" which is a reserved word in C++ 2008-12-05 21:17:16 +02:00
Panu Matilainen a7ece3bc4a Add rpmMkdirs() to librpmio
- allows creating bunch of directories including parents at once
2008-10-10 14:28:41 +03:00
Panu Matilainen 55d3bbd4b8 Enable rpmDoDigest() to pass large file sizes
- should probably be off_t instead of rpm_loff_t as this is lowlevel io
  business and only verification code cares about the size reported by
  it, otoh forcing 64bit always avoids having to deal with variable
  off_t type on printing.. shrug
2008-06-11 09:25:02 +03:00
Panu Matilainen 6962b29bd9 Remove bogus comment on rpmDoDigest() ignoring algorithm 2008-06-02 13:05:46 +03:00
Panu Matilainen 0ee67fede8 Temp file handling tweaks
- rename rpmMkTemp() (back) to rpmMkTempFile()
- rpmMkTemp() is now a lower level thin wrapper around mkstemp()
2008-05-03 12:34:19 +03:00
Panu Matilainen 1b972af8a6 Change rpmGlob() argvPtr type to ARGV_t to make it obvious what it is
- also fix incorrect doxygen commentary, it wasn't a contiguous blob
  before either
2008-04-19 16:58:55 +03:00
Panu Matilainen 3ffbbeba19 Doxygen parameter name mismatch 2008-04-15 18:52:42 +03:00
Panu Matilainen fde961e25b Rewrite rpmMkTempFile() for sanity
- Actually use mkstemp() for creating the temp file and return a FD_t
  dupped from the file descriptor returned by mkstemp().
- Simplify the interface while at it.
- Change callers for the new interface.
- Yes we now require mkstemp() to work, mkstemp() is in POSIX.1-2001 and
  this is year 2008...
2008-04-11 09:05:05 +03:00
Panu Matilainen a5a3cfc3ed Rename currentDirectory() to rpmGetCwd() and move to librpmio 2008-04-04 09:53:17 +03:00
Panu Matilainen 2b39ddc25d Enable variadic checks for rpmExpand(), rpmlog() and rpmGetPath()
Suggested by Michal Marek
2008-02-25 11:03:38 +02:00
Panu Matilainen e886043a10 Add rpm_off_t type for file size types, use where spotted
- preliminaries for bumping up the max size, use rpm-specific type
  as off_t size varies, header data needs fixed size
2008-02-04 11:27:00 +02:00
Panu Matilainen 95b03441cc Rename isCompressed() -> rpmFileIsCompressed() for namespacing 2008-01-27 16:39:40 +02:00
Panu Matilainen 8e2965886f Couple of missing doxygen groupings 2008-01-27 16:13:47 +02:00
Panu Matilainen f0f392cce6 Helper function for checking given suffix on path 2008-01-27 16:00:06 +02:00
Panu Matilainen a97100ba1d Handle spaces in file path arguments correctly (#217258)
Ported from rpm5.org work of Jeff Johnson with some differences:
- place into rpmfileutil instead of rpmgi as it's more generic than just rpmgi
- rename rpmgiEscapeSpaces -> rpmEscapeSpaces
- return char *, not const char * as the return string must be freed by caller
2008-01-09 10:21:01 +02:00
Panu Matilainen 78ad426f04 Remove bogus const from rpmGlob argv return type
- it's malloced and must be freed by caller
2007-12-18 10:17:18 +02:00
Panu Matilainen 14284725e6 Remove const from rpmMkTempFile file name parameter
- the temp name is malloced and needs to be freed by caller
2007-12-16 16:25:09 +02:00
Panu Matilainen 3b6a6c9030 Fix incorrect rpmCleanPath() retval comment 2007-12-15 17:08:18 +02:00
Panu Matilainen dce66192f2 Remove bogus const from rpmGenPath and rpmGetPath return type
- both return malloced strings you're supposed to free
2007-12-15 09:39:32 +02:00
Panu Matilainen 9ce13e09ef Switch to <rpm/foo.h> style for public headers
- adjust include paths accordingly
2007-12-08 14:02:32 +02:00
Panu Matilainen 89ecfb96d0 Include sanity
- don't pull in rpmio into rpmpgp.h
- make rpmpgp.h standalone (needs rpmints and stdio)
- rpmfileutil needs rpmio (makes sense, huh...)
2007-12-01 12:47:30 +02:00
Panu Matilainen 31ad46a64b Add doxygen group for rpmfileutil, include in librpm + hacking docs 2007-11-23 15:11:21 +02:00
Panu Matilainen 7b2a9b3c24 Move rpmGlob() from macros to rpmfileutil.h
- macros is all just macros now
- internal copy of popt stuff needs to go...
2007-11-23 10:27:29 +02:00
Panu Matilainen 2c6905dd9f Move rpmGetPath and rpmGenPath to rpmfileutil.h 2007-11-23 10:20:19 +02:00
Panu Matilainen 178e32a0ba Move rpmCleanPath from macros to rpmfileutil.h 2007-11-23 10:10:19 +02:00
Panu Matilainen ff77bfa2a1 Move file compression stuff from rpmmacro.h to rpmfileutil.h 2007-11-23 10:05:49 +02:00
Panu Matilainen c1bcd63301 Move rpmioMkpath from rpmio.h to rpmfileutil.h 2007-11-23 09:58:02 +02:00
Panu Matilainen d10acc7c2a Move makeTempFile() from misc.h to rpmfileutil.h
- probably not very useful outside rpm but used all over the tree,
- rename to rpmMkTempFile() for namespacing since we're exporting it now
2007-11-22 16:28:30 +02:00
Panu Matilainen e063854e11 Calculating file checksums aint legacy activity
- move the checksumming into librpmio
- rename domd5() to rpmDoDigest() with future expansion for specifying
  digest algorithm type (ignored for now)
- rearrange parameters to leave return types last
- one less rpmio_internal outside rpmio/, whee...
- used all over the rpm tree, and it knows about handling prelinked files
  so potentially useful for outside users, might as well export it
- new public header rpmfilutil.h for collecting this sort of stuff
2007-11-22 16:06:11 +02:00