# Fabric java gateway jar package compilation

## compilation

1. Compile and install Fabric java sdk, or locally install fabric-sdk-java-2.2.8.jar in libs:
```commandline
mvn install:install-file -Dfile=fabric-sdk-java-2.2.8.jar -DpomFile=fabric-sdk-java-2.2.8.pom -DgroupId=org.hyperledger.fabric-sdk-java -DartifactId=fabric-sdk-java -Dversion=2.2.8 -Dpackaging=jar
```

2. Compile gateway:

```commandline
cd ..
mvn install -DskipTests
```
If it is a Linux version, you can directly install the gateway package
```commandline
mvn install:install-file -Dfile=fabric-gateway-java-2.2.2.jar -DpomFile=fabric-gateway-java-2.2.2.pom -DgroupId=org.hyperledger.fabric -DartifactId=fabric-gateway-java -Dversion=2.2.2 -Dpackaging=jar
```