Blame 0031-test_cc1541-Flatten-the-directory-tree.patch

8f581c5
From 22b01fefa879c3a7b1719e76a78df8adb1a8c8e0 Mon Sep 17 00:00:00 2001
8f581c5
From: =?UTF-8?q?Bj=C3=B6rn=20Esser?= <besser82@fedoraproject.org>
8f581c5
Date: Sun, 28 Jul 2019 14:56:54 +0200
8f581c5
Subject: [PATCH 31/36] test_cc1541: Flatten the directory tree.
8f581c5
8f581c5
There are just two source files in the whole tree, thus
8f581c5
it makes more sense to keep them in the same directory.
8f581c5
---
8f581c5
 .gitignore                                     |  4 ++--
8f581c5
 Makefile                                       | 18 +++++++++++-------
8f581c5
 bitbucket-pipelines.yml                        | 10 +++-------
8f581c5
 test_cc1541/test_cc1541.c => test_cc1541.c     |  0
8f581c5
 .../test_cc1541.vcxproj => test_cc1541.vcxproj |  0
8f581c5
 ...proj.filters => test_cc1541.vcxproj.filters |  0
8f581c5
 test_cc1541/Makefile                           | 13 -------------
8f581c5
 7 files changed, 16 insertions(+), 29 deletions(-)
8f581c5
 rename test_cc1541/test_cc1541.c => test_cc1541.c (100%)
8f581c5
 rename test_cc1541/test_cc1541.vcxproj => test_cc1541.vcxproj (100%)
8f581c5
 rename test_cc1541/test_cc1541.vcxproj.filters => test_cc1541.vcxproj.filters (100%)
8f581c5
 delete mode 100644 test_cc1541/Makefile
8f581c5
8f581c5
diff --git a/.gitignore b/.gitignore
8f581c5
index 331ebd7..3c55e78 100644
8f581c5
--- a/.gitignore
8f581c5
+++ b/.gitignore
8f581c5
@@ -7,5 +7,5 @@
8f581c5
 # Compiled applications.
8f581c5
 /cc1541
8f581c5
 /cc1541.exe
8f581c5
-test_cc1541/test_cc1541
8f581c5
-test_cc1541/test_cc1541.exe
8f581c5
+/test_cc1541
8f581c5
+/test_cc1541.exe
8f581c5
diff --git a/Makefile b/Makefile
8f581c5
index 4f1e13e..19cdde9 100644
8f581c5
--- a/Makefile
8f581c5
+++ b/Makefile
8f581c5
@@ -1,14 +1,18 @@
8f581c5
+all: cc1541
8f581c5
+
8f581c5
 cc1541: cc1541.o
8f581c5
 	$(CC) -o $@ $^ $(LDFLAGS)
8f581c5
 
8f581c5
-%.o: %.c
8f581c5
-	$(CC) -std=c99 $(CFLAGS) -c $<
8f581c5
+test_cc1541: test_cc1541.o
8f581c5
+	$(CC) -o $@ $^ $(LDFLAGS)
8f581c5
 
8f581c5
-test: cc1541
8f581c5
-	$(MAKE) -C test_cc1541/ test
8f581c5
+check: cc1541 test_cc1541
8f581c5
+	./test_cc1541 ./cc1541
8f581c5
 
8f581c5
-check: test
8f581c5
+test: check
8f581c5
 
8f581c5
 clean:
8f581c5
-	rm -rf *.o cc1541 *~
8f581c5
-	$(MAKE) -C test_cc1541/ clean
8f581c5
+	rm -rf *.o cc1541 test_cc1541 *~
8f581c5
+
8f581c5
+%.o: %.c
8f581c5
+	$(CC) -std=c99 $(CFLAGS) -c $<
8f581c5
diff --git a/bitbucket-pipelines.yml b/bitbucket-pipelines.yml
8f581c5
index 34cf4c8..4952a16 100644
8f581c5
--- a/bitbucket-pipelines.yml
8f581c5
+++ b/bitbucket-pipelines.yml
8f581c5
@@ -5,9 +5,7 @@ pipelines:
8f581c5
         image: alpine:3.7
8f581c5
         script:
8f581c5
           - apk add build-base
8f581c5
-          - make
8f581c5
-          - cd test_cc1541
8f581c5
-          - make test
8f581c5
+          - make check
8f581c5
         artifacts:
8f581c5
           - cc1541
8f581c5
     - step:
8f581c5
@@ -15,11 +13,9 @@ pipelines:
8f581c5
         image: purplekarrot/mingw-w64-i686
8f581c5
         trigger: manual
8f581c5
         script:
8f581c5
-          - make CC=i686-w64-mingw32-gcc
8f581c5
+          - make cc1541 test_cc1541 CC=i686-w64-mingw32-gcc
8f581c5
           - mv cc1541 cc1541.exe
8f581c5
-          - cd test_cc1541
8f581c5
-          - make CC=i686-w64-mingw32-gcc
8f581c5
           - mv test_cc1541 test_cc1541.exe
8f581c5
-          - wine test_cc1541.exe ../cc1541.exe
8f581c5
+          - wine ./test_cc1541.exe ./cc1541.exe
8f581c5
         artifacts:
8f581c5
           - cc1541.exe
8f581c5
diff --git a/test_cc1541/test_cc1541.c b/test_cc1541.c
8f581c5
similarity index 100%
8f581c5
rename from test_cc1541/test_cc1541.c
8f581c5
rename to test_cc1541.c
8f581c5
diff --git a/test_cc1541/test_cc1541.vcxproj b/test_cc1541.vcxproj
8f581c5
similarity index 100%
8f581c5
rename from test_cc1541/test_cc1541.vcxproj
8f581c5
rename to test_cc1541.vcxproj
8f581c5
diff --git a/test_cc1541/test_cc1541.vcxproj.filters b/test_cc1541.vcxproj.filters
8f581c5
similarity index 100%
8f581c5
rename from test_cc1541/test_cc1541.vcxproj.filters
8f581c5
rename to test_cc1541.vcxproj.filters
8f581c5
diff --git a/test_cc1541/Makefile b/test_cc1541/Makefile
8f581c5
deleted file mode 100644
8f581c5
index 59f3f8d..0000000
8f581c5
--- a/test_cc1541/Makefile
8f581c5
+++ /dev/null
8f581c5
@@ -1,13 +0,0 @@
8f581c5
-test_cc1541: test_cc1541.o
8f581c5
-	$(CC) -o $@ $^ $(LDFLAGS)
8f581c5
-
8f581c5
-%.o: %.c
8f581c5
-	$(CC) -std=c99 $(CFLAGS) -c $<
8f581c5
-
8f581c5
-test: test_cc1541
8f581c5
-	./test_cc1541 ../cc1541
8f581c5
-
8f581c5
-check: test
8f581c5
-
8f581c5
-clean:
8f581c5
-	rm -rf *.o test_cc1541 *~
8f581c5
-- 
8f581c5
2.21.0
8f581c5