Tools – Ant-MakeEtc 1 CSCE 747 Fall 2013 CSCE 747 Software Testing and Quality Assurance Tools 12 – Hamcrest 10/02/2013 1.

Slides:



Advertisements
Similar presentations
Makefiles. makefiles Problem: You are working on one part of a large programming project (e. g., MS Word).  It consists of hundreds of individual.c files.
Advertisements

The make Utility Programming Tools and Environments Winter 2006.
Separate compilation Large programs are generally separated into multiple files, e.g. tuples.h, ray.h, ray.c, tuples.c main.c With several files, we can.
ANT: Another Nice Tool Ali Beyad October 1, 2003.
ANT: Another Nice Tool Ali Beyad October 1, 2003.
The Makefile utility ABC – Chapter 11, Motivation Small programs single file “Not so small” programs : –Many lines of code –Multiple components.
MC365 Ant. Today We Will Cover: Overview of Ant Installing Ant Using the Ant command line tool Various Ant commands available Using Ant in Eclipse.
Fall 2007CS 2251 Programming Tools Eclipse JUnit Testing make and ant.
1 The Makefile Utility ABC – Chapter 11,
Copyright © 2008 Pearson Addison-Wesley. All rights reserved. Chapter 12 Separate Compilation Namespaces Simple Make Files (Ignore all class references.
The Makefile Utility ABC – Chapter 11, Motivation Small programs single file “Not so small” programs : –Many lines of code –Multiple components.
Introduction to Make Updated by Prasad Spring 2000.
About apache ant. Hello world with ant HelloWorldWithAnt.htmlhttp://ant.apache.org/manual/tutorial- HelloWorldWithAnt.html.
2000 Copyrights, Danielle S. Lahmani UNIX Tools G , Fall 2000 Danielle S. Lahmani Lecture 9.
CS465 - Unix C Programming (cc/make and configuration control)
The Makefile Utility ABC – Chapter 11, Motivation Small programs single file “Not so small” programs : –Many lines of code –Multiple components.
Lecture 8  make. Overview: Development process  Creation of source files (.c,.h,.cpp)  Compilation (e.g. *.c  *.o) and linking  Running and testing.
Makefiles. makefiles Problem: You are working on one part of a large programming project (e. g., MS Word).  It consists of hundreds of individual.cpp.
리눅스 : Lecture 5 UNIX 유틸리티 : text editor, compilation (make), …
Ant Build Tools.  Creating a product from source may take several steps: Compile Link Copy files to various directories Remove intermediate files Generate.
Adv. UNIX: large/131 Advanced UNIX v Objectives of these slides: –learn how to write/manage large programs consisting of multiple files, which.
July 2011CMSC 341 CVS/Ant 1 CMSC 341 Java Packages Ant CVS Project Submission.
Ant Presentation by: Bart Taylor. What is Ant? The simple definition: A Java-based build tool The Official Definition: “Apache Ant is a Java-based build.
Makefile M.A Doman. Compiling multiple objects Card.cpp -> Card.o Deck.cpp -> Deck.o main.cpp -> main.o main.o Deck.o Card.o -> Dealer.exe.
GNU Make Computer Organization II 1 © McQuain What is make ? make is a system utility for managing the build process (compilation/linking/etc).
Makefiles. Multiple Source Files (1) u Obviously, large programs are not going to be contained within single files. u C provides several techniques to.
Data Display Debugger (DDD)
Makefiles CARYL RAHN. Separate compilation Large programs are generally separated into multiple files, e.g. main.c addmoney.c removemoney.c money.h With.
Lecture 8  make. Using make for compilation  With medium to large software projects containing many files, it’s difficult to: Type commands to compile.
Make: File Dependency System Lecturer: Prof. Andrzej (AJ) Bieszczad Phone: “UNIX for Programmers and Users” Third.
Linux development Lection What we gonna do today Root privileges Software packages Managing software packages Build procedures Build components.
Emacs, Compilation, and Makefile C151 Multi-User Operating Systems.
Build Tools 1. Building a program for a large project is usually managed by a build tool that controls the various steps involved. These steps may include:
GNU Make Computer Organization II 1 © McQuain What is make ? make is a system utility for managing the build process (compilation/linking/etc).
UNIX Development: g++ and make CS 2204 Class meeting 8 Created by Doug Bowman, 2001 Modified by Mir Farooq Ali, 2002.
SG Introduction to ANT scmGalaxy Author: Rajesh Kumar
An Introduction to Ant. What is Ant? How do you use it? Why would you want to?
Week Seven Agenda Link of the week Review week six lab assignment This week’s expected outcomes Next lab assignment Break-out problems Upcoming deadlines.
Multiple file project management & Makefile
Large Program Management: Make; Ant
CSE 303 Lecture 17 Makefiles reading: Programming in C Ch. 15
Prof: Dr. Shu-Ching Chen TA: Hsin-Yu Ha Fall 2015
NAnt Build Tool CSE784 : ProjectCentralNet Prof : Dr. Jim Fawcett
Large Program Management: Make; Ant
Makefiles Caryl Rahn.
Makefile Tutorial CIS5027 Prof: Dr. Shu-Ching Chen
What is make? make is a system utility for managing the build process (compilation/linking/etc). There are various versions of make; these notes discuss.
Prof: Dr. Shu-Ching Chen TA: Yimin Yang
Prof: Dr. Shu-Ching Chen TA: Samira Pouyanfar Hector Cen Fall 2017
Ant.
Prof: Dr. Shu-Ching Chen TA: Hsin-Yu Ha
Large Program Management: Make; Ant
Large Program Management: Make; Ant
Makefiles and the make utility
Large Program Management: Make; Ant
CSE 390 Lecture 8 Large Program Management: Make; Ant
CMPSC 60: Week 4 Discussion
Large Program Management: Make; Ant
Nilanjan Banerjee Java Packages Ant CVS Project Submission
Large Program Management: Make; Ant
Large Program Management: Make; Ant
Large Program Management: Make; Ant
GNU Make.
Large Program Management: Make; Ant
Makefiles and the make utility
Makefiles, GDB, Valgrind
CSE 390 Lecture 8 Large Program Management: Make; Ant
What is make? make is a system utility for managing the build process (compilation/linking/etc). There are various versions of make; these notes discuss.
Large Program Management: Make; Ant
Large Program Management: Make, Ant
Presentation transcript:

Tools – Ant-MakeEtc 1 CSCE 747 Fall 2013 CSCE 747 Software Testing and Quality Assurance Tools 12 – Hamcrest 10/02/2013 1

Tools – Ant-MakeEtc 2 CSCE 747 Fall 2013 Ant vs Make  Make (Unix) – build systems with minimal compilation  /wiki/Make_(software)  Look at edits see which files need to be recompiled p.c  p.o  Ant (Apache)  ache_Ant

Tools – Ant-MakeEtc 3 CSCE 747 Fall CSCE MAKE(1) LOCAL USER COMMANDS MAKE(1) NAME make - GNU make utility to maintain groups of programs SYNOPSIS make [ -f makefile ] [ options ]... [ targets ]... WARNING This man page is an extract of the documentation of GNU make. It is updated only occasionally, because the GNU project does not use nroff. For complete, current documentation, refer to the Info file make.info which is made from the Texinfo source file make.texi. DESCRIPTION - The purpose of the make utility is to: 1) determine automatically which pieces of a large program need to be recompiled, and 2) issue the commands to recompile them.

Tools – Ant-MakeEtc 4 CSCE 747 Fall 2013 Make Advantages - CSCE  Make saves time - both typing and recompilation  The Makefile documents the dependencies and how to build the software.  For distribution of software one can `make' and `make install' a package with knowing anything about it.

Tools – Ant-MakeEtc 5 CSCE 747 Fall 2013 Makefiles - Make Specification Files - CSCE  Definitions of the form  name=value  Target Groups of the form target_1 : dependency list_1 cmdlist_1 target_2 : dependencylist_2 cmdlist_2...

Tools – Ant-MakeEtc 6 CSCE 747 Fall 2013 A Simple Makefile - CSCE # Makefile Example prog: main.o routines.o cc -o prog main.o routines.o # Each command line starts with a \tab main.o: main.c defs.h cc -c main.c routines.o: routines.c defs.h cc -c routines.c

Tools – Ant-MakeEtc 7 CSCE 747 Fall 2013 Make Tree actually forest - CSCE  To determine if we make a target we check the modification time of all its dependencies (things/files it depends on); if any is newer rebuild the target  Macros –  Built-in Rules –  make –n  make -p

Tools – Ant-MakeEtc 8 CSCE 747 Fall 2013 # Another Makefile Example - CSCE Slide I/O Buffering FILES = Makefile defs.h main.c routines.c OBJS = main.o routines.o LIBES = -lm CFLAGS = -g LP = /fac/matthews/bin/p2c INSTALL_DIR = /fac/matthews/bin prog: main.o routines.o $(CC) $(CFLAGS) $(OBJS) $(LIBES) -o prog $(OBJS): defs.h cleanup: -rm *.o -du install: prog mv prog $(INSTALL_DIR ) print: $(FILES) pr $? > /tmp/manton $(LP) /tmp/manton touch print -rm /tmp/manton

Tools – Ant-MakeEtc 9 CSCE 747 Fall 2013 Make Implementation Algorithm - CSCE Slide I/O Buffering Procedure newest(target) If target is not in the target tree then If file exists return(modification_time) Else return(FAIL) Else min = modification_time of target Foreach child in the dependency list Do child_time = newest(child) If child_time < min Then min = child_time End If min < modification_time of target Then build(target) min = now EndIf End Begin {Main} Parse Specification File Build Dependency Tree newest(target) End Build(target)?

Tools – Ant-MakeEtc 10 CSCE 747 Fall 2013 GNU Make - CSCE   ``Makefile conventions'' (147 k characters) of the GNU Coding Standards (147 k characters). ``Makefile conventions'' (147 k characters)GNU Coding Standards (147 k characters)  Downloading GNU ftp server:   Documentation for Make Documentation for Make 

Tools – Ant-MakeEtc 11 CSCE 747 Fall 2013 Downloading - CSCE   mv make-3.82.tar.gz GNU  cd GNU  tar xcfz make-3.82.tar.gz  more INSTALL README ./configure -- takes a while

Tools – Ant-MakeEtc 12 CSCE 747 Fall 2013 Ant

Tools – Ant-MakeEtc 13 CSCE 747 Fall 2013 Why Ant?  Make-like tools are inherently shell-based: they evaluate a set of dependencies, then execute commands not unlike what you would issue on a shell.  Makefiles are inherently evil as well.  the dreaded tab problem.  configuration files are XML-based  Cross platform

Tools – Ant-MakeEtc 14 CSCE 747 Fall 2013 Writing a Simple Buildfile  A project has three attributes:  name  default  Basedir  Targets  Tasks  Builtin or write your own

Tools – Ant-MakeEtc 15 CSCE 747 Fall 2013 Ant: example Buildfile simple example build file

Tools – Ant-MakeEtc 16 CSCE 747 Fall 2013 Ant <target name="compile" depends="init" description="compile the source " > <target name="dist" depends="compile" description="generate the distribution" >

Tools – Ant-MakeEtc 17 CSCE 747 Fall 2013 Ant <target name="clean" description="clean up" >