Controlled Experiment Tasks
In this controlled experiment you are required to do two sub-tasks: the first
sub-task requires you to detect at least 6 code smells. A code smell can be one
of the following:
The second sub-task requires to do some enhancement and refactoring operations.
Each task has a time limit, and you are required to stop if the time limit
passes.
-
Task1
Based on Makefile1 Makefile:[download
Makefile1, SYMake output,
SDG]
First Sub-Task: Code Smell Detection [Time:15 mins]
Detect at least 6 code smells
Second Sub-Task: Enhancing & Refactoring [Time:8 mins]
- Extract prerequisites “mconbere main.pb.h” to a new target “sub-install” and apply changes to all places use those
prerequisites.
- Rename target “install” to “setup”
- Rename variable “PROTOC” to “protoProgram”
- Rename variable “CXXFLAGS” to “CPP_FGs”
-
Task2
Based on Makefile2 Makefile:[download
Makefile2, SYMake output,
SDG]
First Sub-Task: Code Smell Detection [Time:
15 mins]
Detect at least 6 code smells
Second Sub-Task: Enhancing & Refactoring [Time:10 mins]
- Extract prerequisites “api.c conf.c” to a new target “apiConfig” and apply changes to all places use those
prerequisites.
- Rename target “server” to “server.o”
- Rename variable “C_FILES” to “CSourceFiles”
- Rename variable “PROG” to “Server”
-
Task3
Based on Makefile3 Makefile:[download
Makefile3, SYMake output,
SDG]
First Sub-Task: Code Smell Detection [Time:
15 mins]
Detect at least 6 code smells
Second Sub-Task: Enhancing & Refactoring [Time:10 mins]
- Extract prerequisites “events.cc.pd util.cc.pd” to a new target “install-events” and apply changes to all places use those
prerequisites.
- Rename target “repackage-win32-installer” to “win-pkg-install”
- Rename variable “AB_CD” to “Language”
- Rename the prefix “XPI_” of variable “XPI_PKGNAME”
to “ADDON_”.
-
Task4
Based on Makefile4 Makefile:[download
Makefile4, SYMake output,
SDG]
First Sub-Task: Code Smell Detection [Time:
18 mins]
Detect at least 6 code smells
Second Sub-Task: Enhancing & Refactoring [Time:10 mins]
- Extract prerequisites “zlib.h
zconf.h” to a new target “install-zconf” and apply changes to all places use those
prerequisites.
- Rename target “zutil.o” to “config_utils.o”
- Rename variable “LIBNAME” to “mainProgram”
- Rename variable “TEST_OBJS” to “OutputFiles
”
Task5
Based on Makefile5 Makefile:[download
Makefile5, SYMake output,
SDG]
First Sub-Task: Code Smell Detection [Time:
25 mins]
Detect at least 6 code smells
Second Sub-Task: Enhancing & Refactoring [Time:10 mins]
- Extract prerequisites “libcpupower.hh.cb sysfs.hh.cb” to a new target “install-hh.cb” and apply changes to all places use those
prerequisites.
- Rename target “libcpupower.so.maj” to “libcpupower.so”
- Rename variable “CFLAGS” to “CPP_Flags”
- Rename the prefix “LIB_” of variable “LIB_SRC”
to “Files_”.
Task6
Based on Makefile6 Makefile:[download
Makefile6, SYMake output,
SDG]
First Sub-Task: Code Smell Detection [Time:
20 mins]
Detect at least 6 code smells
Second Sub-Task: Enhancing & Refactoring [Time:10 mins]
- Extract prerequisites “emacs.dvi emacs-xtra.dvi” to a new target “install-dvi” and apply changes to all places use those
prerequisites.
- Rename target “srcdir/info” to “info.out”
- Rename variable “mkinfodir” to “MakeInfo”
- Rename the prefix “tex_” of the variable at line 7 and all references to
the same variable to “txt_”.