"make" system

Anil Kumar Pugalia
Anil Kumar PugaliaLinux Geek and Open Source Hardware & Software Freak, Corporate Trainer, Entrepreneur in Automation
“make” System



© 2010 Anil Kumar Pugalia <email@sarika-pugs.com>
               All Rights Reserved.
What to Expect?
What is 'make' & its System?
Learning 'make' by Examples




        © 2010 Anil Kumar Pugalia <email@sarika-pugs.com>   2
                       All Rights Reserved.
What is 'make'?
Tool to automatically execute commands
  Any number, Any length
Based on complete dependency chains
  Typically based on time (of change)
Majorly replacing the manual process
  Effectively saving time & manual errors
Typical usages
  Project build system (compilation, etc)
  Packaging files (binaries, documentation, source code)
  Installations (of Systems, Packages, ...)
  Anything that can be automated based on dependencies
             © 2010 Anil Kumar Pugalia <email@sarika-pugs.com>   3
                            All Rights Reserved.
Usage of 'make'
Initiated by the command 'make'
Controlled by its configuration files
  Containing rules to execute various commands
  Based on various target dependencies
Default configuration files
  GNUmakefile, makefile, Makefile (in that order)
Other configuration file using -f
Assisted by many in-built rules & variables



           © 2010 Anil Kumar Pugalia <email@sarika-pugs.com>   4
                          All Rights Reserved.
Typical Rule
target: dependencies
<tab>action
<tab>action
<tab>...


Example
abc: pqr
  cp pqr abc
           © 2010 Anil Kumar Pugalia <email@sarika-pugs.com>   5
                          All Rights Reserved.
Sample Makefile
xyz: abc
  cp abc xyz


abc: pqr
  cp pqr abc


pqr:
  touch pqr
           © 2010 Anil Kumar Pugalia <email@sarika-pugs.com>   6
                          All Rights Reserved.
Let's create a Makefile
                           for
Automatically compiling a C program




      © 2010 Anil Kumar Pugalia <email@sarika-pugs.com>   7
                     All Rights Reserved.
Extending the Makefile
Build an executable from many C files
Build a project with 10,000 C files
Add the user's header file dependencies
Automatic header dependency generation




        © 2010 Anil Kumar Pugalia <email@sarika-pugs.com>   8
                       All Rights Reserved.
What all have we learnt?
'make' & its benefits
Usage of 'make'
Examples of using 'make'




        © 2010 Anil Kumar Pugalia <email@sarika-pugs.com>   9
                       All Rights Reserved.
Any Queries?




© 2010 Anil Kumar Pugalia <email@sarika-pugs.com>   10
               All Rights Reserved.
1 of 10

Recommended

Linux File System by
Linux File SystemLinux File System
Linux File SystemAnil Kumar Pugalia
24.5K views33 slides
Signals by
SignalsSignals
SignalsAnil Kumar Pugalia
9.8K views15 slides
Linux Network Management by
Linux Network ManagementLinux Network Management
Linux Network ManagementAnil Kumar Pugalia
11.3K views33 slides
RPM Building by
RPM BuildingRPM Building
RPM BuildingAnil Kumar Pugalia
4K views18 slides
Toolchain by
ToolchainToolchain
ToolchainAnil Kumar Pugalia
15K views21 slides
POSIX Threads by
POSIX ThreadsPOSIX Threads
POSIX ThreadsSysPlay eLearning Academy for You
4.1K views21 slides

More Related Content

What's hot

Introduction to Linux by
Introduction to LinuxIntroduction to Linux
Introduction to LinuxAnil Kumar Pugalia
4K views33 slides
Bootloaders by
BootloadersBootloaders
BootloadersAnil Kumar Pugalia
10K views19 slides
Kernel Debugging & Profiling by
Kernel Debugging & ProfilingKernel Debugging & Profiling
Kernel Debugging & ProfilingAnil Kumar Pugalia
6K views14 slides
Architecture Porting by
Architecture PortingArchitecture Porting
Architecture PortingAnil Kumar Pugalia
5K views12 slides
Threads by
ThreadsThreads
ThreadsAnil Kumar Pugalia
10.2K views39 slides
Understanding the BBB by
Understanding the BBBUnderstanding the BBB
Understanding the BBBSysPlay eLearning Academy for You
9.5K views10 slides

What's hot(20)

Viewers also liked

Power of vi by
Power of viPower of vi
Power of viAnil Kumar Pugalia
3K views9 slides
Embedded C by
Embedded CEmbedded C
Embedded CAnil Kumar Pugalia
25.7K views20 slides
Linux User Space Debugging & Profiling by
Linux User Space Debugging & ProfilingLinux User Space Debugging & Profiling
Linux User Space Debugging & ProfilingAnil Kumar Pugalia
6.5K views36 slides
Introduction to Embedded Systems by
Introduction to Embedded SystemsIntroduction to Embedded Systems
Introduction to Embedded SystemsAnil Kumar Pugalia
18.5K views37 slides
Interrupts by
InterruptsInterrupts
InterruptsAnil Kumar Pugalia
47.7K views18 slides
Linux Porting by
Linux PortingLinux Porting
Linux PortingAnil Kumar Pugalia
17.5K views29 slides

Viewers also liked(17)

Similar to "make" system

Extending uBuild and uDeploy with Plugins by
Extending uBuild and uDeploy with PluginsExtending uBuild and uDeploy with Plugins
Extending uBuild and uDeploy with PluginsIBM UrbanCode Products
9.5K views47 slides
K8s, Amazon EKS - 유재석, AWS 솔루션즈 아키텍트 by
K8s, Amazon EKS - 유재석, AWS 솔루션즈 아키텍트K8s, Amazon EKS - 유재석, AWS 솔루션즈 아키텍트
K8s, Amazon EKS - 유재석, AWS 솔루션즈 아키텍트Amazon Web Services Korea
1.6K views113 slides
仕事ではじめる機械学習 by
仕事ではじめる機械学習仕事ではじめる機械学習
仕事ではじめる機械学習Aki Ariga
8.2K views35 slides
Distributed Monitoring and Cloud Scaling by
Distributed Monitoring and Cloud ScalingDistributed Monitoring and Cloud Scaling
Distributed Monitoring and Cloud ScalingFernando Honig
423 views41 slides
SQLcl overview - A new Command Line Interface for Oracle Database by
SQLcl overview - A new Command Line Interface for Oracle DatabaseSQLcl overview - A new Command Line Interface for Oracle Database
SQLcl overview - A new Command Line Interface for Oracle DatabaseJeff Smith
47.3K views38 slides
AWS 고객사를 위한 ‘AWS 컨테이너 교육’ - 유재석, AWS 솔루션즈 아키텍트 by
AWS 고객사를 위한 ‘AWS 컨테이너 교육’ - 유재석, AWS 솔루션즈 아키텍트AWS 고객사를 위한 ‘AWS 컨테이너 교육’ - 유재석, AWS 솔루션즈 아키텍트
AWS 고객사를 위한 ‘AWS 컨테이너 교육’ - 유재석, AWS 솔루션즈 아키텍트Amazon Web Services Korea
471 views97 slides

Similar to "make" system(20)

仕事ではじめる機械学習 by Aki Ariga
仕事ではじめる機械学習仕事ではじめる機械学習
仕事ではじめる機械学習
Aki Ariga8.2K views
Distributed Monitoring and Cloud Scaling by Fernando Honig
Distributed Monitoring and Cloud ScalingDistributed Monitoring and Cloud Scaling
Distributed Monitoring and Cloud Scaling
Fernando Honig423 views
SQLcl overview - A new Command Line Interface for Oracle Database by Jeff Smith
SQLcl overview - A new Command Line Interface for Oracle DatabaseSQLcl overview - A new Command Line Interface for Oracle Database
SQLcl overview - A new Command Line Interface for Oracle Database
Jeff Smith47.3K views
AWS 고객사를 위한 ‘AWS 컨테이너 교육’ - 유재석, AWS 솔루션즈 아키텍트 by Amazon Web Services Korea
AWS 고객사를 위한 ‘AWS 컨테이너 교육’ - 유재석, AWS 솔루션즈 아키텍트AWS 고객사를 위한 ‘AWS 컨테이너 교육’ - 유재석, AWS 솔루션즈 아키텍트
AWS 고객사를 위한 ‘AWS 컨테이너 교육’ - 유재석, AWS 솔루션즈 아키텍트
Cloud native Microservices using Spring Boot by Sufyaan Kazi
Cloud native Microservices using Spring BootCloud native Microservices using Spring Boot
Cloud native Microservices using Spring Boot
Sufyaan Kazi8.8K views
SaltConf14 - Ben Cane - Using SaltStack in High Availability Environments by SaltStack
SaltConf14 - Ben Cane - Using SaltStack in High Availability EnvironmentsSaltConf14 - Ben Cane - Using SaltStack in High Availability Environments
SaltConf14 - Ben Cane - Using SaltStack in High Availability Environments
SaltStack5K views
OSMC 2013 | Distributed Monitoring and Cloud Scaling for Web Apps by Fernando... by NETWAYS
OSMC 2013 | Distributed Monitoring and Cloud Scaling for Web Apps by Fernando...OSMC 2013 | Distributed Monitoring and Cloud Scaling for Web Apps by Fernando...
OSMC 2013 | Distributed Monitoring and Cloud Scaling for Web Apps by Fernando...
NETWAYS34 views
Mobile and agile the floating writer's survival kit by Alyssa Fox
Mobile and agile   the floating writer's survival kitMobile and agile   the floating writer's survival kit
Mobile and agile the floating writer's survival kit
Alyssa Fox456 views
DevOps Spain 2019. Pedro Mendoza-AWS by atSistemas
DevOps Spain 2019. Pedro Mendoza-AWSDevOps Spain 2019. Pedro Mendoza-AWS
DevOps Spain 2019. Pedro Mendoza-AWS
atSistemas420 views
An Introduction to CMake by ICS
An Introduction to CMakeAn Introduction to CMake
An Introduction to CMake
ICS1.5K views
ServerTemplate Deep Dive by RightScale
ServerTemplate Deep DiveServerTemplate Deep Dive
ServerTemplate Deep Dive
RightScale1.5K views
Решения Cisco для Автоматизации Облачных Услуг - Cisco Intelligent Automation... by Cisco Russia
Решения Cisco для Автоматизации Облачных Услуг - Cisco Intelligent Automation...Решения Cisco для Автоматизации Облачных Услуг - Cisco Intelligent Automation...
Решения Cisco для Автоматизации Облачных Услуг - Cisco Intelligent Automation...
Cisco Russia 443 views
Evolving Services Into A Cloud Native World by Iain Hull
Evolving Services Into A Cloud Native WorldEvolving Services Into A Cloud Native World
Evolving Services Into A Cloud Native World
Iain Hull81 views
Command central 9.6 - Features Overview by Software AG
Command central 9.6 - Features OverviewCommand central 9.6 - Features Overview
Command central 9.6 - Features Overview
Software AG3.4K views
SaaS Testing on an Agile World by PractiTest
SaaS Testing on an Agile WorldSaaS Testing on an Agile World
SaaS Testing on an Agile World
PractiTest1.5K views

More from Anil Kumar Pugalia

File System Modules by
File System ModulesFile System Modules
File System ModulesAnil Kumar Pugalia
21K views37 slides
Processes by
ProcessesProcesses
ProcessesAnil Kumar Pugalia
7K views33 slides
System Calls by
System CallsSystem Calls
System CallsAnil Kumar Pugalia
4.2K views17 slides
Playing with R L C Circuits by
Playing with R L C CircuitsPlaying with R L C Circuits
Playing with R L C CircuitsAnil Kumar Pugalia
2.8K views17 slides
Hardware Design for Software Hackers by
Hardware Design for Software HackersHardware Design for Software Hackers
Hardware Design for Software HackersAnil Kumar Pugalia
1.7K views32 slides
System Calls by
System CallsSystem Calls
System CallsAnil Kumar Pugalia
9.7K views14 slides

Recently uploaded

Top 10 Strategic Technologies in 2024: AI and Automation by
Top 10 Strategic Technologies in 2024: AI and AutomationTop 10 Strategic Technologies in 2024: AI and Automation
Top 10 Strategic Technologies in 2024: AI and AutomationAutomationEdge Technologies
18 views14 slides
Melek BEN MAHMOUD.pdf by
Melek BEN MAHMOUD.pdfMelek BEN MAHMOUD.pdf
Melek BEN MAHMOUD.pdfMelekBenMahmoud
14 views1 slide
6g - REPORT.pdf by
6g - REPORT.pdf6g - REPORT.pdf
6g - REPORT.pdfLiveplex
10 views23 slides
Web Dev - 1 PPT.pdf by
Web Dev - 1 PPT.pdfWeb Dev - 1 PPT.pdf
Web Dev - 1 PPT.pdfgdsczhcet
60 views45 slides
1st parposal presentation.pptx by
1st parposal presentation.pptx1st parposal presentation.pptx
1st parposal presentation.pptxi238212
9 views3 slides
Perth MeetUp November 2023 by
Perth MeetUp November 2023 Perth MeetUp November 2023
Perth MeetUp November 2023 Michael Price
19 views44 slides

Recently uploaded(20)

6g - REPORT.pdf by Liveplex
6g - REPORT.pdf6g - REPORT.pdf
6g - REPORT.pdf
Liveplex10 views
Web Dev - 1 PPT.pdf by gdsczhcet
Web Dev - 1 PPT.pdfWeb Dev - 1 PPT.pdf
Web Dev - 1 PPT.pdf
gdsczhcet60 views
1st parposal presentation.pptx by i238212
1st parposal presentation.pptx1st parposal presentation.pptx
1st parposal presentation.pptx
i2382129 views
Perth MeetUp November 2023 by Michael Price
Perth MeetUp November 2023 Perth MeetUp November 2023
Perth MeetUp November 2023
Michael Price19 views
Attacking IoT Devices from a Web Perspective - Linux Day by Simone Onofri
Attacking IoT Devices from a Web Perspective - Linux Day Attacking IoT Devices from a Web Perspective - Linux Day
Attacking IoT Devices from a Web Perspective - Linux Day
Simone Onofri15 views
Piloting & Scaling Successfully With Microsoft Viva by Richard Harbridge
Piloting & Scaling Successfully With Microsoft VivaPiloting & Scaling Successfully With Microsoft Viva
Piloting & Scaling Successfully With Microsoft Viva
Spesifikasi Lengkap ASUS Vivobook Go 14 by Dot Semarang
Spesifikasi Lengkap ASUS Vivobook Go 14Spesifikasi Lengkap ASUS Vivobook Go 14
Spesifikasi Lengkap ASUS Vivobook Go 14
Dot Semarang37 views
The details of description: Techniques, tips, and tangents on alternative tex... by BookNet Canada
The details of description: Techniques, tips, and tangents on alternative tex...The details of description: Techniques, tips, and tangents on alternative tex...
The details of description: Techniques, tips, and tangents on alternative tex...
BookNet Canada126 views
Business Analyst Series 2023 - Week 3 Session 5 by DianaGray10
Business Analyst Series 2023 -  Week 3 Session 5Business Analyst Series 2023 -  Week 3 Session 5
Business Analyst Series 2023 - Week 3 Session 5
DianaGray10237 views
TouchLog: Finger Micro Gesture Recognition Using Photo-Reflective Sensors by sugiuralab
TouchLog: Finger Micro Gesture Recognition  Using Photo-Reflective SensorsTouchLog: Finger Micro Gesture Recognition  Using Photo-Reflective Sensors
TouchLog: Finger Micro Gesture Recognition Using Photo-Reflective Sensors
sugiuralab19 views

"make" system

  • 1. “make” System © 2010 Anil Kumar Pugalia <email@sarika-pugs.com> All Rights Reserved.
  • 2. What to Expect? What is 'make' & its System? Learning 'make' by Examples © 2010 Anil Kumar Pugalia <email@sarika-pugs.com> 2 All Rights Reserved.
  • 3. What is 'make'? Tool to automatically execute commands Any number, Any length Based on complete dependency chains Typically based on time (of change) Majorly replacing the manual process Effectively saving time & manual errors Typical usages Project build system (compilation, etc) Packaging files (binaries, documentation, source code) Installations (of Systems, Packages, ...) Anything that can be automated based on dependencies © 2010 Anil Kumar Pugalia <email@sarika-pugs.com> 3 All Rights Reserved.
  • 4. Usage of 'make' Initiated by the command 'make' Controlled by its configuration files Containing rules to execute various commands Based on various target dependencies Default configuration files GNUmakefile, makefile, Makefile (in that order) Other configuration file using -f Assisted by many in-built rules & variables © 2010 Anil Kumar Pugalia <email@sarika-pugs.com> 4 All Rights Reserved.
  • 5. Typical Rule target: dependencies <tab>action <tab>action <tab>... Example abc: pqr cp pqr abc © 2010 Anil Kumar Pugalia <email@sarika-pugs.com> 5 All Rights Reserved.
  • 6. Sample Makefile xyz: abc cp abc xyz abc: pqr cp pqr abc pqr: touch pqr © 2010 Anil Kumar Pugalia <email@sarika-pugs.com> 6 All Rights Reserved.
  • 7. Let's create a Makefile for Automatically compiling a C program © 2010 Anil Kumar Pugalia <email@sarika-pugs.com> 7 All Rights Reserved.
  • 8. Extending the Makefile Build an executable from many C files Build a project with 10,000 C files Add the user's header file dependencies Automatic header dependency generation © 2010 Anil Kumar Pugalia <email@sarika-pugs.com> 8 All Rights Reserved.
  • 9. What all have we learnt? 'make' & its benefits Usage of 'make' Examples of using 'make' © 2010 Anil Kumar Pugalia <email@sarika-pugs.com> 9 All Rights Reserved.
  • 10. Any Queries? © 2010 Anil Kumar Pugalia <email@sarika-pugs.com> 10 All Rights Reserved.