diff --git a/README.md b/README.md index 1203f2b..884a25e 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,8 @@ - - - +This repository contains custom PKGBUILD files for packaging various things. # Building - +This details how to build a specific package. ## Regularly @@ -16,8 +14,13 @@ makepkg -si ## In chroot Based on [an Arch Wiki article](https://wiki.archlinux.org/title/Creating_packages#Using_pkgctl_to_build_in_a_clean_chroot_environment). -First, install the `devtools` package from the official repository. Then navigate to the package directory and run +First, install the `devtools` package from the official repository. Then navigate to the package directory and run: ```sh pkgctl build ``` +If it gets built, you can install the resulting `.pkg` file via: +```sh +sudo pacman -U packagename.pkg.tar.zst +``` + diff --git a/msosa/.SRCINFO b/msosa/.SRCINFO new file mode 100644 index 0000000..27b6e6c --- /dev/null +++ b/msosa/.SRCINFO @@ -0,0 +1,15 @@ +pkgbase = magic-systems-of-systems-architect + pkgdesc = Powerful modeling tool based on the MagicDraw platform by No Magic + pkgver = 2022.2 + pkgrel = 1 + url = https://docs.nomagic.com/display/MSOSA2024xR2 + arch = any + license = custom + makedepends = desktop-file-utils + depends = java-runtime=11 + source = local://Magic_Systems_of_Systems_Architect_2022x_Refresh2_unix.sh + source = installer.properties + sha256sums = 2c32231cc6f0eaf5fe33eb62ea811db5684874c499eeec72d6a252db20983e1e + sha256sums = SKIP + +pkgname = magic-systems-of-systems-architect diff --git a/msosa/.gitignore b/msosa/.gitignore new file mode 100644 index 0000000..62e8b24 --- /dev/null +++ b/msosa/.gitignore @@ -0,0 +1,7 @@ +/* +!/.gitignore +!/.SRCINFO +!/PKGBUILD +!/README.md + +!/installer.properties diff --git a/msosa/PKGBUILD b/msosa/PKGBUILD new file mode 100644 index 0000000..6c17557 --- /dev/null +++ b/msosa/PKGBUILD @@ -0,0 +1,62 @@ +# Maintainer: Dominykas Svetikas +pkgname='magic-systems-of-systems-architect' +pkgver='2022.2' #2022x Refresh2 +pkgrel='1' +pkgdesc='Powerful modeling tool based on the MagicDraw platform by No Magic' +url='https://docs.nomagic.com/display/MSOSA2024xR2' +arch=('any') +license=('custom') +depends=('java-runtime=11') +makedepends=('desktop-file-utils') +source=( + "local://Magic_Systems_of_Systems_Architect_2022x_Refresh2_unix.sh" + "installer.properties" +) +sha256sums=( + '2c32231cc6f0eaf5fe33eb62ea811db5684874c499eeec72d6a252db20983e1e' + 'SKIP' +) + +build() { + # Fix for "Error: Could not find or load main class com.zerog.lax.LAX" + export JAVA_TOOL_OPTIONS="-Djdk.util.zip.disableZip64ExtraFieldValidation=true" + + # Set the JAVA_HOME environment variable + export PATH="/usr/lib/jvm/java-11-openjdk/bin/:$PATH" + # Move every tempdir to the source directory, including the user.home + export JAVA_TOOL_OPTIONS="$JAVA_TOOL_OPTIONS -Djava.io.tmpdir=$srcdir/tmp -Duser.dir=$srcdir/tmp/tmp2 -Duser.home=$srcdir" + + # Replace the $BUILD_PATH variable in the installer.properties file + sed -e "s|\$BUILD_PATH|$PWD|" installer.properties > installer.properties.tmp + + # Specify the temporary directory for the installer + # https://community.flexera.com/s/article/installanywhere-self-extraction-and-temp-space-requirements + mkdir -p "$srcdir/tmp" + export IATEMPDIR="$srcdir/tmp" + + # Create the required directories, otherwise warnings are generated and it fails + mkdir -p "$srcdir/.local/share/applications" + mkdir -p "$srcdir/magic-systems-of-systems-architect/userhome" + + ./Magic_Systems_of_Systems_Architect_2022x_Refresh2_unix.sh -f "$srcdir/installer.properties.tmp" -i console -l en + + # Update the desktop file with the correct path + desktop-file-edit .local/share/applications/*.desktop --set-key=Exec --set-value="magic-systems-of-systems-architect" + desktop-file-edit .local/share/applications/*.desktop --set-key=Icon --set-value="/usr/share/pixmaps/magic-systems-of-systems-architect.ico" +} + +package() { + cd "$srcdir/magic-systems-of-systems-architect" || exit 1 + + # Install the application + install -d $pkgdir/{opt/$pkgname,usr/bin} + cp -a bin certs data help lib manual mdmain.ini modelLibraries openapi plugins profiles samples templates $pkgdir/opt/$pkgname + ln -s /opt/$pkgname/bin/msosa $pkgdir/usr/bin/$pkgname + + # TODO: Change some permissions + + # Install the desktop file + install -d "${pkgdir}/usr/share/pixmaps" + install -Dm644 $srcdir/.local/share/applications/Magic_Systems_of_Systems_Architect_2022x_Refresh2.desktop $pkgdir/usr/share/applications/$pkgname.desktop + ln -s /opt/$pkgname/bin/msosa.ico "${pkgdir}/usr/share/pixmaps/$pkgname.ico" +} diff --git a/msosa/README.md b/msosa/README.md new file mode 100644 index 0000000..df57350 --- /dev/null +++ b/msosa/README.md @@ -0,0 +1,3 @@ +You will need to obtain an installation file and put it in the directory with the PKGBUILD file. + +Currently broken with chroot builds. diff --git a/msosa/installer.properties b/msosa/installer.properties new file mode 100644 index 0000000..459b52c --- /dev/null +++ b/msosa/installer.properties @@ -0,0 +1,13 @@ +#Choose Java Virtual Machine +#--------------------------- +JDK_HOME=/usr/lib/jvm/java-11-openjdk +JAVA_DOT_HOME=/usr/lib/jvm/java-11-openjdk +JAVA_EXECUTABLE=/usr/lib/jvm/java-11-openjdk/bin/java + +#Choose Install Folder +#--------------------- +USER_INSTALL_DIR=$BUILD_PATH/magic-systems-of-systems-architect + +#Choose Link Folder +#------------------ +USER_SHORTCUTS=$BUILD_PATH diff --git a/ttf-edo-sz/.gitignore b/ttf-edo-sz/.gitignore index 91f1c10..713f6f8 100644 --- a/ttf-edo-sz/.gitignore +++ b/ttf-edo-sz/.gitignore @@ -1,4 +1,4 @@ /* !/.gitignore -!/PKGBUILD !/.SRCINFO +!/PKGBUILD diff --git a/ttf-edo-sz/PKGBUILD b/ttf-edo-sz/PKGBUILD index 25140c3..a7421c3 100644 --- a/ttf-edo-sz/PKGBUILD +++ b/ttf-edo-sz/PKGBUILD @@ -1,3 +1,4 @@ +# Maintainer: Dominykas Svetikas pkgname=ttf-edo-sz pkgver=1 pkgrel=1