From 5c8dd58793502005017ef88a6898a127737c14b8 Mon Sep 17 00:00:00 2001 From: Mohammad Amin Chitgarha Date: Tue, 5 Apr 2022 14:27:15 +0430 Subject: [PATCH 1/9] Don't exclude Glibc (libc.so and libm.so) from the AppImage The latest AppImage does not work because of Glibc incompatibilities. Such a disaster! --- build-aux/appimage/build.sh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/build-aux/appimage/build.sh b/build-aux/appimage/build.sh index 1cfc299..6003f6d 100755 --- a/build-aux/appimage/build.sh +++ b/build-aux/appimage/build.sh @@ -120,9 +120,7 @@ bundlePhpSharedLibraries() { # Reached the argument after an arrow, so bundle it if [[ "$prevWasArrow" = true ]]; then # Don't include libc and libm - if ! [[ "$i" =~ "libc.so" || "$i" =~ "libm.so" ]]; then - cp "$i" "$appDir/usr/$i" - fi + cp "$i" "$appDir/usr/$i" prevWasArrow=false fi From bdeb6b0031a48b456ff03bb1f4f9aef8080a05f7 Mon Sep 17 00:00:00 2001 From: Mohammad Amin Chitgarha Date: Tue, 5 Apr 2022 14:31:27 +0430 Subject: [PATCH 2/9] Output the libraries being bundled in build.sh --- build-aux/appimage/build.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/build-aux/appimage/build.sh b/build-aux/appimage/build.sh index 6003f6d..1789869 100755 --- a/build-aux/appimage/build.sh +++ b/build-aux/appimage/build.sh @@ -115,12 +115,18 @@ bundlePhpSharedLibraries() { # Extract all libraries, which came after an arrow in ldd output lddOutput="$(ldd "$appDir/usr/bin/php")" + # For debugging purposes + echo "ldd of PHP binary:" + echo "$lddOutput" + prevWasArrow=false for i in $lddOutput; do # Reached the argument after an arrow, so bundle it if [[ "$prevWasArrow" = true ]]; then # Don't include libc and libm + echo "Bundling '$i'..." cp "$i" "$appDir/usr/$i" + prevWasArrow=false fi From f270f8049949be372b8727af1097227a83cc67c1 Mon Sep 17 00:00:00 2001 From: Mohammad Amin Chitgarha Date: Tue, 5 Apr 2022 14:40:02 +0430 Subject: [PATCH 3/9] Fix and improve grammar in README.md --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index ca1a869..7217c1c 100644 --- a/README.md +++ b/README.md @@ -10,13 +10,13 @@ Easy and semi-intelligent VHDL simulation tool, integrating GHDL and GTKWave. - 💡 Zero-configuration by default. Go ahead and simulate your design! - - ☕ Easy to use. You don't need to remember or look for dependencies everytime, Parvaj does this for you. You wouldn't even need to know most of the GHDL command-line options. + - ☕ Easy to use. You don't need to remember or look for dependencies everytime, Parvaj does it for you. You wouldn't even need to know most of the GHDL command-line options. - ☔ Simple installation process, by providing AppImage and Phar files. - **Fast:** - - ⛽ Speed up your development. Don't get your hands dirty by invoking GHDL and GTKWave manually, use the simple `simulate` command instead to do all the steps for you. + - ⛽ Speed up your development. Don't get your hands dirty by invoking GHDL and GTKWave manually; use the simple `simulate` command instead to do all the steps for you. - ⚡ The tool itself is designed to have good performance. It uses a proper cache mechanism for this. Although it uses regex patterns for major tasks, thanks to fast PHP regex engine, you wouldn't notice slowdowns. @@ -24,7 +24,7 @@ Easy and semi-intelligent VHDL simulation tool, integrating GHDL and GTKWave. - 🔥 Automatic detection of dependencies. Forget about what depends on what. - - 🧠 After finding where a unit (e.g. entity) lives, it remembers it. Don't worry, it is smart enough to check if it was moved around or has been renamed. Just use it! + - 🧠 After finding where a unit (e.g. entity) lives, Parvaj remembers it. Don't worry, it is smart enough to check if it was moved around or was renamed. Just use it! ## Let's Install! From f0a6a11c5b12ce7e92f27f4503e26c91272f164e Mon Sep 17 00:00:00 2001 From: Mohammad Amin Chitgarha Date: Tue, 5 Apr 2022 14:53:42 +0430 Subject: [PATCH 4/9] Bump version to 0.3.2-rc.1 --- src/Console/Application.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Console/Application.php b/src/Console/Application.php index 6c54ed5..a5aac8f 100644 --- a/src/Console/Application.php +++ b/src/Console/Application.php @@ -7,7 +7,7 @@ class Application extends \Symfony\Component\Console\Application { public const NAME = "Parvaj"; - public const VERSION = "0.3.1"; + public const VERSION = "0.3.2-rc.1"; public function __construct() { From 6f8d792974c9a8712b18e87d269d63b8e6cba48d Mon Sep 17 00:00:00 2001 From: Mohammad Amin Chitgarha Date: Tue, 5 Apr 2022 15:35:21 +0430 Subject: [PATCH 5/9] Bundle PHP shared libraries just before stripping the PHP binary Because after stripping, symbols get removed and ldd command might not work properly. --- build-aux/appimage/build.sh | 6 +++--- src/Console/Application.php | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/build-aux/appimage/build.sh b/build-aux/appimage/build.sh index 1789869..dc4e477 100755 --- a/build-aux/appimage/build.sh +++ b/build-aux/appimage/build.sh @@ -84,6 +84,9 @@ buildPhp() { cp ./php.ini-development "$iniPath" customizePhpIni "$iniPath" + echoSection "Bundling PHP shared libs..." + bundlePhpSharedLibraries "$appDir" + echoSection "Cleaning up..." minimizePhpInstallationSize "$installationPrefix" @@ -232,9 +235,6 @@ if [ "$skipPhpBuild" != true ]; then echoSection "Building PHP..." buildPhp "$phpSourcePath" "$phpInstallationPath" - - echoSection "Bundling PHP shared libs..." - bundlePhpSharedLibraries "$appDir" fi echoSection "Copying Parvaj root to AppDir..." diff --git a/src/Console/Application.php b/src/Console/Application.php index a5aac8f..388df0f 100644 --- a/src/Console/Application.php +++ b/src/Console/Application.php @@ -7,7 +7,7 @@ class Application extends \Symfony\Component\Console\Application { public const NAME = "Parvaj"; - public const VERSION = "0.3.2-rc.1"; + public const VERSION = "0.3.2-rc.2"; public function __construct() { From 59f105e9b75e0eda0b902da2241222fd5a3edc5c Mon Sep 17 00:00:00 2001 From: Mohammad Amin Chitgarha Date: Tue, 5 Apr 2022 17:22:19 +0430 Subject: [PATCH 6/9] Exclude Glibc and everything related The problem with previous AppImages were the inclusion of libraries retaining Glibc backward-compatibility, including libdl.so, librt.so and libpthread.so. Therefore, we exclude them all and rely on system's Glibc instead. --- build-aux/appimage/build.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/build-aux/appimage/build.sh b/build-aux/appimage/build.sh index dc4e477..25c37cf 100755 --- a/build-aux/appimage/build.sh +++ b/build-aux/appimage/build.sh @@ -126,9 +126,11 @@ bundlePhpSharedLibraries() { for i in $lddOutput; do # Reached the argument after an arrow, so bundle it if [[ "$prevWasArrow" = true ]]; then - # Don't include libc and libm - echo "Bundling '$i'..." - cp "$i" "$appDir/usr/$i" + # Don't include libc and related libraries + if [[ "$i" =~ "lib(m|c|rt|dl|pthread).so" ]]; then + echo "Bundling '$i'..." + cp "$i" "$appDir/usr/$i" + fi prevWasArrow=false fi From 7d7a25f2b07f902cf573856cca062b37881db799 Mon Sep 17 00:00:00 2001 From: Mohammad Amin Chitgarha Date: Tue, 5 Apr 2022 17:25:12 +0430 Subject: [PATCH 7/9] Make GitHub Actions CI workflow trigger on pushing tags Bump version to 0.3.2-rc.3. --- .github/workflows/ci.yml | 1 + src/Console/Application.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 004af94..1c3e79c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,6 +2,7 @@ name: CI on: push: + tags: "*" branches: - master - develop diff --git a/src/Console/Application.php b/src/Console/Application.php index 388df0f..155969e 100644 --- a/src/Console/Application.php +++ b/src/Console/Application.php @@ -7,7 +7,7 @@ class Application extends \Symfony\Component\Console\Application { public const NAME = "Parvaj"; - public const VERSION = "0.3.2-rc.2"; + public const VERSION = "0.3.2-rc.3"; public function __construct() { From c2a8bd2ce755b8fd40c3b8c8cd153945c964039b Mon Sep 17 00:00:00 2001 From: Mohammad Amin Chitgarha Date: Tue, 5 Apr 2022 17:37:17 +0430 Subject: [PATCH 8/9] Fix a missing ! is build.sh :(, bump version to 0.3.2.-rc.4 --- build-aux/appimage/build.sh | 2 +- src/Console/Application.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/build-aux/appimage/build.sh b/build-aux/appimage/build.sh index 25c37cf..f08e081 100755 --- a/build-aux/appimage/build.sh +++ b/build-aux/appimage/build.sh @@ -127,7 +127,7 @@ bundlePhpSharedLibraries() { # Reached the argument after an arrow, so bundle it if [[ "$prevWasArrow" = true ]]; then # Don't include libc and related libraries - if [[ "$i" =~ "lib(m|c|rt|dl|pthread).so" ]]; then + if ! [[ "$i" =~ "lib(m|c|rt|dl|pthread).so" ]]; then echo "Bundling '$i'..." cp "$i" "$appDir/usr/$i" fi diff --git a/src/Console/Application.php b/src/Console/Application.php index 155969e..c2b8f06 100644 --- a/src/Console/Application.php +++ b/src/Console/Application.php @@ -7,7 +7,7 @@ class Application extends \Symfony\Component\Console\Application { public const NAME = "Parvaj"; - public const VERSION = "0.3.2-rc.3"; + public const VERSION = "0.3.2-rc.4"; public function __construct() { From b2040438d1248306400e43c3105cbeaf0e505bc7 Mon Sep 17 00:00:00 2001 From: Mohammad Amin Chitgarha Date: Tue, 5 Apr 2022 17:51:19 +0430 Subject: [PATCH 9/9] Fix a regular expression in build.sh --- build-aux/appimage/build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build-aux/appimage/build.sh b/build-aux/appimage/build.sh index f08e081..9b603ab 100755 --- a/build-aux/appimage/build.sh +++ b/build-aux/appimage/build.sh @@ -127,7 +127,7 @@ bundlePhpSharedLibraries() { # Reached the argument after an arrow, so bundle it if [[ "$prevWasArrow" = true ]]; then # Don't include libc and related libraries - if ! [[ "$i" =~ "lib(m|c|rt|dl|pthread).so" ]]; then + if ! [[ "$i" =~ lib(m|c|rt|dl|pthread).so ]]; then echo "Bundling '$i'..." cp "$i" "$appDir/usr/$i" fi