SlideShare a Scribd company logo
1 of 21
Common practices
and tools
vicente.bolea@gmail.com
Motivation
So far we have covered tools and practices which helps you in
your project in a high level.
However, normally projects integrate tools and practices
when it comes to coding which becomes a integral part of the
project itself.
Scope
1. GNU autotools
2. Design patterns
3. Strategy pattern
Autotools vs. Make
➢ Make let you instruct your compiler how to build your
project for your platform. All the variable are hardcoded.
➢ Autotools does the same thing as Make, however, it also
let you: Forget about dependencies, library building,
different platforms, check for compatibility, build the
actual release package (*.tar.gz) and much more.
Autotools drawbacks
➢ It check compatibility for a useless amount of old
platforms.
➢ It’s bloated.
➢ It’s slow.
➢ It’s hard to learn and you will not expect newbies to
master this tool.
But Autotools is:
➢ Ubiquitous within Linux.
➢ No competitors.
➢ Standard.
➢ Does not require the user to install autotools.
➢ Believe or not, it makes the life easier to the users.
This is how I see
Autotools...
Autotools: user tutorial
Fairly simple:
$ sh autogen.sh
$ sh ./configure --help # Check if there is any relevant opt
$ sh ./configure --prefix /usr/local # for the most cases
# if you are missing a dependency install it by apt, yum ...
$ make [-j #proc] install
Autotools: Developer
tutorial
You need the two files to configure autotools:
- Configure.ac # General options and checkings
- Makefile.am # Options for the generation of
the Makefile
Autotools: Developer
tutorial
Often you will like to automatize all those calls
shown in the figure.
Thus, the convention is to write a file called
autogen.sh.
That file will call all those commands for you so that
you can forget about that complex graph of calls.
Autotools: Developer
tutorial
One more convention is to call sh autogen.sh at the
source code directory while calling the rest of the
command in a separated directory.
That separated directory is often refer as build
folder and contains temporary files which can be
safely removed.
The source code directory remains intact. (Good for
git)
Design patterns: Motivation
➢ Create a vocabulary among your peers to communicate
faster and more accurately.
➢ Being able to generate a extensible and good class design
for your project.
➢ Gives you a tested solution of your problem.
➢ Easy for other peers to read your code.
I can’t cover all of
the design patterns.
Let’s just focus on
one...
Strategy pattern
Features:
➢ Abstracts a family of algorithms
➢ Encapsulate algorithms (Remove dependencies)
➢ Easy to add new algorithms
Strategy pattern: Diagram
Strategy pattern:
Implementation
The source code is too big for this slide, we can see it in the
following website.
Example
Strategy pattern: Review
As we have seen in the previous example, benefits of strategy
are clear:
➔ Strategy class only has no dependency.
➔ TestBed only depends on Strategy class.
➔ We can add more Strategies without modifying different
classes.
➔ Imagine if you more than 50 different strategies… !
Design pattern: Conclusion
In this mini-tutorial of strategy pattern we can see the
potential benefit of using them.
That is just one of the more than 20 basic design patterns, I
invite you to research and incorporate in your designs.
BONUS:
C++14
shoutout
So far we have used C++98 which is clumsy and
some of its features such as multithreading, lambda
functions and so on are half-cooked. Good new is
that we now have C++14 which allows us to:
● Use lambda functions.
● Multithreading API.
● Auto keyword.
● Move operator.
BONUS: C++14 shoutout
To start using C++14 make sure that your GCC compiler’s version is
higher than 4.9 and compile with the flag -std=c++11.
Also as for your assignments as your TA’s whether is acceptable to use
C++11, 14. Your code will not compile in an old compiler or if they
don’t specified the previously mentioned flags.
Q&A

More Related Content

What's hot

Test Driven Development
Test Driven DevelopmentTest Driven Development
Test Driven DevelopmentJohn Blanco
 
Test Driven Development with PHP
Test Driven Development with PHPTest Driven Development with PHP
Test Driven Development with PHPRogério Vicente
 
PHP Code Quality
PHP Code QualityPHP Code Quality
PHP Code QualityUsman Zafar
 
2 Getting To Know Your Programing Environment
2 Getting To Know Your Programing Environment2 Getting To Know Your Programing Environment
2 Getting To Know Your Programing Environmentguest9aa151
 
Lessons learned on software testing automation
Lessons learned on software testing automationLessons learned on software testing automation
Lessons learned on software testing automationgaoliang641
 
【Edd workshop@140725】TDD introduction_Andy Huang
【Edd workshop@140725】TDD introduction_Andy Huang 【Edd workshop@140725】TDD introduction_Andy Huang
【Edd workshop@140725】TDD introduction_Andy Huang EZTABLE
 
Php[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for BeginnersPhp[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for BeginnersAdam Englander
 
It's all about behaviour, also in php - phpspec
It's all about behaviour, also in php - phpspecIt's all about behaviour, also in php - phpspec
It's all about behaviour, also in php - phpspecGiulio De Donato
 
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)Matheus Marabesi
 
Managing frontend libs in your php project
Managing frontend libs in your php projectManaging frontend libs in your php project
Managing frontend libs in your php projectMassimiliano Arione
 
Best practices in pair programming
Best practices in pair programmingBest practices in pair programming
Best practices in pair programmingLucas Aquiles
 
Test Driven Development in CQ5/AEM
Test Driven Development in CQ5/AEMTest Driven Development in CQ5/AEM
Test Driven Development in CQ5/AEMSagar Sane
 
РОМАН ЯКИМЧУК «Оптимізація QA процесів» Kyiv QADay 2021
РОМАН ЯКИМЧУК «Оптимізація QA процесів» Kyiv QADay 2021РОМАН ЯКИМЧУК «Оптимізація QA процесів» Kyiv QADay 2021
РОМАН ЯКИМЧУК «Оптимізація QA процесів» Kyiv QADay 2021GoQA
 
Productive Android developers (Meetup slides)
Productive Android developers (Meetup slides)Productive Android developers (Meetup slides)
Productive Android developers (Meetup slides)Michal Juhas
 

What's hot (20)

Test Driven Development
Test Driven DevelopmentTest Driven Development
Test Driven Development
 
Test Driven Development with PHP
Test Driven Development with PHPTest Driven Development with PHP
Test Driven Development with PHP
 
Testing and symfony2
Testing and symfony2Testing and symfony2
Testing and symfony2
 
PHP Code Quality
PHP Code QualityPHP Code Quality
PHP Code Quality
 
2 Getting To Know Your Programing Environment
2 Getting To Know Your Programing Environment2 Getting To Know Your Programing Environment
2 Getting To Know Your Programing Environment
 
Lessons learned on software testing automation
Lessons learned on software testing automationLessons learned on software testing automation
Lessons learned on software testing automation
 
【Edd workshop@140725】TDD introduction_Andy Huang
【Edd workshop@140725】TDD introduction_Andy Huang 【Edd workshop@140725】TDD introduction_Andy Huang
【Edd workshop@140725】TDD introduction_Andy Huang
 
Php[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for BeginnersPhp[tek] 2016 - BDD with Behat for Beginners
Php[tek] 2016 - BDD with Behat for Beginners
 
It's all about behaviour, also in php - phpspec
It's all about behaviour, also in php - phpspecIt's all about behaviour, also in php - phpspec
It's all about behaviour, also in php - phpspec
 
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
 
Tdd presentation
Tdd presentationTdd presentation
Tdd presentation
 
Managing frontend libs in your php project
Managing frontend libs in your php projectManaging frontend libs in your php project
Managing frontend libs in your php project
 
Unit testing (eng)
Unit testing (eng)Unit testing (eng)
Unit testing (eng)
 
Best practices in pair programming
Best practices in pair programmingBest practices in pair programming
Best practices in pair programming
 
Developing for Developers
Developing for DevelopersDeveloping for Developers
Developing for Developers
 
Testing In Django
Testing In DjangoTesting In Django
Testing In Django
 
Test Driven Development in CQ5/AEM
Test Driven Development in CQ5/AEMTest Driven Development in CQ5/AEM
Test Driven Development in CQ5/AEM
 
РОМАН ЯКИМЧУК «Оптимізація QA процесів» Kyiv QADay 2021
РОМАН ЯКИМЧУК «Оптимізація QA процесів» Kyiv QADay 2021РОМАН ЯКИМЧУК «Оптимізація QA процесів» Kyiv QADay 2021
РОМАН ЯКИМЧУК «Оптимізація QA процесів» Kyiv QADay 2021
 
Productive Android developers (Meetup slides)
Productive Android developers (Meetup slides)Productive Android developers (Meetup slides)
Productive Android developers (Meetup slides)
 
Tdd red-green-refactor
Tdd red-green-refactorTdd red-green-refactor
Tdd red-green-refactor
 

Similar to Autotools, Design Patterns and more

His162013 140529214456-phpapp01
His162013 140529214456-phpapp01His162013 140529214456-phpapp01
His162013 140529214456-phpapp01Getachew Ganfur
 
C plus plus for hackers it security
C plus plus for hackers it securityC plus plus for hackers it security
C plus plus for hackers it securityCESAR A. RUIZ C
 
Software Development Standard Operating Procedure
Software Development Standard Operating Procedure Software Development Standard Operating Procedure
Software Development Standard Operating Procedure rupeshchanchal
 
Programming Sessions KU Leuven - Session 01
Programming Sessions KU Leuven - Session 01Programming Sessions KU Leuven - Session 01
Programming Sessions KU Leuven - Session 01Rafael Camacho Dejay
 
Stanislav Khorunzhyi, "Front-end it like a PRO"
Stanislav Khorunzhyi, "Front-end it like a PRO"Stanislav Khorunzhyi, "Front-end it like a PRO"
Stanislav Khorunzhyi, "Front-end it like a PRO"Sigma Software
 
Test Driven Development (TDD) Preso 360|Flex 2010
Test Driven Development (TDD) Preso 360|Flex 2010Test Driven Development (TDD) Preso 360|Flex 2010
Test Driven Development (TDD) Preso 360|Flex 2010guest5639fa9
 
Test Driven Development (TDD) with FlexUnit 4 - 360|Flex San Jose preso
Test Driven Development (TDD) with FlexUnit 4 - 360|Flex San Jose presoTest Driven Development (TDD) with FlexUnit 4 - 360|Flex San Jose preso
Test Driven Development (TDD) with FlexUnit 4 - 360|Flex San Jose presoElad Elrom
 
How to work with code blocks
How to work with code blocksHow to work with code blocks
How to work with code blocksTech Bikram
 
C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.Richard Taylor
 
Makefile
MakefileMakefile
MakefileIonela
 
Introduction to Behavior Driven Development
Introduction to Behavior Driven Development Introduction to Behavior Driven Development
Introduction to Behavior Driven Development Robin O'Brien
 
Introduction of Tools for providing rich user experience in debugger
Introduction of Tools for providing rich user experience in debuggerIntroduction of Tools for providing rich user experience in debugger
Introduction of Tools for providing rich user experience in debuggerNaoto Ono
 
codeblocks-instructions.pdf
codeblocks-instructions.pdfcodeblocks-instructions.pdf
codeblocks-instructions.pdfRavinderKSingla
 
Prg 218 entire course
Prg 218 entire coursePrg 218 entire course
Prg 218 entire coursegrades4u
 
C++ language basic
C++ language basicC++ language basic
C++ language basicWaqar Younis
 
IDE and Toolset For Magento Development
IDE and Toolset For Magento DevelopmentIDE and Toolset For Magento Development
IDE and Toolset For Magento DevelopmentAbid Malik
 

Similar to Autotools, Design Patterns and more (20)

C++ for hackers
C++ for hackersC++ for hackers
C++ for hackers
 
His162013 140529214456-phpapp01
His162013 140529214456-phpapp01His162013 140529214456-phpapp01
His162013 140529214456-phpapp01
 
C plus plus for hackers it security
C plus plus for hackers it securityC plus plus for hackers it security
C plus plus for hackers it security
 
Software Development Standard Operating Procedure
Software Development Standard Operating Procedure Software Development Standard Operating Procedure
Software Development Standard Operating Procedure
 
Programming Sessions KU Leuven - Session 01
Programming Sessions KU Leuven - Session 01Programming Sessions KU Leuven - Session 01
Programming Sessions KU Leuven - Session 01
 
Stanislav Khorunzhyi, "Front-end it like a PRO"
Stanislav Khorunzhyi, "Front-end it like a PRO"Stanislav Khorunzhyi, "Front-end it like a PRO"
Stanislav Khorunzhyi, "Front-end it like a PRO"
 
Test Driven Development (TDD) Preso 360|Flex 2010
Test Driven Development (TDD) Preso 360|Flex 2010Test Driven Development (TDD) Preso 360|Flex 2010
Test Driven Development (TDD) Preso 360|Flex 2010
 
Test Driven Development (TDD) with FlexUnit 4 - 360|Flex San Jose preso
Test Driven Development (TDD) with FlexUnit 4 - 360|Flex San Jose presoTest Driven Development (TDD) with FlexUnit 4 - 360|Flex San Jose preso
Test Driven Development (TDD) with FlexUnit 4 - 360|Flex San Jose preso
 
How to work with code blocks
How to work with code blocksHow to work with code blocks
How to work with code blocks
 
C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.
 
ID E's features
ID E's featuresID E's features
ID E's features
 
Makefile
MakefileMakefile
Makefile
 
Introduction to Behavior Driven Development
Introduction to Behavior Driven Development Introduction to Behavior Driven Development
Introduction to Behavior Driven Development
 
Introduction of Tools for providing rich user experience in debugger
Introduction of Tools for providing rich user experience in debuggerIntroduction of Tools for providing rich user experience in debugger
Introduction of Tools for providing rich user experience in debugger
 
codeblocks-instructions.pdf
codeblocks-instructions.pdfcodeblocks-instructions.pdf
codeblocks-instructions.pdf
 
DDD with Behat
DDD with BehatDDD with Behat
DDD with Behat
 
Prg 218 entire course
Prg 218 entire coursePrg 218 entire course
Prg 218 entire course
 
C++ language basic
C++ language basicC++ language basic
C++ language basic
 
Git Makes Me Angry Inside
Git Makes Me Angry InsideGit Makes Me Angry Inside
Git Makes Me Angry Inside
 
IDE and Toolset For Magento Development
IDE and Toolset For Magento DevelopmentIDE and Toolset For Magento Development
IDE and Toolset For Magento Development
 

More from Vicente Bolea

Linux Developing Stack
Linux Developing StackLinux Developing Stack
Linux Developing StackVicente Bolea
 
Github developing stack
Github developing stackGithub developing stack
Github developing stackVicente Bolea
 
Project management frameworks for software developing
Project management frameworks for software developingProject management frameworks for software developing
Project management frameworks for software developingVicente Bolea
 

More from Vicente Bolea (7)

Basic Git Tutorial
Basic Git TutorialBasic Git Tutorial
Basic Git Tutorial
 
BOOST ASIO overview
BOOST ASIO overviewBOOST ASIO overview
BOOST ASIO overview
 
Linux Developing Stack
Linux Developing StackLinux Developing Stack
Linux Developing Stack
 
Github developing stack
Github developing stackGithub developing stack
Github developing stack
 
Project management frameworks for software developing
Project management frameworks for software developingProject management frameworks for software developing
Project management frameworks for software developing
 
Debuging like a pro
Debuging like a proDebuging like a pro
Debuging like a pro
 
VeloxDFS
VeloxDFSVeloxDFS
VeloxDFS
 

Recently uploaded

Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...srsj9000
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girlsssuser7cb4ff
 
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETE
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETEINFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETE
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETEroselinkalist12
 
Heart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptxHeart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptxPoojaBan
 
Internship report on mechanical engineering
Internship report on mechanical engineeringInternship report on mechanical engineering
Internship report on mechanical engineeringmalavadedarshan25
 
Risk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfRisk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfROCENODodongVILLACER
 
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort serviceGurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort servicejennyeacort
 
Biology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxBiology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxDeepakSakkari2
 
Call Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile serviceCall Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile servicerehmti665
 
Electronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdfElectronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdfme23b1001
 
main PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfidmain PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfidNikhilNagaraju
 
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfCCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfAsst.prof M.Gokilavani
 
What are the advantages and disadvantages of membrane structures.pptx
What are the advantages and disadvantages of membrane structures.pptxWhat are the advantages and disadvantages of membrane structures.pptx
What are the advantages and disadvantages of membrane structures.pptxwendy cai
 
Work Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvWork Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvLewisJB
 
Introduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECHIntroduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECHC Sai Kiran
 
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IVHARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IVRajaP95
 
Artificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxArtificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxbritheesh05
 
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube ExchangerStudy on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube ExchangerAnamika Sarkar
 

Recently uploaded (20)

Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girls
 
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETE
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETEINFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETE
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETE
 
Heart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptxHeart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptx
 
Internship report on mechanical engineering
Internship report on mechanical engineeringInternship report on mechanical engineering
Internship report on mechanical engineering
 
Risk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfRisk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdf
 
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort serviceGurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
 
Biology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxBiology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptx
 
Call Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile serviceCall Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile service
 
Electronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdfElectronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdf
 
main PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfidmain PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfid
 
Design and analysis of solar grass cutter.pdf
Design and analysis of solar grass cutter.pdfDesign and analysis of solar grass cutter.pdf
Design and analysis of solar grass cutter.pdf
 
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfCCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
 
🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...
🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...
🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...
 
What are the advantages and disadvantages of membrane structures.pptx
What are the advantages and disadvantages of membrane structures.pptxWhat are the advantages and disadvantages of membrane structures.pptx
What are the advantages and disadvantages of membrane structures.pptx
 
Work Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvWork Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvv
 
Introduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECHIntroduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECH
 
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IVHARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
 
Artificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxArtificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptx
 
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube ExchangerStudy on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
 

Autotools, Design Patterns and more

  • 2. Motivation So far we have covered tools and practices which helps you in your project in a high level. However, normally projects integrate tools and practices when it comes to coding which becomes a integral part of the project itself.
  • 3. Scope 1. GNU autotools 2. Design patterns 3. Strategy pattern
  • 4. Autotools vs. Make ➢ Make let you instruct your compiler how to build your project for your platform. All the variable are hardcoded. ➢ Autotools does the same thing as Make, however, it also let you: Forget about dependencies, library building, different platforms, check for compatibility, build the actual release package (*.tar.gz) and much more.
  • 5. Autotools drawbacks ➢ It check compatibility for a useless amount of old platforms. ➢ It’s bloated. ➢ It’s slow. ➢ It’s hard to learn and you will not expect newbies to master this tool.
  • 6. But Autotools is: ➢ Ubiquitous within Linux. ➢ No competitors. ➢ Standard. ➢ Does not require the user to install autotools. ➢ Believe or not, it makes the life easier to the users.
  • 7. This is how I see Autotools...
  • 8. Autotools: user tutorial Fairly simple: $ sh autogen.sh $ sh ./configure --help # Check if there is any relevant opt $ sh ./configure --prefix /usr/local # for the most cases # if you are missing a dependency install it by apt, yum ... $ make [-j #proc] install
  • 9. Autotools: Developer tutorial You need the two files to configure autotools: - Configure.ac # General options and checkings - Makefile.am # Options for the generation of the Makefile
  • 10. Autotools: Developer tutorial Often you will like to automatize all those calls shown in the figure. Thus, the convention is to write a file called autogen.sh. That file will call all those commands for you so that you can forget about that complex graph of calls.
  • 11. Autotools: Developer tutorial One more convention is to call sh autogen.sh at the source code directory while calling the rest of the command in a separated directory. That separated directory is often refer as build folder and contains temporary files which can be safely removed. The source code directory remains intact. (Good for git)
  • 12. Design patterns: Motivation ➢ Create a vocabulary among your peers to communicate faster and more accurately. ➢ Being able to generate a extensible and good class design for your project. ➢ Gives you a tested solution of your problem. ➢ Easy for other peers to read your code.
  • 13. I can’t cover all of the design patterns. Let’s just focus on one...
  • 14. Strategy pattern Features: ➢ Abstracts a family of algorithms ➢ Encapsulate algorithms (Remove dependencies) ➢ Easy to add new algorithms
  • 16. Strategy pattern: Implementation The source code is too big for this slide, we can see it in the following website. Example
  • 17. Strategy pattern: Review As we have seen in the previous example, benefits of strategy are clear: ➔ Strategy class only has no dependency. ➔ TestBed only depends on Strategy class. ➔ We can add more Strategies without modifying different classes. ➔ Imagine if you more than 50 different strategies… !
  • 18. Design pattern: Conclusion In this mini-tutorial of strategy pattern we can see the potential benefit of using them. That is just one of the more than 20 basic design patterns, I invite you to research and incorporate in your designs.
  • 19. BONUS: C++14 shoutout So far we have used C++98 which is clumsy and some of its features such as multithreading, lambda functions and so on are half-cooked. Good new is that we now have C++14 which allows us to: ● Use lambda functions. ● Multithreading API. ● Auto keyword. ● Move operator.
  • 20. BONUS: C++14 shoutout To start using C++14 make sure that your GCC compiler’s version is higher than 4.9 and compile with the flag -std=c++11. Also as for your assignments as your TA’s whether is acceptable to use C++11, 14. Your code will not compile in an old compiler or if they don’t specified the previously mentioned flags.
  • 21. Q&A