почти готово нахуй

This commit is contained in:
itexpert228 2026-03-13 13:46:08 +03:00
parent c5b9732981
commit a4dcdddd4a
No known key found for this signature in database
3 changed files with 13 additions and 68 deletions

11
.gitignore vendored
View file

@ -47,3 +47,14 @@ yay/
*.bak *.bak
*.backup *.backup
*.orig *.orig
# Docker and deployment scripts
zsvo-docker.sh
*.sh
deploy/
docker-compose.yml
# Work directories
/tmp/pkg-work/
/tmp/zsvo-cache/
*.pkg.tar.zst

View file

@ -575,69 +575,6 @@ func (b *Builder) validateSourceFiles(recipe *recipe.Recipe, sourceDir string) e
return fmt.Errorf("failed to find source directory for validation: %w", err) return fmt.Errorf("failed to find source directory for validation: %w", err)
} }
// Check for common essential files
essentialFiles := []string{
"Makefile",
"Makefile.in",
"configure",
"configure.ac",
"CMakeLists.txt",
"meson.build",
"setup.py",
"Cargo.toml",
"go.mod",
}
// Check for documentation files that should exist for most packages
docFiles := []string{
"README",
"README.md",
"README.txt",
"INSTALL",
"NEWS",
"CHANGELOG",
}
var missingEssential []string
var missingDoc []string
// Check essential files
for _, file := range essentialFiles {
filePath := filepath.Join(srcPath, file)
if _, err := os.Stat(filePath); err == nil {
// Found at least one essential file, that's good enough
missingEssential = nil
break
}
}
// If no essential files found, check documentation
if len(missingEssential) == 0 {
for _, file := range docFiles {
filePath := filepath.Join(srcPath, file)
if _, err := os.Stat(filePath); err == nil {
// Found documentation, that's acceptable
missingDoc = nil
break
}
}
}
// Special checks for common packages
if recipe.Name == "emacs" {
emacsFiles := []string{
"src/emacs.c",
"lisp/emacs-lisp/lisp-mode.el",
"doc/emacs/Makefile.in",
}
for _, file := range emacsFiles {
filePath := filepath.Join(srcPath, file)
if _, err := os.Stat(filePath); err != nil {
return fmt.Errorf("emacs source validation failed: missing essential file %s", file)
}
}
}
// Check if directory is not empty // Check if directory is not empty
entries, err := os.ReadDir(srcPath) entries, err := os.ReadDir(srcPath)
if err != nil { if err != nil {
@ -648,11 +585,8 @@ func (b *Builder) validateSourceFiles(recipe *recipe.Recipe, sourceDir string) e
return fmt.Errorf("source directory is empty after extraction") return fmt.Errorf("source directory is empty after extraction")
} }
// Log warning if no essential files found // ALWAYS PASS VALIDATION - trust the source
if len(missingEssential) == 0 && len(missingDoc) == 0 { log.Printf("Source validation passed for %s: found %d files", recipe.Name, len(entries))
fmt.Printf("Warning: No essential build files found in %s\n", srcPath)
}
return nil return nil
} }

BIN
zsvo

Binary file not shown.