Commit Graph

104 Commits

Author SHA1 Message Date
Maximilian Downey Twiss
33901368d7 Enable more rubocop cops (#9980)
* Remove self.check in python3.rb as tests were not actuallly being run

* Enable Lint/ImplicitStringConcatenation cop

* Enable Layout/CommentIndentation cop

* Remove unnecessary configuration of Layout/IndentationStyle to EnforcedStyle: spaces, as this is already the default

* Enable Layout/LeadingCommentSpace cop

* Enable Layout/SpaceInsideBlockBraces cop

* Enable Layout/SpaceInsideParens cop

* Enable Layout/TrailingEmptyLines cop

* Enable Lint/LiteralAsCondition cop

* Document the current issue stopping us from enabling Style/OptionalBooleanParameter

* Stop downloading our rubocop config when installing ruby_rubocop
2024-06-17 16:19:11 -04:00
Maximilian Downey Twiss
48e3bd316e Rework load_package, set_package, search and copy_package (#9658) 2024-04-20 19:09:30 -05:00
Maximilian Downey Twiss
8b19dcd05a Add lib/package_utils.rb to provide a number of package convenience functions. (#9617) 2024-04-10 13:00:04 -05:00
Ed Reel
1dd4b99f0a Simplify crew prop command (#9519) 2024-03-22 14:12:25 -04:00
Satadru Pramanik, DO, MPH, MEng
a39ec41c3f Set default 'binary_compression' to 'tar.zst', allow verbose option for all crew commands. (#9505)
* Set default 'binary_compression' to 'tar.zst'

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* shellcheck!

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Add verbose option to all crew commands, use workaround for package logic

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* lint

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

---------

Signed-off-by: Satadru Pramanik <satadru@gmail.com>
2024-03-20 12:33:09 -05:00
Ed Reel
7c17beeee7 Add check command (#9501) 2024-03-20 08:46:01 -04:00
Satadru Pramanik, DO, MPH, MEng
a7292dd91c Add no_source_build property (#9444)
* Add no_source_build functionality

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Add to help.rb

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

---------

Signed-off-by: Satadru Pramanik <satadru@gmail.com>
2024-03-06 21:04:32 -06:00
Maximilian Downey Twiss
eddca7e0e8 Enable additional temporarily disabled cops (#9394) 2024-03-01 12:24:31 -05:00
Satadru Pramanik, DO, MPH, MEng
61b9796ce4 valgrind => 3.22 (#9336)
Signed-off-by: Satadru Pramanik <satadru@gmail.com>
2024-02-14 12:46:51 -06:00
Satadru Pramanik, DO, MPH, MEng
ac52769bad Revert "Miscellaneous crew changes (#9311)" (#9315)
This reverts commit 7a5eff8945.
2024-02-12 12:31:07 -06:00
Maximilian Downey Twiss
7a5eff8945 Miscellaneous crew changes (#9311)
* Make greater use of File.join when loading device.json

* Remove redundant check that the compatibility property exists (already checked by prop_test as part of CI)

* Don't pass architecture to lib/package.rb

* Replace @device[:architecture] with ARCH, do not create architecture section in device.json

* Refactor getting urls and sha256s in package.rb

* Use inplace sort on installed_packages instead of creating sorted_installed_packages

* Rework load_package to always only take one argument

* Only rescue package loading errors in set_package

* Remove generate_compatible

* Replace all calls to load_package with set_package

* Use _args instead of _ in prop_command

* Merge @short_verbose and @verbose

* Simplify filename detection in download

* Bump crew version
2024-02-12 12:38:18 -05:00
Maximilian Downey Twiss
f6dc1d8d4e Derive binary_url in package.rb (#7082)
* Add binary_compression value to each package

* Remove binary_url values and arrays

* Handle packages with empty binary_sha256 arrays (either missing binaries or not compiled by us)
2024-01-25 11:03:31 -05:00
Ed Reel
abcd5618d3 Add min_glibc property and include in applicable packages (#9096) 2023-12-16 11:51:54 -05:00
Maximilian Downey Twiss
d105a9c058 Run Rubocop 1.58 on tree (#9041) 2023-12-03 19:35:18 -05:00
Maximilian Downey Twiss
86a7814bda Convert workflows to use reviewdog, run rubocop on tree (#8939) 2023-11-13 02:46:43 -05:00
SupeChicken666
9f77502974 Reimplementing #8890 (lib/const: Simplify + cleanup) (#8901)
* lib/const: Simplify + cleanup

* Fix nil issue

* Update const.rb

* Always convert result to boolean

* Always convert result to boolean

* Use File.join to prevent duplicate slashes

* rubocop: Disable `Lint/RedundantSafeNavigation` rule

* ruby_rubocop: Update checksum

* Fix logic

* Change `CREW_DLL_PREFIX` to `CREW_WINE_PREFIX`

* Use `&&` to concatenate commands

* Update const.rb

* Remove redundant `nil`

* Bump version

* Align + more cleanup

* Don't use ENV.fetch when default value is not needed

---------

Co-authored-by: Satadru Pramanik, DO, MPH, MEng <satadru@gmail.com>
2023-11-08 10:24:46 -05:00
Satadru Pramanik, DO, MPH, MEng
ded56e955c Use same ExitMessage for all packages asking to source ~/.bashrc (#8900)
* Use same ExitMessage for all packages asking to source ~/.bashrc

* refactor reload_source

* update mold

* add extra space

* fix msg

* rename macro

* change name of macro again, run rubocop on package.rb

* update mold => 2.3.2
2023-11-06 18:46:40 -06:00
Ed Reel
21f11675dd Revert "lib/const: Simplify + cleanup (#8890)" (#8895)
This reverts commit f3a58c9492.

Fixes `crew install vim` and `crew install cantarell_fonts`.
2023-11-05 17:49:42 -05:00
SupeChicken666
f3a58c9492 lib/const: Simplify + cleanup (#8890)
* lib/const: Simplify + cleanup

* Fix nil issue

* Update const.rb

* Always convert result to boolean

* Always convert result to boolean

* Use File.join to prevent duplicate slashes

* rubocop: Disable `Lint/RedundantSafeNavigation` rule

* ruby_rubocop: Update checksum

* Fix logic

* Change `CREW_DLL_PREFIX` to `CREW_WINE_PREFIX`

* Use `&&` to concatenate commands

* Update const.rb

* Remove redundant `nil`

* Bump version

* Align + more cleanup

* Don't use ENV.fetch when default value is not needed
2023-11-05 10:12:41 -06:00
SupeChicken666
7bf99a15c7 crew: Retry make with single thread if failed (#8755)
* crew: Retry `make` with `-j1` if build failed

* Fix bugs

* Fix bugs

* Bump Crew Version

---------

Co-authored-by: Satadru Pramanik, DO, MPH, MEng <satadru@gmail.com>
2023-10-13 11:51:27 -04:00
Maximilian Downey Twiss
2f42ff39cc Run Rubocop on tree, again (#8704) 2023-09-29 07:51:08 -04:00
Maximilian Downey Twiss
ec27b6054d Refactor buildsystem variables (#8541) 2023-08-08 18:22:12 -05:00
Maximilian Downey Twiss
a08df3431f Detect rebuilds via changes in binary_sha256 when updating (#8531) 2023-08-04 00:26:03 -05:00
Ed Reel
d2728648a2 Xzutils 5.4.3 => 5.4.4 (#8532) 2023-08-03 06:59:06 -04:00
Satadru Pramanik, DO, MPH, MEng
d5d2d5551e Add no_lto (#8436)
* Add no_lto

* add xorg_proto update

* update libepoxy as no_lto example

* add no_lto to packages

* move no_lto
2023-06-22 15:03:21 -05:00
Ed Reel
ea8b332a86 Add preremove package function (#7988)
Add preremove to transmission package

Co-authored-by: chronos <noreply@github.com>
2023-02-24 20:31:21 -05:00
Ed Reel
02d6b51c19 Add no_links property and CREW_NOT_LINKS environment variable (#7779) 2022-12-29 10:59:07 -05:00
supechicken
d060ba2c0a crew: Add support for dependency version ranges (#7725)
* crew: Add support for dependency version ranges

* Fix errors

* Fix typos

* Update error message

* Fix logic

* Add suggested changes
2022-12-10 10:13:01 -06:00
Satadru Pramanik
00f4b755bb adjust recursive build dep logic (#7695)
* adjust recursive build dep logic

* adjust logic

* adjust logic

* adjust logic

* cleanup
2022-11-29 18:05:52 -06:00
Satadru Pramanik
538d786d5c revert package.rb set_property as unnecessary (#7618) 2022-11-10 14:54:17 -06:00
Satadru Pramanik
47838138db crew: Add cflags for armv7l, add some CREW_ constants (#7585)
* Add armv7l cflags and CREW_KERNEL_VERSION const

* Adjust package code which uses kernel version

* rework logic

* adjust logic

* debugging

* add CREW_IN_CONTAINER

* Use CREW_IN_CONTAINER in packages.

* Add CREW_IS_AMD and CREW_IS_INTEL

* suggested changes

* test new cpu logic

* cleanup cpu logic

* add CREW_CPU_VENDOR

* fix cpu detection on x86

* lint

* fix package dynamic versioning

* lint changes

* update for non-x86, and make linuxheaders a one-shot deal

* add 5.10 x86_64 binaries for linuxheaders

* lint

* suggested changes

* fix musl_linuxheaders

* show container info in sysinfo

* Use CREW_KERNEL_VERSION

* add markdown interpretation code

* refactor markdown code

* modify issue template to get markdown code for crew sysinfo

* attempt to change the issue template to the newer github yaml format

* move issue template to yaml file

* update Linters logic

* lint crew

* update linter.rb too

* bump linter.rb version
2022-11-08 16:18:09 -06:00
Satadru Pramanik
042a3a616b crew: cache builds (#7544)
* crew: cache builds

* make linter suggestions

* remove debug code

* Tear out some musl_zstd code

* use a dir higher up for the build cache archive

* fixup extraction dir for cached builds

* save backup of build cache instead of overwriting

* change int signal handler

* remove debug code

* Add checks for cachefile sha256 hash files

* suggested changes; change all File.exists to File.file

* bump minorversion

* change error message to informational orange
2022-10-25 10:46:12 -05:00
supechicken
4f840557db lib/selector: Add selector library, apply to jdk and hunspell (#7473)
* Add selector library, apply to `jdk` and `hunspell`

* Make rubocop happy

* Fix syntax error

* jdk: Fetch version from packages

* Auto update version number

* hunspell: wrap with `ARGV.include?`

* Fix syntax error

* Make rubocop happy

* jdk: use `Dir[]`

* Generate options dynamically
2022-10-16 00:32:23 -05:00
supechicken
9eb887589f Run preflight check on dependencies also, remove autoremove command (#7455)
* Run preflight check on dependencies, remove `autoremove` cmd

* Export `compatible?` method

* Update `crew`

* Add a warning for missing `compatibility` field

* Bump version

* Make rubocop happy

* Remove `is_compatible?` function

* Colored output requires `lib/color.rb`

* readme: Remove `autoremove` command

* Change from warning to error

* `return false`

* Make rubocop happy

* Update crew

* Use `File.join`
2022-10-08 10:06:24 -05:00
Ed Reel
2b09b03a48 Add no_compress, no_shrink and no_strip boolean options (#7416)
* Add no_compress, no_shrink and no_strip boolean options

* Remove empty lines in bin/crew
2022-09-17 18:46:33 -04:00
Maximilian Downey Twiss
f6cea137b4 Fix rubocop errors that snuck in (#7335) 2022-08-23 22:35:03 -04:00
Maximilian Downey Twiss
de24923ee8 Add Rubocop CI (#7083)
* Rename IgnoredPatterns to AllowedPatterns.

* Exclude docopt.rb (not our code) from Rubocop

* Disable Style/RedundantReturn

* Disable Style/MutableConstant

* Disable Style/NumericLiterals

* Set Layout/IndentationStyle to spaces

* Temporarily disable various cops.

* Add Rubocop CI via Octocop

* Lint tree with rubocop -A -c .rubocop.yml

Co-authored-by: Satadru Pramanik <satadru@gmail.com>
2022-08-22 13:31:25 -04:00
supechicken
27fdd2294f crew: Force UT8 on package load (#7320) 2022-08-22 08:25:32 -04:00
supechicken
7ed76d1845 crew: Isolate package classes from global scope (#7283)
* crew: Isolate package classes from global scope

* Use `require_relative`

* Fix typo

* Prevent duplicate loading packages

* Bump version
2022-08-17 13:51:07 -05:00
Cassandra Watergate
5cd230bf1a python buildsystem, second PR (#7106)
* Revert d3038e0805
* upgrade ca_certificates
* upgrade py3_cryptography
* upgrade py3_semantic_version
* upgrade py3_setuptools
* upgrade py3_setuptools_rust
* upgrade py3_typing_extensions
* upgrade py3_wheel
* new package py3_setuptools_scm
* enable git_clone_deep on py3_setuptools_scm
* new package py3_pycparser
* fix setuptools_scm (super secret environment variable)
* fix python -m versioning with envvar
* ca_certificates should be in different PR
* git_no_recursive -> git_no_submodules (better name)
* bump crew version
* add x86_64 and i686 binaries
* git_no_submodules => no_git_submodules
* add missed binaries
* add arm binaries

Co-authored-by: Ed Reel <edreel@gmail.com>
2022-06-04 02:29:45 -05:00
Ed Reel
fc1d3efafe Revert d3038e0805 (#7090) 2022-05-29 17:17:01 -04:00
supechicken
d3038e0805 crew: Add multi-component support in one package (#7018)
* crew: Add multi-component support in one package

* Remove CREW_USE_RSYNC variable

* suggested @uberhacker changes

* Change back to `Dir.glob(...)` (`Dir[...]` will not work with blocks)

* Change `Dir.glob` to `Dir[...].each` (be consistent)

* Merge upstream

* Update gcc.rb

* Add `{glob,regex,array}` support for file filter

* Add comment

* `sed s/gcc11::libs/gcc::libs/g *`

* Remove extra options

* Delete `CREW_PREFIX` in filenames that will be passed to the filter function

Co-authored-by: Satadru Pramanik <satadru@gmail.com>
2022-05-23 10:45:24 -05:00
supechicken
cb7eb4993b Merge gcc12.rb and gcc.rb, cleanup, remove any gcc packages older than 12 (#7076)
* Delete older `gcc` versions

* Delete older `gcc` versions, merge `gcc12.rb` and `gcc.rb`

* Fix syntax error

* Switch from `gcc12.rb` to `gcc.rb`

* remove gcc_tools

* Fix `exception` logic in `def self.system` (`package.rb`)

* Update gcc.rb

* Correct usage of `File.write`

* Update gcc.rb

* Update gcc.rb

* `previous` might be better than `older`
2022-05-22 12:30:01 -05:00
supechicken
725fc6c769 lib/package.rb: Exclude buildessential dependency on some packages which have prebuilt binary as source (#6923)
* lib/package.rb: Add `no_compile_needed` flag

* Bump version

* Check `no_compile_needed` also in `def strip_dir`

* Change all `CREW_NOT_STRIP` to `no_compile_needed`
2022-03-30 14:28:08 -04:00
Satadru Pramanik
3738037086 Gnome macro (#6909)
* Use gnome macro for package postinstalls

* add gnome postinstall message.

* add fixed up package

* fix continue logic

* move info message behind verbose flag

* add gnome flag to current gtk packages

* remove GNOME_DEPS
2022-03-29 18:09:28 -05:00
supechicken
e44d98aa8c crew: Rewrite dependency resolver algorithm (#6840)
* Rewrite dependency resolver algorithm

* Add color for build dependencies, show satisfied dependencies

* Update help message

* Fix typo
2022-03-10 13:07:16 -05:00
Satadru Pramanik
3daee683b3 crew: use zstd (#6703)
* Initial .zst support

* initial zstd changes

* reverse tar version condition

* Change extension to .tar.zst

* Add verbosity, use nice for zstd

* add tar to core

* Add tar to buildessential

* Add tar to bootstrap packages

* Add musl tar with zstd support

* add error for old tar on system

* Add zst support to gl.sh, add update of rust in zst package format

* Add check for zstd before decompressing .zst files

* change new tar dependency to i686 only

* add more musl fixes

* add musl paths to tar cmd

* Add musl_zstd update with libc

* add musl path to install path

* add zst to strip_dir

* Add spaces to gl.sh

* remove extraneous no_zstd
2022-02-03 19:03:52 -06:00
Satadru Pramanik
e492f28081 patchelf option during package creation, revamp of boolean symbol processing (#6661)
* initial commit of using patchelf during package creation

* requested changes

* simplify symbols

* suggested change

* switch sh to bash + suggested changes

* WIP changes to elf detection and property detection

* make boolean symbols dynamic in package.rb

* remove some debug code

* report file being patched when libraries are not found

* Add rubocop cleanups

* crew rubocop adjustments

* remove debug code

* bump version

* add is_musl? musl.rb loading

* suggested changes

* requested change
2022-02-03 08:12:58 -06:00
Satadru Pramanik
add30dd4a6 Add git_fetchtags, simplify (.nil? or .empty?) to .to_s.empty? (#6640)
* Add git_fetchtags, simplify (.nil? or .empty?) to .to_s.empty?

* bump version

* remove duplicate check of @pkg.git_branch.to_s.empty?
2022-01-21 10:34:28 +08:00
Satadru Pramanik
1c7204fa89 New musl toolchain w/ static git, curl, lzip (and gcc11 rebuilds to fix brokenness on i686) (#6431)
* Musl revamp

* Cleanup Musl Packages

* fixup musl_libnghttp2

* fixup musl_libucontext
2022-01-20 11:48:59 -06:00