From 5a53ea4a42b47eaffc0234c48c46a0980138b1ff Mon Sep 17 00:00:00 2001 From: Marcus Date: Wed, 20 Dec 2023 16:07:21 +0100 Subject: [PATCH 01/14] add case for DISTR=win --- .gitlab-ci-scripts/local-before-script.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitlab-ci-scripts/local-before-script.sh b/.gitlab-ci-scripts/local-before-script.sh index adb28e78..37a40d02 100755 --- a/.gitlab-ci-scripts/local-before-script.sh +++ b/.gitlab-ci-scripts/local-before-script.sh @@ -62,6 +62,8 @@ case ${DISTRO} in buster) make buster-debsource ;; esac ;; + win) # Do nothing for windows + ;; *) # We expect only RPM by default [ -d rpm ] || { echo "using freshly cloned and adapted rpm folder" From b7a0d164c67545d3e602dc102483701ae1f11256 Mon Sep 17 00:00:00 2001 From: Marcus Date: Wed, 20 Dec 2023 16:22:40 +0100 Subject: [PATCH 02/14] Add a find --- .gitlab-ci-scripts/local-before-script.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitlab-ci-scripts/local-before-script.sh b/.gitlab-ci-scripts/local-before-script.sh index 37a40d02..0486eed8 100755 --- a/.gitlab-ci-scripts/local-before-script.sh +++ b/.gitlab-ci-scripts/local-before-script.sh @@ -89,6 +89,9 @@ esac # Clean up rm -rf delme +echo "==============================[find]==============================" +find +echo "==============================[find]==============================" echo "======== oidc-agent-local-before-script done ========" From dd40a308aee950d9932015ec4e60977446e581a8 Mon Sep 17 00:00:00 2001 From: Marcus Date: Wed, 20 Dec 2023 16:24:42 +0100 Subject: [PATCH 03/14] retrigger ci --- .gitlab-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index e0b07499..2ad04d64 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -167,3 +167,4 @@ installer: branch: $TRIGGER_BRANCH strategy: depend + From 030a68c48f712b1e60ca05eff5ce9a71d29b9878 Mon Sep 17 00:00:00 2001 From: Marcus Date: Wed, 20 Dec 2023 16:37:48 +0100 Subject: [PATCH 04/14] Add debug output --- Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Makefile b/Makefile index 5abfd460..12965ff7 100644 --- a/Makefile +++ b/Makefile @@ -438,6 +438,9 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c set -e ;\ depFileName=$(OBJDIR)/$*.d ;\ $(CC) -MM $(CFLAGS) $< -o $${depFileName} $(DEFINE_USE_CJSON_SO) $(DEFINE_USE_LIST_SO) $(DEFINE_USE_MUSTACHE_SO) ;\ + ls -la obj/oidc-agent ;\ + ls -la `dirname $${depFileName}`;\ + echo "mv -f $${depFileName} $${depFileName}.tmp" ;\ mv -f $${depFileName} $${depFileName}.tmp ;\ sed -e 's|.*:|$@:|' < $${depFileName}.tmp > $${depFileName} ;\ cp -f $${depFileName} $${depFileName}.tmp ;\ From c7e01889514f8f7bf6c73e8fe8047df3597ef4a3 Mon Sep 17 00:00:00 2001 From: Marcus Date: Thu, 21 Dec 2023 12:32:00 +0100 Subject: [PATCH 05/14] remove debug --- Makefile | 3 --- 1 file changed, 3 deletions(-) diff --git a/Makefile b/Makefile index 12965ff7..5abfd460 100644 --- a/Makefile +++ b/Makefile @@ -438,9 +438,6 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c set -e ;\ depFileName=$(OBJDIR)/$*.d ;\ $(CC) -MM $(CFLAGS) $< -o $${depFileName} $(DEFINE_USE_CJSON_SO) $(DEFINE_USE_LIST_SO) $(DEFINE_USE_MUSTACHE_SO) ;\ - ls -la obj/oidc-agent ;\ - ls -la `dirname $${depFileName}`;\ - echo "mv -f $${depFileName} $${depFileName}.tmp" ;\ mv -f $${depFileName} $${depFileName}.tmp ;\ sed -e 's|.*:|$@:|' < $${depFileName}.tmp > $${depFileName} ;\ cp -f $${depFileName} $${depFileName}.tmp ;\ From 7eac5d315608aacd1050b40c197109ae90148e31 Mon Sep 17 00:00:00 2001 From: Marcus Date: Thu, 21 Dec 2023 12:36:25 +0100 Subject: [PATCH 06/14] try with less debug --- Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Makefile b/Makefile index 5abfd460..bd9a86b7 100644 --- a/Makefile +++ b/Makefile @@ -438,6 +438,9 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c set -e ;\ depFileName=$(OBJDIR)/$*.d ;\ $(CC) -MM $(CFLAGS) $< -o $${depFileName} $(DEFINE_USE_CJSON_SO) $(DEFINE_USE_LIST_SO) $(DEFINE_USE_MUSTACHE_SO) ;\ + echo "Dirname: `dirname $${depFileName}`";\ + ls -la `dirname $${depFileName}`;\ + echo "mv -f $${depFileName} $${depFileName}.tmp" ;\ mv -f $${depFileName} $${depFileName}.tmp ;\ sed -e 's|.*:|$@:|' < $${depFileName}.tmp > $${depFileName} ;\ cp -f $${depFileName} $${depFileName}.tmp ;\ From aaaa0af1ae1e716fc0b90cfc832e6a9b76822496 Mon Sep 17 00:00:00 2001 From: Marcus Date: Thu, 21 Dec 2023 12:46:11 +0100 Subject: [PATCH 07/14] Add sleep 0.2 --- Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/Makefile b/Makefile index bd9a86b7..4d161cea 100644 --- a/Makefile +++ b/Makefile @@ -441,6 +441,7 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c echo "Dirname: `dirname $${depFileName}`";\ ls -la `dirname $${depFileName}`;\ echo "mv -f $${depFileName} $${depFileName}.tmp" ;\ + sleep 0.2;\ mv -f $${depFileName} $${depFileName}.tmp ;\ sed -e 's|.*:|$@:|' < $${depFileName}.tmp > $${depFileName} ;\ cp -f $${depFileName} $${depFileName}.tmp ;\ From 535026ac7b08a939fe13d38b1aa00be29f90cf3a Mon Sep 17 00:00:00 2001 From: Marcus Date: Thu, 21 Dec 2023 13:31:53 +0100 Subject: [PATCH 08/14] Add debug with lots of ls --- Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Makefile b/Makefile index 4d161cea..a378cf11 100644 --- a/Makefile +++ b/Makefile @@ -438,6 +438,8 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c set -e ;\ depFileName=$(OBJDIR)/$*.d ;\ $(CC) -MM $(CFLAGS) $< -o $${depFileName} $(DEFINE_USE_CJSON_SO) $(DEFINE_USE_LIST_SO) $(DEFINE_USE_MUSTACHE_SO) ;\ + echo "obj-dir: obj/oidc-agent";\ + ls -la obj/oidc-agent ;\ echo "Dirname: `dirname $${depFileName}`";\ ls -la `dirname $${depFileName}`;\ echo "mv -f $${depFileName} $${depFileName}.tmp" ;\ From 201897727f1e01f72c776af77514001e29037e61 Mon Sep 17 00:00:00 2001 From: Marcus Date: Thu, 21 Dec 2023 14:23:59 +0100 Subject: [PATCH 09/14] Replace ls with longer sleep (1.2s) --- Makefile | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/Makefile b/Makefile index a378cf11..08060ef8 100644 --- a/Makefile +++ b/Makefile @@ -438,12 +438,7 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c set -e ;\ depFileName=$(OBJDIR)/$*.d ;\ $(CC) -MM $(CFLAGS) $< -o $${depFileName} $(DEFINE_USE_CJSON_SO) $(DEFINE_USE_LIST_SO) $(DEFINE_USE_MUSTACHE_SO) ;\ - echo "obj-dir: obj/oidc-agent";\ - ls -la obj/oidc-agent ;\ - echo "Dirname: `dirname $${depFileName}`";\ - ls -la `dirname $${depFileName}`;\ - echo "mv -f $${depFileName} $${depFileName}.tmp" ;\ - sleep 0.2;\ + sleep 1.2;\ mv -f $${depFileName} $${depFileName}.tmp ;\ sed -e 's|.*:|$@:|' < $${depFileName}.tmp > $${depFileName} ;\ cp -f $${depFileName} $${depFileName}.tmp ;\ From d266c7e5ac78945c8585c1ceab87a092540b084e Mon Sep 17 00:00:00 2001 From: Marcus Date: Thu, 21 Dec 2023 14:58:17 +0100 Subject: [PATCH 10/14] Make heisenbugworkaround windows-conditional --- Makefile | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 08060ef8..09e3946c 100644 --- a/Makefile +++ b/Makefile @@ -438,7 +438,15 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c set -e ;\ depFileName=$(OBJDIR)/$*.d ;\ $(CC) -MM $(CFLAGS) $< -o $${depFileName} $(DEFINE_USE_CJSON_SO) $(DEFINE_USE_LIST_SO) $(DEFINE_USE_MUSTACHE_SO) ;\ - sleep 1.2;\ + TEST="${MINGW}${MSYS}" + [ -z ${TEST} ] || {\ + echo "obj-dir: obj/oidc-agent";\ + ls -la obj/oidc-agent ;\ + echo "Dirname: `dirname $${depFileName}`";\ + ls -la `dirname $${depFileName}`;\ + echo "mv -f $${depFileName} $${depFileName}.tmp" ;\ + sleep 1.5;\ + } mv -f $${depFileName} $${depFileName}.tmp ;\ sed -e 's|.*:|$@:|' < $${depFileName}.tmp > $${depFileName} ;\ cp -f $${depFileName} $${depFileName}.tmp ;\ From cda36b91cd5a3541fc9ada4cc33dc2e5c2a789b8 Mon Sep 17 00:00:00 2001 From: Marcus Date: Thu, 21 Dec 2023 15:00:51 +0100 Subject: [PATCH 11/14] Fix missing backslash --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 09e3946c..4969be04 100644 --- a/Makefile +++ b/Makefile @@ -446,7 +446,7 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c ls -la `dirname $${depFileName}`;\ echo "mv -f $${depFileName} $${depFileName}.tmp" ;\ sleep 1.5;\ - } + }\ mv -f $${depFileName} $${depFileName}.tmp ;\ sed -e 's|.*:|$@:|' < $${depFileName}.tmp > $${depFileName} ;\ cp -f $${depFileName} $${depFileName}.tmp ;\ From f4e528303c4861746f887c394994537f7aaff788 Mon Sep 17 00:00:00 2001 From: Marcus Date: Thu, 21 Dec 2023 15:13:57 +0100 Subject: [PATCH 12/14] Should work now --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 4969be04..68928446 100644 --- a/Makefile +++ b/Makefile @@ -438,7 +438,7 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c set -e ;\ depFileName=$(OBJDIR)/$*.d ;\ $(CC) -MM $(CFLAGS) $< -o $${depFileName} $(DEFINE_USE_CJSON_SO) $(DEFINE_USE_LIST_SO) $(DEFINE_USE_MUSTACHE_SO) ;\ - TEST="${MINGW}${MSYS}" + TEST="${MINGW}${MSYS}";\ [ -z ${TEST} ] || {\ echo "obj-dir: obj/oidc-agent";\ ls -la obj/oidc-agent ;\ @@ -446,7 +446,7 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c ls -la `dirname $${depFileName}`;\ echo "mv -f $${depFileName} $${depFileName}.tmp" ;\ sleep 1.5;\ - }\ + };\ mv -f $${depFileName} $${depFileName}.tmp ;\ sed -e 's|.*:|$@:|' < $${depFileName}.tmp > $${depFileName} ;\ cp -f $${depFileName} $${depFileName}.tmp ;\ From 24e8464df70c5442eaca72fb559fd4f62adcbdcb Mon Sep 17 00:00:00 2001 From: Marcus Date: Thu, 21 Dec 2023 15:24:30 +0100 Subject: [PATCH 13/14] More delay and more silent output --- Makefile | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 68928446..3ed09d4c 100644 --- a/Makefile +++ b/Makefile @@ -440,12 +440,10 @@ $(OBJDIR)/%.o : $(SRCDIR)/%.c $(CC) -MM $(CFLAGS) $< -o $${depFileName} $(DEFINE_USE_CJSON_SO) $(DEFINE_USE_LIST_SO) $(DEFINE_USE_MUSTACHE_SO) ;\ TEST="${MINGW}${MSYS}";\ [ -z ${TEST} ] || {\ - echo "obj-dir: obj/oidc-agent";\ - ls -la obj/oidc-agent ;\ - echo "Dirname: `dirname $${depFileName}`";\ - ls -la `dirname $${depFileName}`;\ + ls -la obj/oidc-agent > /dev/null ;\ + ls -la `dirname $${depFileName}` > /dev/null;\ echo "mv -f $${depFileName} $${depFileName}.tmp" ;\ - sleep 1.5;\ + sleep 2.5;\ };\ mv -f $${depFileName} $${depFileName}.tmp ;\ sed -e 's|.*:|$@:|' < $${depFileName}.tmp > $${depFileName} ;\ From 800d5ad8d153b979ec52b893f8ec26745be8477d Mon Sep 17 00:00:00 2001 From: Marcus Date: Thu, 21 Dec 2023 15:37:06 +0100 Subject: [PATCH 14/14] remove debug code --- .gitlab-ci-scripts/local-before-script.sh | 3 --- .gitlab-ci.yml | 1 - 2 files changed, 4 deletions(-) diff --git a/.gitlab-ci-scripts/local-before-script.sh b/.gitlab-ci-scripts/local-before-script.sh index 0486eed8..37a40d02 100755 --- a/.gitlab-ci-scripts/local-before-script.sh +++ b/.gitlab-ci-scripts/local-before-script.sh @@ -89,9 +89,6 @@ esac # Clean up rm -rf delme -echo "==============================[find]==============================" -find -echo "==============================[find]==============================" echo "======== oidc-agent-local-before-script done ========" diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2ad04d64..e0b07499 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -167,4 +167,3 @@ installer: branch: $TRIGGER_BRANCH strategy: depend -