Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2023-02-08 00:49:38 +0300
committerCorinna Vinschen <corinna@vinschen.de>2023-02-08 00:49:38 +0300
commit627c0f2b6715f37663ccd0c6c7f87b2f0ba0dc8f (patch)
tree5ae557cbe06c3fd9c14348d593e4459a91555ed1 /winsup/utils
parent013ccc0686131aa835f1364ea7ca9d07066e03e6 (diff)
Cygwin: cygcheck: collect build-depends info
TODO: implement options to print all deps, all build-deps, all packages depending on packages matching the search string and so on. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diffstat (limited to 'winsup/utils')
-rw-r--r--winsup/utils/mingw/cygcheck.cc12
1 files changed, 12 insertions, 0 deletions
diff --git a/winsup/utils/mingw/cygcheck.cc b/winsup/utils/mingw/cygcheck.cc
index 1ed4fdc6f..ac8343e66 100644
--- a/winsup/utils/mingw/cygcheck.cc
+++ b/winsup/utils/mingw/cygcheck.cc
@@ -2237,6 +2237,7 @@ struct vers_info
char *install;
char *source;
char *depends2;
+ char *build_depends;
time_t install_date;
bool matches;
bool installed;
@@ -2270,6 +2271,7 @@ free_pkg_info (ini_package_info *pi)
free (pi->curr.install);
free (pi->curr.source);
free (pi->curr.depends2);
+ free (pi->curr.build_depends);
if (pi->prev)
{
for (size_t i = 0; i < pi->prev_count; ++i)
@@ -2278,6 +2280,7 @@ free_pkg_info (ini_package_info *pi)
free (pi->prev[i].install);
free (pi->prev[i].source);
free (pi->prev[i].depends2);
+ free (pi->prev[i].build_depends);
}
free (pi->prev);
}
@@ -2289,6 +2292,7 @@ free_pkg_info (ini_package_info *pi)
free (pi->test[i].install);
free (pi->test[i].source);
free (pi->test[i].depends2);
+ free (pi->test[i].build_depends);
}
free (pi->test);
}
@@ -2410,6 +2414,8 @@ collect_pkg_info (FILE *fp, ini_package_info *pi)
vinfo->source = strdup (buf + strlen ("source: "));
else if (!strncmp (buf, "depends2: ", strlen ("depends2: ")))
vinfo->depends2 = strdup (buf + strlen ("depends2: "));
+ else if (!strncmp (buf, "build-depends: ", strlen ("build-depends: ")))
+ vinfo->build_depends = strdup (buf + strlen ("build-depends: "));
}
}
return pi;
@@ -2503,6 +2509,12 @@ package_info_print (ini_package_info *pi, vers_info *vers)
printf ("Source : %s\n", cp + 1);
}
}
+#if 0 /* FIXME: needs CLI options */
+ if (vers->depends2)
+ printf ("Dependencies: %s\n", vers->depends2);
+ if (vers->build_depends)
+ printf ("Build Deps : %s\n", vers->build_depends);
+#endif
if (pi->sdesc)
printf ("Summary : %s\n", pi->sdesc);
if (pi->url)