Commit Graph

782 Commits (d71af0cfd78313cc37aa373b26b94dfcc98cd294)

Author SHA1 Message Date
modmuss50 d71af0cfd7
Kotlin metadata annotation remapping (#573)
Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>
2022-01-16 23:48:36 +00:00
modmuss50 421b41ebc7 Fix misc jar remapping issues. 2022-01-16 17:01:56 +00:00
modmuss50 d40241d75a
Fix performance regressions in large multi-project builds. (#571)
* Perf improvements to multi-project builds.

* Fixes.

* More fixes.

* Layered mappings fixes

* Perf improvements. Undo broken fix.

* Fix remap classpath being empty.

* Another gradle bug? Either way this is fine and works.

* Fix broken test

* Final fixes?

* Fix and cleanup mixin ap mappings.
2022-01-14 19:50:45 +00:00
modmuss50 6fd3d5d021 Delete existing sources jar when re-running jar processors. Fixes #560 2022-01-05 09:58:19 +00:00
modmuss50 240a23f52d Improve decompiler options by moving them away from the task.
Done because the split jar changes required registering the decompiler task after evaluation.
As there may be more than one decompile task, the options are set per decompiler and not per task.
This should also make easier to add new decompilers without requiring a plugin.
2022-01-05 09:49:11 +00:00
modmuss50 19143fc5a8 Remove JarProcessor#isInvalid and impl getId correctly. 2022-01-04 21:40:20 +00:00
modmuss50 4158062ce5
Experimental support for split common and clientonly minecraft jars. (#561)
This lays the ground work for split client and server mod code. With this first phase when enabled loom will generate a clientonly and common minecraft jar. Fabric loader and API will both need changes to support this before it can be used to develop mods.

Phase two of this project will handle splitting mod code into a client and common source set along with spliting any dependencies. 

Mostly fixes #539 by sepreating decompile tasks
2022-01-04 21:19:03 +00:00
shartte ccfe12eb17
Interface Injection (#496)
* Added interface injection via fabric.mod.json.

* Added interface injection

* Added amending of class signature with injected interface.
2022-01-04 18:15:21 +00:00
modmuss50 03d3950d11 Exclude client only libraries in server run task. 2021-12-30 00:15:18 +00:00
modmuss50 15afb45769 Exclude client only libraries in the IntelliJ server run config. 2021-12-29 23:52:13 +00:00
modmuss50 87abd7ad7b Merge branch 'dev/0.10' into exp/0.11 2021-12-29 22:26:57 +00:00
val = int(1) 7611e3a632
Add support for mixin files outside of root in MixinRefmapHelper (#536)
* Add support for mixin files outside of root in MixinRefmapHelper

* Fix checkstyle + Integration tests + Checks all srcDirs from sourceSet

* Redid part that failed to save for last commit

* Other issues fixed

* Checkstyle again

* Made getting root paths safer

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>

* CodeNarc for test

* Normalized all paths to fix issues on Windows

* Removed debug line used to test return value of lamdba

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>
Co-authored-by: modmuss50 <modmuss50@gmail.com>
2021-12-29 22:16:13 +00:00
modmuss50 63f2b51b2c Fix include generating modid's that are too long for loader
Co-authored-by: NebelNidas <burnerjulian@gmail.com>
2021-12-29 22:06:34 +00:00
modmuss50 e985cb85d4 Only quote program arguments if they actually contain spaces 2021-12-29 22:03:06 +00:00
Juuxel 005d180e0c
Fix up-to-date checks for ValidateAccessWidenerTask (#565)
* Apply mitigation's against Log4J2 exploit CVE-2021-44228.

* Only warn when the yarn version does not match the minecraft version.

Should allow yarn versions to be used across mc versions when needed.

* Fix up-to-date checks for ValidateAccessWidenerTask

Co-authored-by: modmuss50 <modmuss50@gmail.com>
2021-12-29 21:59:19 +00:00
modmuss50 2752b61cb7 Cleanup signature fixer code + add basic integration test. Fixes #546 2021-12-29 19:27:24 +00:00
modmuss50 6aa552bad0 Add task to download gradle sources next to the api jar. 2021-12-29 18:34:09 +00:00
modmuss50 9ca915df15 Undo accidental code commenting. 2021-12-29 00:12:27 +00:00
modmuss50 53b839b739 Decompiler API improvements:
* Fix decompiler tasks getting registered in afterEvaluate
* Allow decompilers to add file collections to the forked JVM classpath.
* General code cleanup.
2021-12-29 00:10:58 +00:00
modmuss50 b377db7297 Only warn when the yarn version does not match the minecraft version.
Should allow yarn versions to be used across mc versions when needed.
2021-12-22 22:39:18 +00:00
modmuss50 e4244dc895 Remove idea-ext plugin, replace with 1 internal gradle api. Vastly improves import performance. 2021-12-20 16:54:03 +00:00
modmuss50 ab21e0e550
Rewrire Jar and Source remapping tasks. (#504) 2021-12-20 16:29:11 +00:00
modmuss50 5a16440c1e
Support ARM natives, rewrite native handling and misc cleanup. (#554)
* Rewrite natives handling, upgrade LWJGL on ARM machines.

* Remove old natives override hack, should now always be done via gradle.

* Use "idea" everywhere

* Add server specific libraries onto their own classpath. Includes misc code cleanup.

* Start on writing the excluded server libs.

* Gradle deprecation fixes, and misc cleanup

* Add support mod.

* Make native support mod none transitive.

* Update gradle.
2021-12-17 15:37:00 +00:00
modmuss50 4eb0290bb4 Apply mitigation's against Log4J2 exploit CVE-2021-44228. 2021-12-10 10:59:14 +00:00
modmuss50 4ace257c37 Fix unit tests 2021-12-04 19:00:47 +00:00
modmuss50 efddf8f35c Run validate access widener task before genSources. Closes #550 2021-12-04 19:00:47 +00:00
modmuss50 6d65e120e7 Remove deprecated stuff 2021-12-04 19:00:47 +00:00
modmuss50 337d17bb92 Java 17 and update libs. Closes #545 2021-12-04 19:00:47 +00:00
modmuss50 5ce9fde9b1 Start on 0.11 2021-12-04 14:10:12 +00:00
modmuss50 b550ca7857
Validate remapped mods also have a remapped access widener. (#549)
* Validate remapped mods also have a remapped access widener.

* Fix checkstyle
2021-12-02 18:59:47 +00:00
modmuss50 4b45783a54 Fix crash on Java 18 due to unpick using an outdated asm version.
Unpick will now get the same version of asm that loom is running with on its classpath.
2021-11-26 23:10:35 +00:00
modmuss50 60c908ea1b Fix duplicate comments about transitive access wideners. Fixes #544
A more sophisticated fix might be nice, but im not sure it will provide a lot of benefit.
2021-11-25 18:53:04 +00:00
modmuss50 7b28d61fab
More improvements/fixes to shared caches maven publications + test improvements. 2021-11-25 14:49:17 +00:00
Juuxel 9ddff5f31a
Fix gradle module metadatas not including api deps in runtimeElements (#540) 2021-11-23 18:35:08 +00:00
modmuss50 babbc55586
Add an option (enabled by default) to map synthetic field and method names from the official mojang mappings. (#538) 2021-11-20 21:46:33 +00:00
modmuss50 9c2b1e8d6d Fix access widener file hashcode calculation breaking caching.
When using transitive access wideners the mc jar would always be re-processed.
2021-11-17 15:30:23 +00:00
modmuss50 dd7882598e Add getBaseMappedJar to make it easier to get the pre-transformed game jar. 2021-11-15 13:42:07 +00:00
modmuss50 35afda4398
Fix `namedElements` not extending from api (#533)
* Fix `namedElements` not extending from api
Fix artifact not waiting for remapAllJars with shared caches

* Use apiElements

* Add a better test for this.

* Also add remapped api mods to namedElements
2021-11-12 10:46:23 +00:00
modmuss50 2994c2d488 Fix for 1.18-pre1 server bundler.
In the bundler its called 1.18 Pre-release 1 not 1.18-pre1, so we just assume there is only ever going to be 1 version per jar.
2021-11-11 18:28:15 +00:00
modmuss50 e2b4bc8985 Reduce log level of "Using project based jar storage".
This will be used on a lot more projects now as transitive access wideners becomes more widely used.
2021-11-10 17:42:41 +00:00
modmuss50 ba4b9289e2 Ensure that the encoding is set to UTF-8 2021-11-10 14:23:32 +00:00
modmuss50 b2228e3175
Fix unobfuscated names not having params or docs. (#532) 2021-11-09 22:07:43 +00:00
modmuss50 cb5c009e1a Fix missing blank line between javadoc and params 2021-11-01 18:30:42 +00:00
Cat Core a91b75c05c
Allow to set custom intermediary url again (#528)
* allow to set custom intermediary url again

* apply suggestions

* add some javadoc
2021-11-01 15:47:28 +00:00
modmuss50 5f379e4f42
Make CFR the default decompiler (#527)
* Make CFR the default decompiler
Expose decompiler options

* Remove convention, default value is an empty map.

* Checkstyle..
2021-11-01 13:43:03 +00:00
modmuss50 d01c20f049 Update cfr 2021-10-30 23:41:19 +01:00
Juuxel 587db4abae
Add localRuntime and modLocalRuntime configurations (#526)
Closes #481.

Co-authored-by: modmuss50 <modmuss50@gmail.com>
2021-10-29 22:26:59 +01:00
modmuss50 e409f13b8c
Add dev config with default jar task on it, to aid with depending on … (#525)
* Add dev config with default jar task on it, to aid with depending on sub projects.

* Rename to `namedElements`

* Update src/main/java/net/fabricmc/loom/configuration/CompileConfiguration.java

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>

Co-authored-by: Juuxel <6596629+Juuxel@users.noreply.github.com>
2021-10-29 13:29:29 +01:00
modmuss50 177264420e Fix misleading error message when decompiling fails. 2021-10-28 18:15:59 +01:00
shedaniel 5c190cc3ef
Use NIO instead of ZipUtil (#513)
* Use nio for zip utils

* Make tests work

* Please work

* Fix some issues with tests

* Fix more issues with tests

* NIOZipUtils -> ZipUtils

* Resolve Juuxel's reviews

* Use our own FS utils

* Improve error handling, add loom Pair

* Add Unit tests + fixes

Co-authored-by: modmuss50 <modmuss50@gmail.com>
2021-10-26 13:08:17 +01:00