Would you give me a hand to solve problems related to Makefile working on(Linux, Cygwin). I want to make binary files by using Makefile. I've currently conducted a project about 3d reconstruction. I've use Linux(Ubuntu) and Cygwin(Windows). There are some problems when i used Makefile included with source codes.(I received from online). I entered 'make' on command line and I got errors related to Make. Here these are.
[Type1]
make[1]: Entering directory `/home/curtis/bundlersrc/lib/5point'
make[1]: Nothing to be done for `all'.
make[3]: Entering directory `/home/curtis/bundlersrc/lib/ann_1.1_char/src'
make[3]: Nothing to be done for `targets'.
make[1]: Entering directory `/home/curtis/bundlersrc/lib/imagelib'
make[1]: Nothing to be done for `all'.
[Type2]
BundlerApp.h:620:32: error: cannot call constructor ‘SkeletalApp::BundlerApp’ directly [-fpermissive]
BundlerApp::BundlerApp(); ^
BundlerApp.h:620:32: error: for a function-style cast, remove the redundant ‘::BundlerApp’ [-fpermissive]
BundlerApp.cpp: In member function ‘virtual void BundlerApp::ProcessOptions(int, char**)’:
[Type3]
make[1]: Leaving directory `/home/curtis/bundlersrc/src'
make: *** [default] Error 2
One of Make file contains like these shell code
LIB = lib5point.a
TARGET = $(LIB)
OBJS = 5point.o poly1.o poly3.o
CC=gcc
OPTFLAGS=-O3
OTHERFLAGS=-Wall
MATRIX_PATH=../matrix
IMAGELIB_PATH=../imagelib
CPPFLAGS = $(OTHERFLAGS) $(OPTFLAGS) -I$(MATRIX_PATH) -I$(IMAGELIB_PATH)
all: $(TARGET)
$(TARGET): $(OBJS)
ar r $@ $(OBJS)
cp $@ ..
clean:
rm -f $(TARGET) *.o *~
I couldn't understand why errors came up and about (.a)file. Is there a something wrong?
Top level Makefile contains these code
ANN_TARGET = linux-g++-shared
OS = $(shell uname -o)
ifeq ($(OS), Cygwin)
ANN_TARGET = win32-g++-shared
endif
default:
# Make libraries
cd lib/5point; $(MAKE)
cd lib/ann_1.1_char; $(MAKE) $(ANN_TARGET)
cd lib/imagelib; $(MAKE)
cd lib/matrix; $(MAKE)
cd lib/sba-1.5; $(MAKE)
cd lib/sfm-driver; $(MAKE)
# Auxiliary libraries
cd lib/lapack; $(MAKE)
cd lib/minpack; $(MAKE)
cd lib/blas; $(MAKE)
cd lib/cblas; $(MAKE)
cd lib/f2c; $(MAKE)
# Main program
cd src; $(MAKE)
clean:
cd lib/5point; $(MAKE) clean
cd lib/ann_1.1_char; $(MAKE) clean
cd lib/imagelib; $(MAKE) clean
cd lib/matrix; $(MAKE) clean
cd lib/sba-1.5; $(MAKE) clean
cd lib/sfm-driver; $(MAKE) clean
cd lib/lapack; $(MAKE) clean
cd lib/minpack; $(MAKE) clean
cd lib/blas; $(MAKE) clean
cd lib/cblas; $(MAKE) clean
cd lib/f2c; $(MAKE) clean
cd src; $(MAKE) clean
rm -f bin/bundler bin/KeyMatchFull
rm -f lib/*.a`
Thanks for reading my question,