# dmake **Repository Path**: dzlua/dmake ## Basic Information - **Project Name**: dmake - **Description**: On Linux build tools - **Primary Language**: Shell - **License**: BSD-2-Clause - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2019-05-13 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # dmake #### Description On Linux build tools #### Software Architecture Quickly build code and compile it #### Installation 1. git clone https://gitee.com/dzlua/dmake.git 2. cd dmake 3. ./install.sh #### Instructions 1. generage and edit dmake.t ``` [dzlua@ubuntu]# dmake t #!/bin/bash SRCS=`ls ./*.cc` DST=./a.out #INCLUDES=`pkg-config --cflags gtk+-3.0` INCLUDES= #LINKS=`pkg-config --libs gtk+-3.0` LINKS= RUN_ARGS=() ``` 2. build ``` [dzlua@ubuntu]# dmake b ``` 3. run ``` [dzlua@ubuntu]# dmake r ``` 4. see log ``` [dzlua@ubuntu]# cat a.out.log ``` #### Command 1. t: Generate a script ``` [dzlua@ubuntu]# dmake t ``` Example: ``` [dzlua@ubuntu]# ls info.cc info.h main.cc [dzlua@ubuntu]# dmake t [dzlua@ubuntu]# ls dmake.t info.cc info.h main.cc [dzlua@ubuntu]# cat dmake.t #!/bin/bash SRCS=`ls ./*.cc` DST=./a.out LOG_FILE=./a.log #INCLUDES=`pkg-config --cflags gtk+-3.0` INCLUDES= #LINKS=`pkg-config --libs gtk+-3.0` LINKS= RUN_ARGS=() [dzlua@ubuntu]# ``` 2. b: Build all files ``` [dzlua@ubuntu]# dmake b ``` Example: ``` [dzlua@ubuntu]# ls dmake.t info.cc info.h main.cc [dzlua@ubuntu]# dmake b Done! [dzlua@ubuntu]# ls a.out dmake.t info.cc info.h main.cc [dzlua@ubuntu]# ``` 3. r: Run the app ``` [dzlua@ubuntu]# dmake r ``` Example: ``` [dzlua@ubuntu]# ls a.out dmake.t info.cc info.h main.cc [dzlua@ubuntu]# dmake r exist with code 0 [dzlua@ubuntu]# ls a.log a.out dmake.t info.cc info.h main.cc [dzlua@ubuntu]# cat a.log hellow world [dzlua@ubuntu]# ``` 4. br: Build all files and Run the app ``` [dzlua@ubuntu]# dmake br ``` Example: ``` [dzlua@ubuntu]# ls dmake.t info.cc info.h main.cc [dzlua@ubuntu]# dmake br Done! exist with code 0 [dzlua@ubuntu]# ls a.log a.out dmake.t info.cc info.h main.cc [dzlua@ubuntu]# cat a.log hellow world [dzlua@ubuntu]# ``` 5. -v: Display details ``` [dzlua@ubuntu]# dmake br -v ``` Example: ``` [dzlua@ubuntu]# ls dmake.t info.cc info.h main.cc [dzlua@ubuntu]# dmake br -v build command: g++ ./info.cc ./main.cc -o ./a.out ...building... Done! run command: ././a.out ...runing... exist with code 0 [dzlua@ubuntu]# ls a.log a.out dmake.t info.cc info.h main.cc [dzlua@ubuntu]# cat a.log hellow world [dzlua@ubuntu]# ``` 6. -d: Debug mode ``` [dzlua@ubuntu]# dmake br -d ``` 7. -h: Show help ``` [dzlua@ubuntu]# dmake -h ``` Example: ``` [dzlua@ubuntu]# dmake -h Usage: dmake [actions] [options] Actions: t Generate a script b Build all files r Run the app br Build all files and Run the app Options: -v Display details -d Debug mode -h Show this help [dzlua@ubuntu]# ``` #### Contribution 1. [dzlua@ubuntu]# mkdir test 2. [dzlua@ubuntu]# cd test 3. [dzlua@ubuntu]# vi main.cc 4. coding main.cc ``` #include #include int main(int argc, char **argv) { printf("hellow world"); return 0; } ``` 5. [dzlua@ubuntu]# dmake t Generating Template 6. [dzlua@ubuntu]# dmake b build main.cc 7. [dzlua@ubuntu]# dmake r run target 8. [dzlua@ubuntu]# ls a.out a.out.log dmake.t main.cc #### Gitee Feature 1. You can use Readme\_XXX.md to support different languages, such as Readme\_en.md, Readme\_zh.md 2. Gitee blog [blog.gitee.com](https://blog.gitee.com) 3. Explore open source project [https://gitee.com/explore](https://gitee.com/explore) 4. The most valuable open source project [GVP](https://gitee.com/gvp) 5. The manual of Gitee [https://gitee.com/help](https://gitee.com/help) 6. The most popular members [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)