From 463ee6163dc5d71088d390300715431de22f1e2d Mon Sep 17 00:00:00 2001 From: Mushfiqur Rahman Abir <28858998+Abir-Tx@users.noreply.github.com> Date: Thu, 22 Apr 2021 02:53:25 +0600 Subject: [PATCH 1/8] Upgrade the project to use cmake build tools - git ignore updated to untrack cmake generated files - CMakeLists creates - vs code cpp_properties changed by cmake ext --- .gitignore | 19 ++++++++++++++++++- .vscode/c_cpp_properties.json | 5 ++--- CMakeLists.txt | 13 +++++++++++++ 3 files changed, 33 insertions(+), 4 deletions(-) create mode 100644 CMakeLists.txt diff --git a/.gitignore b/.gitignore index 561229e..06f3386 100755 --- a/.gitignore +++ b/.gitignore @@ -37,4 +37,21 @@ bin/* passphrase.bin s_lockValue.bin -release-configs/* \ No newline at end of file +release-configs/* + +### CMake ### +CMakeLists.txt.user +CMakeCache.txt +CMakeFiles +CMakeScripts +Testing +cmake_install.cmake +install_manifest.txt +compile_commands.json +CTestTestfile.cmake +_deps +CMakeUserPresets.json +build/* +### CMake Patch ### +# External projects +*-prefix/ \ No newline at end of file diff --git a/.vscode/c_cpp_properties.json b/.vscode/c_cpp_properties.json index 572ba24..373b167 100644 --- a/.vscode/c_cpp_properties.json +++ b/.vscode/c_cpp_properties.json @@ -21,13 +21,13 @@ "${workspaceFolder}/include/ffmpeg-coder/**", "${workspaceFolder}/include/**", "${workspaceFolder}/lib" - ], "defines": [], "compilerPath": "C:\\MinGW\\bin\\gcc.exe", "cStandard": "${default}", "cppStandard": "c++14", - "intelliSenseMode": "${default}" + "intelliSenseMode": "${default}", + "configurationProvider": "ms-vscode.cmake-tools" }, { "name": "Surface", @@ -36,7 +36,6 @@ "${workspaceFolder}/include/ffmpeg-coder/**", "${workspaceFolder}/include/**", "${workspaceFolder}/lib" - ], "defines": [], "compilerPath": "C:\\Program Files (x86)\\mingw-w64\\i686-8.1.0-posix-dwarf-rt_v6-rev0\\mingw32\\bin\\gcc.exe", diff --git a/CMakeLists.txt b/CMakeLists.txt new file mode 100644 index 0000000..0783e05 --- /dev/null +++ b/CMakeLists.txt @@ -0,0 +1,13 @@ +cmake_minimum_required(VERSION 3.12) +project(ffmpeg-coder VERSION 1.0.0) +message("FFMPEG CODER BUILD PROCESS") +message("--------------------------") + + +include_directories(include/ffmpeg-coder lib) + + + + +add_executable(ffmpeg-coder src/ffmpeg-coder.cpp) + From 9819a945279d0fc757ff609ab2472266e5087724 Mon Sep 17 00:00:00 2001 From: Mushfiqur Rahman Abir <28858998+Abir-Tx@users.noreply.github.com> Date: Thu, 22 Apr 2021 02:54:07 +0600 Subject: [PATCH 2/8] Change #ifndef dec from H to HPP --- include/ffmpeg-coder/ffmpeg_coder.hpp | 7 +++++-- include/ffmpeg-coder/frontend_funcs.hpp | 6 +++--- include/ffmpeg-coder/s_lock.hpp | 4 ++-- include/ffmpeg-coder/utils.hpp | 4 ++-- 4 files changed, 12 insertions(+), 9 deletions(-) diff --git a/include/ffmpeg-coder/ffmpeg_coder.hpp b/include/ffmpeg-coder/ffmpeg_coder.hpp index 250b56d..9589e52 100644 --- a/include/ffmpeg-coder/ffmpeg_coder.hpp +++ b/include/ffmpeg-coder/ffmpeg_coder.hpp @@ -1,5 +1,5 @@ -#if !defined(FFMPEG_CODER_H) -#define FFMPEG_CODER_H +#if !defined(FFMPEG_CODER_HPP) +#define FFMPEG_CODER_HPP #include "utils.hpp" #include @@ -330,6 +330,9 @@ class ffmpeg { } } } + +// Quick convert function + void quickConvert(){}; }; ffmpeg::ffmpeg() {} diff --git a/include/ffmpeg-coder/frontend_funcs.hpp b/include/ffmpeg-coder/frontend_funcs.hpp index b3816f2..5a2ef51 100644 --- a/include/ffmpeg-coder/frontend_funcs.hpp +++ b/include/ffmpeg-coder/frontend_funcs.hpp @@ -1,5 +1,5 @@ -#if !defined(FRONTEND_FUNC_H) -#define FRONTEND_FUNC_H +#if !defined(FRONTEND_FUNC_HPP) +#define FRONTEND_FUNC_HPP #include "rang.hpp" #include @@ -108,7 +108,7 @@ void homepage() ffmpeg.selected_action(); } else if (choice == 2){ - cout << "Work in progress !!" << endl; + ffmpeg.quickConvert(); } else if (choice == 3) { diff --git a/include/ffmpeg-coder/s_lock.hpp b/include/ffmpeg-coder/s_lock.hpp index c57801a..28e137d 100644 --- a/include/ffmpeg-coder/s_lock.hpp +++ b/include/ffmpeg-coder/s_lock.hpp @@ -1,5 +1,5 @@ -#if !defined(S_LOCK_H) -#define S_LOCK_H +#if !defined(S_LOCK_HPP) +#define S_LOCK_HPP #include "rang.hpp" #include diff --git a/include/ffmpeg-coder/utils.hpp b/include/ffmpeg-coder/utils.hpp index 2f4318b..5981a09 100644 --- a/include/ffmpeg-coder/utils.hpp +++ b/include/ffmpeg-coder/utils.hpp @@ -1,5 +1,5 @@ -#if !defined(UTILS_H) -#define UTILS_H +#if !defined(UTILS_HPP) +#define UTILS_HPP #include "rang.hpp" #include From 2d41780e3e56443938db459f6e557a618dc01f09 Mon Sep 17 00:00:00 2001 From: Mushfiqur Rahman Abir <28858998+Abir-Tx@users.noreply.github.com> Date: Thu, 22 Apr 2021 03:25:19 +0600 Subject: [PATCH 3/8] Update bin dir in cmake Rename my own Makefile to Makefile.own to use both makefiles --- CMakeLists.txt | 4 +- Makefile | 220 ++++++++++++++++++++++++++++++++++++++----------- Makefile.own | 56 +++++++++++++ 3 files changed, 232 insertions(+), 48 deletions(-) create mode 100644 Makefile.own diff --git a/CMakeLists.txt b/CMakeLists.txt index 0783e05..2be9949 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,9 +3,11 @@ project(ffmpeg-coder VERSION 1.0.0) message("FFMPEG CODER BUILD PROCESS") message("--------------------------") - +set(CMAKE_CXX_FLAGS "-Wall -v") include_directories(include/ffmpeg-coder lib) +# Placing the executable in the bin dir +set(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/Makefile b/Makefile index ddc6fd1..5c4fbbe 100644 --- a/Makefile +++ b/Makefile @@ -1,54 +1,180 @@ -# make script for the ffmpeg-coder project to build the project from source code -# By Abir-Tx +# CMAKE generated file: DO NOT EDIT! +# Generated by "MinGW Makefiles" Generator, CMake Version 3.20 +# Default target executed when no arguments are given to make. +default_target: all +.PHONY : default_target -# variables -CC := g++ -SRCDIR := src -BUILDDIR := bin -CFLAG := -v -INC := -I include/ffmpeg-coder -I lib -APPNAME := ffmpeg-coder +# Allow only one "make -f Makefile2" at a time, but pass parallelism. +.NOTPARALLEL: -.PHONY: all +#============================================================================= +# Special targets provided by cmake. -all: build run +# Disable implicit rules so canonical targets will work. +.SUFFIXES: -.PHONY: build -build: - ${CC} ${CFLAG} ${SRCDIR}/${APPNAME}.cpp ${INC} -o ${BUILDDIR}/${APPNAME}.o +# Disable VCS-based implicit rules. +% : %,v -.PHONY: clean +# Disable VCS-based implicit rules. +% : RCS/% + +# Disable VCS-based implicit rules. +% : RCS/%,v + +# Disable VCS-based implicit rules. +% : SCCS/s.% + +# Disable VCS-based implicit rules. +% : s.% + +.SUFFIXES: .hpux_make_needs_suffix_list + +# Command-line flag to silence nested $(MAKE). +$(VERBOSE)MAKESILENT = -s + +#Suppress display of executed commands. +$(VERBOSE).SILENT: + +# A target that is always out of date. +cmake_force: +.PHONY : cmake_force + +#============================================================================= +# Set environment variables for the build. + +SHELL = cmd.exe + +# The CMake executable. +CMAKE_COMMAND = "C:\Program Files\CMake\bin\cmake.exe" + +# The command to remove a file. +RM = "C:\Program Files\CMake\bin\cmake.exe" -E rm -f + +# Escaping for special characters. +EQUALS = = + +# The top-level source directory on which CMake was run. +CMAKE_SOURCE_DIR = C:\Users\abir_\code\github\ffmpeg-coder + +# The top-level build directory on which CMake was run. +CMAKE_BINARY_DIR = C:\Users\abir_\code\github\ffmpeg-coder + +#============================================================================= +# Targets provided globally by CMake. + +# Special rule for the target edit_cache +edit_cache: + @$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake cache editor..." + "C:\Program Files\CMake\bin\cmake-gui.exe" -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) +.PHONY : edit_cache + +# Special rule for the target edit_cache +edit_cache/fast: edit_cache +.PHONY : edit_cache/fast + +# Special rule for the target rebuild_cache +rebuild_cache: + @$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake to regenerate build system..." + "C:\Program Files\CMake\bin\cmake.exe" --regenerate-during-build -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) +.PHONY : rebuild_cache + +# Special rule for the target rebuild_cache +rebuild_cache/fast: rebuild_cache +.PHONY : rebuild_cache/fast + +# The main all target +all: cmake_check_build_system + $(CMAKE_COMMAND) -E cmake_progress_start C:\Users\abir_\code\github\ffmpeg-coder\CMakeFiles C:\Users\abir_\code\github\ffmpeg-coder\\CMakeFiles\progress.marks + $(MAKE) $(MAKESILENT) -f CMakeFiles\Makefile2 all + $(CMAKE_COMMAND) -E cmake_progress_start C:\Users\abir_\code\github\ffmpeg-coder\CMakeFiles 0 +.PHONY : all + +# The main clean target clean: - echo Deleting the binaries.... - rm ${BUILDDIR}/* - rm ffmpeg-coder/usr/bin/ffmpeg-coder - -.PHONY: run -run: - echo Running the built program.... - ./${BUILDDIR}/${APPNAME}.o - -.PHONY: dir -dir: - echo Creating directories..... - mkdir bin - -.PHONY: debpackage -debpackage: build - echo Creating the debian package of ffmpeg-coder - mv bin/ffmpeg-coder.o bin/ffmpeg-coder - cp bin/ffmpeg-coder ffmpeg-coder/usr/bin/ - fakeroot dpkg-deb -v --build ffmpeg-coder bin - echo The deb package has been created in the bin folder - - -# Windows Configs for make -.PHONY: winbuild -winbuild: - ${CC} ${CFLAG} ${SRCDIR}/${APPNAME}.cpp ${INC} -o ${BUILDDIR}/${APPNAME}.exe - -.PHONY: winrun -winrun: - echo Running the built program.... - ./${BUILDDIR}/${APPNAME}.exe + $(MAKE) $(MAKESILENT) -f CMakeFiles\Makefile2 clean +.PHONY : clean + +# The main clean target +clean/fast: clean +.PHONY : clean/fast + +# Prepare targets for installation. +preinstall: all + $(MAKE) $(MAKESILENT) -f CMakeFiles\Makefile2 preinstall +.PHONY : preinstall + +# Prepare targets for installation. +preinstall/fast: + $(MAKE) $(MAKESILENT) -f CMakeFiles\Makefile2 preinstall +.PHONY : preinstall/fast + +# clear depends +depend: + $(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles\Makefile.cmake 1 +.PHONY : depend + +#============================================================================= +# Target rules for targets named ffmpeg-coder + +# Build rule for target. +ffmpeg-coder: cmake_check_build_system + $(MAKE) $(MAKESILENT) -f CMakeFiles\Makefile2 ffmpeg-coder +.PHONY : ffmpeg-coder + +# fast build rule for target. +ffmpeg-coder/fast: + $(MAKE) $(MAKESILENT) -f CMakeFiles\ffmpeg-coder.dir\build.make CMakeFiles/ffmpeg-coder.dir/build +.PHONY : ffmpeg-coder/fast + +src/ffmpeg-coder.obj: src/ffmpeg-coder.cpp.obj +.PHONY : src/ffmpeg-coder.obj + +# target to build an object file +src/ffmpeg-coder.cpp.obj: + $(MAKE) $(MAKESILENT) -f CMakeFiles\ffmpeg-coder.dir\build.make CMakeFiles/ffmpeg-coder.dir/src/ffmpeg-coder.cpp.obj +.PHONY : src/ffmpeg-coder.cpp.obj + +src/ffmpeg-coder.i: src/ffmpeg-coder.cpp.i +.PHONY : src/ffmpeg-coder.i + +# target to preprocess a source file +src/ffmpeg-coder.cpp.i: + $(MAKE) $(MAKESILENT) -f CMakeFiles\ffmpeg-coder.dir\build.make CMakeFiles/ffmpeg-coder.dir/src/ffmpeg-coder.cpp.i +.PHONY : src/ffmpeg-coder.cpp.i + +src/ffmpeg-coder.s: src/ffmpeg-coder.cpp.s +.PHONY : src/ffmpeg-coder.s + +# target to generate assembly for a file +src/ffmpeg-coder.cpp.s: + $(MAKE) $(MAKESILENT) -f CMakeFiles\ffmpeg-coder.dir\build.make CMakeFiles/ffmpeg-coder.dir/src/ffmpeg-coder.cpp.s +.PHONY : src/ffmpeg-coder.cpp.s + +# Help Target +help: + @echo The following are some of the valid targets for this Makefile: + @echo ... all (the default if no target is provided) + @echo ... clean + @echo ... depend + @echo ... edit_cache + @echo ... rebuild_cache + @echo ... ffmpeg-coder + @echo ... src/ffmpeg-coder.obj + @echo ... src/ffmpeg-coder.i + @echo ... src/ffmpeg-coder.s +.PHONY : help + + + +#============================================================================= +# Special targets to cleanup operation of make. + +# Special rule to run CMake to check the build system integrity. +# No rule that depends on this can have commands that come from listfiles +# because they might be regenerated. +cmake_check_build_system: + $(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles\Makefile.cmake 0 +.PHONY : cmake_check_build_system + diff --git a/Makefile.own b/Makefile.own new file mode 100644 index 0000000..a2ded7f --- /dev/null +++ b/Makefile.own @@ -0,0 +1,56 @@ +# make script for the ffmpeg-coder project to build the project from source code +# By Abir-Tx +# Use make -f Makefile.own winbuild to use this file + + +# variables +CC := g++ +SRCDIR := src +BUILDDIR := bin +CFLAG := -v +INC := -I include/ffmpeg-coder -I lib +APPNAME := ffmpeg-coder + +.PHONY: all + +all: build run + +.PHONY: build +build: + ${CC} ${CFLAG} ${SRCDIR}/${APPNAME}.cpp ${INC} -o ${BUILDDIR}/${APPNAME}.o + +.PHONY: clean +clean: + echo Deleting the binaries.... + rm ${BUILDDIR}/* + rm ffmpeg-coder/usr/bin/ffmpeg-coder + +.PHONY: run +run: + echo Running the built program.... + ./${BUILDDIR}/${APPNAME}.o + +.PHONY: dir +dir: + echo Creating directories..... + mkdir bin + mkdir build + +.PHONY: debpackage +debpackage: build + echo Creating the debian package of ffmpeg-coder + mv bin/ffmpeg-coder.o bin/ffmpeg-coder + cp bin/ffmpeg-coder ffmpeg-coder/usr/bin/ + fakeroot dpkg-deb -v --build ffmpeg-coder bin + echo The deb package has been created in the bin folder + + +# Windows Configs for make +.PHONY: winbuild +winbuild: + ${CC} ${CFLAG} ${SRCDIR}/${APPNAME}.cpp ${INC} -o ${BUILDDIR}/${APPNAME}.exe + +.PHONY: winrun +winrun: + echo Running the built program.... + ./${BUILDDIR}/${APPNAME}.exe From 0d6b35c2356fb324b22cd36754cd93c35f3e7a01 Mon Sep 17 00:00:00 2001 From: Mushfiqur Rahman Abir <28858998+Abir-Tx@users.noreply.github.com> Date: Thu, 22 Apr 2021 03:34:10 +0600 Subject: [PATCH 4/8] Remove cmake generated Makefile from git tracking --- .gitignore | 1 + Makefile | 180 ----------------------------------------------------- 2 files changed, 1 insertion(+), 180 deletions(-) delete mode 100644 Makefile diff --git a/.gitignore b/.gitignore index 06f3386..e99d69a 100755 --- a/.gitignore +++ b/.gitignore @@ -45,6 +45,7 @@ CMakeCache.txt CMakeFiles CMakeScripts Testing +Makefile cmake_install.cmake install_manifest.txt compile_commands.json diff --git a/Makefile b/Makefile deleted file mode 100644 index 5c4fbbe..0000000 --- a/Makefile +++ /dev/null @@ -1,180 +0,0 @@ -# CMAKE generated file: DO NOT EDIT! -# Generated by "MinGW Makefiles" Generator, CMake Version 3.20 - -# Default target executed when no arguments are given to make. -default_target: all -.PHONY : default_target - -# Allow only one "make -f Makefile2" at a time, but pass parallelism. -.NOTPARALLEL: - -#============================================================================= -# Special targets provided by cmake. - -# Disable implicit rules so canonical targets will work. -.SUFFIXES: - -# Disable VCS-based implicit rules. -% : %,v - -# Disable VCS-based implicit rules. -% : RCS/% - -# Disable VCS-based implicit rules. -% : RCS/%,v - -# Disable VCS-based implicit rules. -% : SCCS/s.% - -# Disable VCS-based implicit rules. -% : s.% - -.SUFFIXES: .hpux_make_needs_suffix_list - -# Command-line flag to silence nested $(MAKE). -$(VERBOSE)MAKESILENT = -s - -#Suppress display of executed commands. -$(VERBOSE).SILENT: - -# A target that is always out of date. -cmake_force: -.PHONY : cmake_force - -#============================================================================= -# Set environment variables for the build. - -SHELL = cmd.exe - -# The CMake executable. -CMAKE_COMMAND = "C:\Program Files\CMake\bin\cmake.exe" - -# The command to remove a file. -RM = "C:\Program Files\CMake\bin\cmake.exe" -E rm -f - -# Escaping for special characters. -EQUALS = = - -# The top-level source directory on which CMake was run. -CMAKE_SOURCE_DIR = C:\Users\abir_\code\github\ffmpeg-coder - -# The top-level build directory on which CMake was run. -CMAKE_BINARY_DIR = C:\Users\abir_\code\github\ffmpeg-coder - -#============================================================================= -# Targets provided globally by CMake. - -# Special rule for the target edit_cache -edit_cache: - @$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake cache editor..." - "C:\Program Files\CMake\bin\cmake-gui.exe" -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) -.PHONY : edit_cache - -# Special rule for the target edit_cache -edit_cache/fast: edit_cache -.PHONY : edit_cache/fast - -# Special rule for the target rebuild_cache -rebuild_cache: - @$(CMAKE_COMMAND) -E cmake_echo_color --switch=$(COLOR) --cyan "Running CMake to regenerate build system..." - "C:\Program Files\CMake\bin\cmake.exe" --regenerate-during-build -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) -.PHONY : rebuild_cache - -# Special rule for the target rebuild_cache -rebuild_cache/fast: rebuild_cache -.PHONY : rebuild_cache/fast - -# The main all target -all: cmake_check_build_system - $(CMAKE_COMMAND) -E cmake_progress_start C:\Users\abir_\code\github\ffmpeg-coder\CMakeFiles C:\Users\abir_\code\github\ffmpeg-coder\\CMakeFiles\progress.marks - $(MAKE) $(MAKESILENT) -f CMakeFiles\Makefile2 all - $(CMAKE_COMMAND) -E cmake_progress_start C:\Users\abir_\code\github\ffmpeg-coder\CMakeFiles 0 -.PHONY : all - -# The main clean target -clean: - $(MAKE) $(MAKESILENT) -f CMakeFiles\Makefile2 clean -.PHONY : clean - -# The main clean target -clean/fast: clean -.PHONY : clean/fast - -# Prepare targets for installation. -preinstall: all - $(MAKE) $(MAKESILENT) -f CMakeFiles\Makefile2 preinstall -.PHONY : preinstall - -# Prepare targets for installation. -preinstall/fast: - $(MAKE) $(MAKESILENT) -f CMakeFiles\Makefile2 preinstall -.PHONY : preinstall/fast - -# clear depends -depend: - $(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles\Makefile.cmake 1 -.PHONY : depend - -#============================================================================= -# Target rules for targets named ffmpeg-coder - -# Build rule for target. -ffmpeg-coder: cmake_check_build_system - $(MAKE) $(MAKESILENT) -f CMakeFiles\Makefile2 ffmpeg-coder -.PHONY : ffmpeg-coder - -# fast build rule for target. -ffmpeg-coder/fast: - $(MAKE) $(MAKESILENT) -f CMakeFiles\ffmpeg-coder.dir\build.make CMakeFiles/ffmpeg-coder.dir/build -.PHONY : ffmpeg-coder/fast - -src/ffmpeg-coder.obj: src/ffmpeg-coder.cpp.obj -.PHONY : src/ffmpeg-coder.obj - -# target to build an object file -src/ffmpeg-coder.cpp.obj: - $(MAKE) $(MAKESILENT) -f CMakeFiles\ffmpeg-coder.dir\build.make CMakeFiles/ffmpeg-coder.dir/src/ffmpeg-coder.cpp.obj -.PHONY : src/ffmpeg-coder.cpp.obj - -src/ffmpeg-coder.i: src/ffmpeg-coder.cpp.i -.PHONY : src/ffmpeg-coder.i - -# target to preprocess a source file -src/ffmpeg-coder.cpp.i: - $(MAKE) $(MAKESILENT) -f CMakeFiles\ffmpeg-coder.dir\build.make CMakeFiles/ffmpeg-coder.dir/src/ffmpeg-coder.cpp.i -.PHONY : src/ffmpeg-coder.cpp.i - -src/ffmpeg-coder.s: src/ffmpeg-coder.cpp.s -.PHONY : src/ffmpeg-coder.s - -# target to generate assembly for a file -src/ffmpeg-coder.cpp.s: - $(MAKE) $(MAKESILENT) -f CMakeFiles\ffmpeg-coder.dir\build.make CMakeFiles/ffmpeg-coder.dir/src/ffmpeg-coder.cpp.s -.PHONY : src/ffmpeg-coder.cpp.s - -# Help Target -help: - @echo The following are some of the valid targets for this Makefile: - @echo ... all (the default if no target is provided) - @echo ... clean - @echo ... depend - @echo ... edit_cache - @echo ... rebuild_cache - @echo ... ffmpeg-coder - @echo ... src/ffmpeg-coder.obj - @echo ... src/ffmpeg-coder.i - @echo ... src/ffmpeg-coder.s -.PHONY : help - - - -#============================================================================= -# Special targets to cleanup operation of make. - -# Special rule to run CMake to check the build system integrity. -# No rule that depends on this can have commands that come from listfiles -# because they might be regenerated. -cmake_check_build_system: - $(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles\Makefile.cmake 0 -.PHONY : cmake_check_build_system - From 203a17237bf339e1def8d7abf9dd0205e41fdb40 Mon Sep 17 00:00:00 2001 From: Mushfiqur Rahman Abir <28858998+Abir-Tx@users.noreply.github.com> Date: Thu, 22 Apr 2021 03:43:10 +0600 Subject: [PATCH 5/8] Fix CI According to new makefile fix the ci --- .github/workflows/c-cpp.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml index 4cc41b6..97dae04 100644 --- a/.github/workflows/c-cpp.yml +++ b/.github/workflows/c-cpp.yml @@ -1,4 +1,4 @@ -name: C/C++ CI +name: C/C++ Build CI on: push: @@ -13,11 +13,11 @@ jobs: steps: - uses: actions/checkout@v2 - name: make-dir - run: make dir + run: make -f Makefile.own dir - name: linux-build - run: make build + run: make -f Makefile.own build - name: make run - run: make run + run: make -f Makefile.own run build-windows: runs-on: windows-2019 @@ -27,6 +27,6 @@ jobs: - name: install-make run: choco install make - name: make-directory - run: make dir + run: make -f Makefile.own dir - name: windows-build - run: make winbuild + run: make -f Makefile.own winbuild From d9ba9a3c76d32f15e5ae43f1b29a20af2cce80f2 Mon Sep 17 00:00:00 2001 From: Mushfiqur Rahman Abir <28858998+Abir-Tx@users.noreply.github.com> Date: Thu, 22 Apr 2021 03:47:34 +0600 Subject: [PATCH 6/8] Add cmake test CI --- .github/workflows/c-cpp.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml index 97dae04..7946437 100644 --- a/.github/workflows/c-cpp.yml +++ b/.github/workflows/c-cpp.yml @@ -18,6 +18,8 @@ jobs: run: make -f Makefile.own build - name: make run run: make -f Makefile.own run + - name: Linux CMake Build + run: cmake . && make build-windows: runs-on: windows-2019 @@ -25,8 +27,10 @@ jobs: steps: - uses: actions/checkout@v2 - name: install-make - run: choco install make + run: choco install make cmake - name: make-directory run: make -f Makefile.own dir - name: windows-build run: make -f Makefile.own winbuild + - name: Windows CMake Build + run: cmake . && make From f4337ab083f03982aacb960567a9b704699a9647 Mon Sep 17 00:00:00 2001 From: Mushfiqur Rahman Abir <28858998+Abir-Tx@users.noreply.github.com> Date: Thu, 22 Apr 2021 03:50:52 +0600 Subject: [PATCH 7/8] Remove make & cmake installations --- .github/workflows/c-cpp.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml index 7946437..bca98fa 100644 --- a/.github/workflows/c-cpp.yml +++ b/.github/workflows/c-cpp.yml @@ -26,8 +26,8 @@ jobs: steps: - uses: actions/checkout@v2 - - name: install-make - run: choco install make cmake + # - name: install-make + # run: choco install make cmake - name: make-directory run: make -f Makefile.own dir - name: windows-build From 4cc215a7258e596b2927c89fe54ae60a7b7f64b6 Mon Sep 17 00:00:00 2001 From: Mushfiqur Rahman Abir <28858998+Abir-Tx@users.noreply.github.com> Date: Thu, 22 Apr 2021 04:12:12 +0600 Subject: [PATCH 8/8] Fix windows build error --- .github/workflows/c-cpp.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml index bca98fa..1be609c 100644 --- a/.github/workflows/c-cpp.yml +++ b/.github/workflows/c-cpp.yml @@ -33,4 +33,4 @@ jobs: - name: windows-build run: make -f Makefile.own winbuild - name: Windows CMake Build - run: cmake . && make + run: cmake -G "MinGW Makefiles" && cmake . && make