Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Organize Misq with multi-project Gradle build system #1

Merged
merged 10 commits into from
Jun 5, 2021

Commits on Jun 3, 2021

  1. Organize Misq with multi-project Gradle build system

    - Gradle version 7.0.2 and OpenJDK 16, are required.
    
    - The JDK's Java Modules (JPMS) framework is not used, except where
      necessary (JavaFX apps require jvm options specify modules).
    
    - Gradle projects are distinct (not sub-projects), but share common
      platforms (version constraints), dependencies, and build tasks.
    
    - Gradle task customization is defined in buildSrc/build.gradle, but
      can be overriden in module build files.
    
    - Gradle parallel build feature is used to shorten build times.
      This did not work in Bisq, but it is worth trying in latest
      Gradle version.
    
    - Common dependency declarations are defined in buildSrc/*.gradle files.
    
    - Common protobuf generation task is defined in buildSrc/gen-protos.gradle
    
    - The Gradle Platforms api is used to define dependency version
      constraints in a central location.  Projects (modules) reference a platform,
      then declare specific dependencies without needing to specify the
      version.  Referencing a platform does not declare any dependencies,
      it only constrains the dependency version when project declares it.
    
    - Gradle signature verification support for dependenices is not enabled.
      Enabling it requires creating gradle/verification-metadata.xml and
      manually configuring each failed verfication.
      See https://docs.gradle.org/7.0.2/userguide/dependency_verification.html
      Note: the gradle-witness plugin is not compatible with Gradle 7.0.2.
    
    Modules (Synonymous with Gradle Projects, not JPMS Modules)
    
    - Stub out module 'api' with common logging/test deps.
    
    - Stub out module 'application' with common logging/test deps.
    
    - Stub out module 'common', defining shared logging/test deps.
    
    - Stub out modules 'grpc' & 'cli' with grpc, protobuf, & common logging/test deps.
    
    - Stub out module 'jfx' with java-fx, and common logging/test deps.
    
      Jpackage v16 has been shown to work for simple JFX 16 app via cmd line.
      May use a modified Bisq:desktop:package.gradle script to invoke from
      the 'jfx:build.gradle',  or see if a convenience plugin can work with
      jpackage 16. See https://github.com/petr-panteleyev/jpackage-gradle-plugin.
    
    - Stub out module 'p2p' with P2PService class, protobuf, & common logging/test deps.
    
    - Stub out module 'web' with common logging/test deps.
    
      Webapp framework choice is still being considered.
    ghubstan committed Jun 3, 2021
    Configuration menu
    Copy the full SHA
    d609b8b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    cd3efe5 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    64d467b View commit details
    Browse the repository at this point in the history

Commits on Jun 4, 2021

  1. Configuration menu
    Copy the full SHA
    6b484a0 View commit details
    Browse the repository at this point in the history
  2. Add buildSrc/os-arch.gradle to make os info available to all projects

    Contains extra osxArch property to work around Mac M1 protobuf support bug,
    which may be fixed by google in next release.
    ghubstan committed Jun 4, 2021
    Configuration menu
    Copy the full SHA
    91f1ef1 View commit details
    Browse the repository at this point in the history
  3. Change jfx dist's entry point from JfxMain to Main

    The generated jfx distribution requires a wrapper around
    JfxMain.  Main must be the dist's entry point.  Renaming
    JfxMain as Main does not fix the dist runtime problem.
    
    See javafxports/openjdk-jfx#236
    ghubstan committed Jun 4, 2021
    Configuration menu
    Copy the full SHA
    9b5ec53 View commit details
    Browse the repository at this point in the history
  4. Remove semicolons

    ghubstan committed Jun 4, 2021
    Configuration menu
    Copy the full SHA
    d6c8149 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    a691871 View commit details
    Browse the repository at this point in the history
  6. Fix LICENSE, use AFFERO

    ghubstan committed Jun 4, 2021
    Configuration menu
    Copy the full SHA
    549248a View commit details
    Browse the repository at this point in the history
  7. Provide module-info.java to 'org.openjfx.javafxplugin'

    The 'org.openjfx.javafxplugin' logs a potentially misleading message
    if a JPMS module-info.java is missing from any project is it applied to
    (in this case, the jfx gradle project).  This change adds a module-info.java,
    and build msg "Project :jfx => no module-info.java found" becomes
    "Project :jfx => 'network.misq.jfx' Java module".
    
    Many 3rd party libraries conform to the JPMS "Automatic Module" and "Unnamed Module"
    type structures, but not all, like the gprc libs.  Should the misq:jfx project
    module ever require any 3rd party lib that does not conform to any JPMS module type,
    this change will have to be reverted, and misq builds will log "no module-info.java
    found" messages.
    ghubstan committed Jun 4, 2021
    Configuration menu
    Copy the full SHA
    02a93e9 View commit details
    Browse the repository at this point in the history