diff --git a/recipes/libs/ncursesw/recipe.toml b/recipes/libs/ncursesw/recipe.toml index 7b138a00c9..d182dbdb5d 100644 --- a/recipes/libs/ncursesw/recipe.toml +++ b/recipes/libs/ncursesw/recipe.toml @@ -11,24 +11,18 @@ script = """ DYNAMIC_INIT COOKBOOK_CONFIGURE_FLAGS+=( --disable-db-install + --disable-ext-colors --disable-stripping - --disable-widec - --enable-pc-files + --enable-widec --without-ada --without-manpages --without-tests + --enable-pc-files --with-terminfo-dirs=/usr/share/terminfo --with-pkg-config-libdir=/usr/lib/pkgconfig cf_cv_func_mkstemp=yes + cf_cv_wint_t=yes ) -if [ "${COOKBOOK_DYNAMIC}" == "1" ] -then - COOKBOOK_CONFIGURE_FLAGS+=(--with-shared) -fi cookbook_configure """ -[package] -dependencies = [ - "terminfo", -] diff --git a/src/recipe.rs b/src/recipe.rs index 4c85860e5a..6932c51686 100644 --- a/src/recipe.rs +++ b/src/recipe.rs @@ -513,7 +513,20 @@ impl CookRecipe { } } SourceRecipe::SameAs { same_as } => { - dir = self.dir.join(same_as); + let same_as_dir = self.dir.join(same_as); + let target_recipe = same_as_dir.join("recipe.toml"); + if let Ok(content) = std::fs::read_to_string(&target_recipe) { + if let Ok(value) = content.parse::() { + if let Some(pkg) = value.get("package") { + if let Some(v) = pkg.get("version").and_then(|x| x.as_str()) { + if !v.is_empty() { + return Some(v.to_string()); + } + } + } + } + } + dir = same_as_dir; } _ => {} }