|
Panu Matilainen |
c66608 |
diff -up rpm-4.6.0-rc4/build/rpmfc.c.extra-prov rpm-4.6.0-rc4/build/rpmfc.c
|
|
Panu Matilainen |
c66608 |
--- rpm-4.6.0-rc4/build/rpmfc.c.extra-prov 2009-02-04 15:18:05.000000000 +0200
|
|
Panu Matilainen |
c66608 |
+++ rpm-4.6.0-rc4/build/rpmfc.c 2009-02-04 15:20:46.000000000 +0200
|
|
Panu Matilainen |
c66608 |
@@ -485,6 +485,7 @@ static const struct rpmfcTokens_s const
|
|
Panu Matilainen |
c66608 |
{ "RPM v4", RPMFC_ARCHIVE|RPMFC_INCLUDE },
|
|
Panu Matilainen |
c66608 |
|
|
Panu Matilainen |
c66608 |
{ " image", RPMFC_IMAGE|RPMFC_INCLUDE },
|
|
Panu Matilainen |
c66608 |
+ { " font metrics", RPMFC_WHITE|RPMFC_INCLUDE },
|
|
Panu Matilainen |
c66608 |
{ " font", RPMFC_FONT|RPMFC_INCLUDE },
|
|
Panu Matilainen |
c66608 |
{ " Font", RPMFC_FONT|RPMFC_INCLUDE },
|
|
Panu Matilainen |
c66608 |
|
|
Panu Matilainen |
c66608 |
@@ -1189,6 +1190,31 @@ exit:
|
|
Panu Matilainen |
c66608 |
#endif
|
|
Panu Matilainen |
c66608 |
}
|
|
Panu Matilainen |
c66608 |
|
|
Panu Matilainen |
c66608 |
+static int rpmfcMISC(rpmfc fc)
|
|
Panu Matilainen |
c66608 |
+{
|
|
Panu Matilainen |
c66608 |
+ struct stat st;
|
|
Panu Matilainen |
c66608 |
+ int rc = -1;
|
|
Panu Matilainen |
c66608 |
+ const char *what = NULL;
|
|
Panu Matilainen |
c66608 |
+ const char * fn = fc->fn[fc->ix];
|
|
Panu Matilainen |
c66608 |
+ /* this part is enumerated, compare equality not bit flags */
|
|
Panu Matilainen |
c66608 |
+ int ftype = fc->fcolor->vals[fc->ix] & 0x000F0000;
|
|
Panu Matilainen |
c66608 |
+
|
|
Panu Matilainen |
c66608 |
+ if (ftype == RPMFC_FONT) {
|
|
Panu Matilainen |
c66608 |
+ what = "fontconfig";
|
|
Panu Matilainen |
c66608 |
+ } else if (ftype == RPMFC_TEXT && rpmFileHasSuffix(fn, ".desktop")) {
|
|
Panu Matilainen |
c66608 |
+ what = "desktop";
|
|
Panu Matilainen |
c66608 |
+ }
|
|
Panu Matilainen |
c66608 |
+
|
|
Panu Matilainen |
c66608 |
+ if (what == NULL || stat(fn, &st) < 0 || !S_ISREG(st.st_mode)) {
|
|
Panu Matilainen |
c66608 |
+ goto exit;
|
|
Panu Matilainen |
c66608 |
+ }
|
|
Panu Matilainen |
c66608 |
+
|
|
Panu Matilainen |
c66608 |
+ (void) rpmfcHelper(fc, 'P', what);
|
|
Panu Matilainen |
c66608 |
+ rc = 0;
|
|
Panu Matilainen |
c66608 |
+
|
|
Panu Matilainen |
c66608 |
+exit:
|
|
Panu Matilainen |
c66608 |
+ return rc;
|
|
Panu Matilainen |
c66608 |
+}
|
|
Panu Matilainen |
c66608 |
typedef const struct rpmfcApplyTbl_s {
|
|
Panu Matilainen |
c66608 |
int (*func) (rpmfc fc);
|
|
Panu Matilainen |
c66608 |
int colormask;
|
|
Panu Matilainen |
c66608 |
@@ -1198,12 +1224,11 @@ typedef const struct rpmfcApplyTbl_s {
|
|
Panu Matilainen |
c66608 |
*/
|
|
Panu Matilainen |
c66608 |
static const struct rpmfcApplyTbl_s const rpmfcApplyTable[] = {
|
|
Panu Matilainen |
c66608 |
{ rpmfcELF, RPMFC_ELF },
|
|
Panu Matilainen |
c66608 |
- { rpmfcSCRIPT, (RPMFC_SCRIPT|RPMFC_PERL) },
|
|
Panu Matilainen |
c66608 |
- { rpmfcSCRIPT, (RPMFC_SCRIPT|RPMFC_PYTHON) },
|
|
Panu Matilainen |
c66608 |
- { rpmfcSCRIPT, (RPMFC_SCRIPT|RPMFC_PKGCONFIG) },
|
|
Panu Matilainen |
c66608 |
- { rpmfcSCRIPT, (RPMFC_SCRIPT|RPMFC_LIBTOOL) },
|
|
Panu Matilainen |
c66608 |
- { rpmfcSCRIPT, RPMFC_MONO },
|
|
Panu Matilainen |
c66608 |
- { rpmfcSYMLINK, RPMFC_SYMLINK },
|
|
Panu Matilainen |
c66608 |
+ { rpmfcSCRIPT, (RPMFC_SCRIPT|RPMFC_BOURNE|
|
|
Panu Matilainen |
c66608 |
+ RPMFC_PERL|RPMFC_PYTHON|RPMFC_MONO|
|
|
Panu Matilainen |
c66608 |
+ RPMFC_PKGCONFIG|RPMFC_LIBTOOL) },
|
|
Panu Matilainen |
c66608 |
+ { rpmfcMISC, RPMFC_FONT|RPMFC_TEXT },
|
|
Panu Matilainen |
c66608 |
+ { rpmfcSYMLINK, RPMFC_SYMLINK },
|
|
Panu Matilainen |
c66608 |
{ NULL, 0 }
|
|
Panu Matilainen |
c66608 |
};
|
|
Panu Matilainen |
c66608 |
|
|
Panu Matilainen |
c66608 |
@@ -1322,7 +1347,7 @@ rpmRC rpmfcClassify(rpmfc fc, ARGV_t arg
|
|
Panu Matilainen |
c66608 |
size_t slen;
|
|
Panu Matilainen |
c66608 |
int fcolor;
|
|
Panu Matilainen |
c66608 |
int xx;
|
|
Panu Matilainen |
c66608 |
- int msflags = MAGIC_CHECK; /* XXX MAGIC_COMPRESS flag? */
|
|
Panu Matilainen |
c66608 |
+ int msflags = MAGIC_CHECK | MAGIC_COMPRESS;
|
|
Panu Matilainen |
c66608 |
magic_t ms = NULL;
|
|
Panu Matilainen |
c66608 |
|
|
Panu Matilainen |
c66608 |
if (fc == NULL || argv == NULL)
|
|
Panu Matilainen |
c66608 |
diff -up rpm-4.6.0-rc4/macros.in.extra-prov rpm-4.6.0-rc4/macros.in
|
|
Panu Matilainen |
c66608 |
--- rpm-4.6.0-rc4/macros.in.extra-prov 2009-02-04 15:18:05.000000000 +0200
|
|
Panu Matilainen |
c66608 |
+++ rpm-4.6.0-rc4/macros.in 2009-02-04 15:18:05.000000000 +0200
|
|
Panu Matilainen |
c66608 |
@@ -463,6 +463,9 @@ print (t)\
|
|
Panu Matilainen |
c66608 |
%__pkgconfig_provides @RPMCONFIGDIR@/pkgconfigdeps.sh --provides
|
|
Panu Matilainen |
c66608 |
%__pkgconfig_requires @RPMCONFIGDIR@/pkgconfigdeps.sh --requires
|
|
Panu Matilainen |
c66608 |
|
|
Panu Matilainen |
c66608 |
+#%__fontconfig_provides /usr/lib/rpm/fontconfig.prov
|
|
Panu Matilainen |
c66608 |
+%__desktop_provides /usr/lib/rpm/desktop-file.prov
|
|
Panu Matilainen |
c66608 |
+
|
|
Panu Matilainen |
c66608 |
#==============================================================================
|
|
Panu Matilainen |
c66608 |
# ---- Database configuration macros.
|
|
Panu Matilainen |
c66608 |
# Macros used to configure Berkley db parameters.
|