makefile related

Discussion in 'C' started by answerme, Mar 18, 2008.

  1. answerme

    answerme New Member

    Joined:
    Dec 17, 2007
    Messages:
    114
    Likes Received:
    0
    Trophy Points:
    0
    Iam comipliing my project but it showing this error


    Code:
    NMAKE : fatal error U1064: MAKEFILE not found and no target specified
    Does anyone have solution
     
  2. asadullah.ansari

    asadullah.ansari TechCake

    Joined:
    Jan 9, 2008
    Messages:
    356
    Likes Received:
    14
    Trophy Points:
    0
    Occupation:
    Developer
    Location:
    NOIDA
    If you are using gmake commmand for your project

    then use

    gmake -f MakeFileName -target

    example: suppose target is all.stub
    and MakeFileName is Makefile.TelProject

    command will be
    gmake -f Makefile.TelProject all.stub
     
  3. asadullah.ansari

    asadullah.ansari TechCake

    Joined:
    Jan 9, 2008
    Messages:
    356
    Likes Received:
    14
    Trophy Points:
    0
    Occupation:
    Developer
    Location:
    NOIDA
    target , you have define it may be for some specific like unix, all.stub(all things) etc. It depends on you wahtever you wanna use.

    You have to define in your makefile as target as like

    Code:
    
    #  targets
    .PHONY:	
    
    all:	unix.stub \
    	all.stub \
    
    all.test:
    	@echo "\n#### Test cases####\n"
    
    
    
    
    all.unix:
    	@echo "\n#### making file ####\n"
    	@$(MAKE) --no-print-directory -f dir
    	
    all.stub:
    	@echo "\n#### making file ####\n"
    	@$(MAKE) --no-print-directory -f dir
    clean:
    	@echo "\n#### cleaning file ####\n"
    	@$(MAKE) --no-print-directory -f dir clean
    	@echo "\n#### cleaning file2####\n"
    	@$(MAKE) --no-print-directory -f file2.mkf clean	
    	@echo "\n#### done ####\n"
    
    # ---- INCLUDE ----
    include $File
    
    # eof
    
    

    I dont know about your Makefile. If u post your makefile source code then only i can tell you exactly solution to your probls
     
  4. answerme

    answerme New Member

    Joined:
    Dec 17, 2007
    Messages:
    114
    Likes Received:
    0
    Trophy Points:
    0
    first of all sorry ,i did not intentionally post the same query twice ,it was done mistakenly.
    Ok i am sending my makefile here ,kindly see it ,plz let me know what can i do

    Code:
    #
    # filename = Makefile
    #
    # NMAKE makefile
    #
    
    #
    #   RTXC Version
    #   Copyright (c) 1986-1996.
    #   Embedded System Products, Inc.
    #   ALL RIGHTS RESERVED
    #
    
    RTXCROOT =.
    # Duplm = 0 normal, 1-Hot Standby
    DUPLM=0
    VER=1028
    F=try
    #in sw.opt
    #-Xkeep-assembly-file
    #-X11
    
    SYSMACRO = $(RTXCROOT)\include\sysmacro.mak
    SWMACRO = $(RTXCROOT)\switch.mak
    MAKEFILE=makefile
    
    INCLUDE_LOOPBACK   = 1
    INCLUDE_ENET       = 0
    INCLUDE_SLIP       = 0
    INCLUDE_PPP        = 0
    PPP_LOOPBACK       = 0
    
    INCLUDE_TCP   = 1
    INCLUDE_HTTP  = 0
    # to use common lib we have to enable include snmp
    INCLUDE_SNMP  = 1 # make it =1 to use SNMP
    # to use common makefiles we have to define 0 or 1 for CSTA
    INCLUDE_CSTA = 0
    INCLUDE_SMTP  = 0
    INCLUDE_RIP   = 0
    
    INCLUDE_V5_SRC = 0 # make it =1 to use V5 in IRIS Plus
    
    #!if $(INCLUDE_V5_SRC) == 1
    
    # define no of interfaces and no of e1 links in the interfaces this 
    # will be used to build V5 stack for said no of interfaces and with 
    #said no of e1 links per interface. make sure stack code re compiles 
    # and  the stack libraries are built again. -PRAFULLA
    #NUM_OF_V5_INTERFACES=2
    #NUM_OF_E1V5_LINKS=2
    #
    #!endif
    
    !include $(SYSMACRO)
    !include $(EXNMACRO)
    
    !if "$(REFPLAT)" == "EVB505"
    !error Due to memory limitations, the example does not support the reference platform EVB505.
    !endif
    APUTILHDR  =
    #APUTILHDR  =$(APPUTIL)\elic.h
    #APPLHDR  = 
    
    ################################################################################
    #    System and Application files compile/assemble list
    ##temp.o object.o contain.o array.o pstring.o \
    #			 lists.o dict.o random.o semaphor.o ptime.o  pprocess.o thread.o
    	
    ################################################################################
    
    APPHDRS = $(MINC)\netdemo.h	$(INC)\sysopts.h
    
    SWRTHDRS = $(MINC)\cqueue.h $(MINC)\cclock.h $(MINC)\csema.h \
    		$(INC)\rtxcapi.h $(INC)\rtxcopts.h $(MINC)\cres.h \
    		$(INC)\rtxstruc.h $(INC)\typedef.h
    
    SWHDRS = $(SWINC)\acd.h $(SWINC)\cdb.h $(SWINC)\data.h $(SWINC)\err_tab.h \
    		$(SWINC)\isbx.h $(SWINC)\keys.h $(SWINC)\msg.h $(SWINC)\num.h \
    		$(SWINC)\pc.h $(SWINC)\pdef.h $(SWINC)\pi.h $(SWINC)\romcd.h \
    		$(SWINC)\sacco.h $(SWINC)\struct.h $(SWINC)\timer.h $(SWINC)\func.h\
    		$(SWINC)\bgrp.h switch.mak makefile $(SWRTHDRS)
    
    
    #
    #   Demo application files macro csminit.o csmdrv.o
    #
    APPTASKS =  rtxcmain.o rtxcbug.o
    		 
    SHELL    =  applctl.o \
    # if (INCLUDE_SNMP) == 1
    	snmpcmd.o snmpvars.o snmpconf.o rfc1213.o \
    			coralsnm.o corltrap.o
    # endif
    # stelnet.o cmdutil.o 
    
    NETTASKS = printstk.o vscreen.o 
    
    REFPLAT_OBJ =   cspcb.o sysrom.o  IO860.o  Uart.o PPCintr.o \
    #!if $(DUPLM) == 1
    				i2c.o spi.o \
    #!endif
    				Idma.o Csmisr.o excp.o intrs.o pcmdrv.o
    
    LLAPPIF  = netstart.o netconf.o netlpb.o
    
    SWOBJS = acd.o alarm.o alc.o atc.o auto.o bgrp.o cdb.o clock.o cstasw.o \
    		conf.o ctsrv.o disa.o dlc.o dtmf.o feature.o hddpc.o init.o \
    		is_func.o libs.o lprog.o mfc.o mode.o modem.o msgs.o musac.o opr.o \
    		oprprog.o pi.o pisrv.o pmsrv.o pprog.o prgsrv.o print.o \
    		printf.o qsig.o rep.o router.o rtc.o rxr.o show.o skts.o \
    		sms.o snap.o spl_fn.o state.o super.o sup_fn.o swflash.o \
    		swmain.o swprog.o swsac.o syncdb.o sys_alrm.o telnet.o tone.o \
    		version.o
    
    OBJECTS  =  $(SWOBJS) $(RTXCGEN)  $(NETTASKS) $(LLAPPIF) \
    			$(REFPLAT_OBJ) $(SHELL) $(APPTASKS) start.o
    
    #####################################################################
    #
    # all: Primary target, creates all rtxcnet libraries, rtxc kernel
    #      net example
    #
    #####################################################################
    
    !include $(EXNTARGS)
    
    !include $(EXTARGS)
    
    #####################################################################
    #
    # Source files targets specifying file inter-dependencies
    #
    #####################################################################
    
    start.o :	$(REFPLATDIR)\start.s $(ASMOPT) makefile
    intrs.o :	$(REFPLATDIR)\intrs.s $(ASMOPT) makefile
    
    cspcb.o:	$(REFPLATDIR)\cspcb.c $(STDIOH) makefile
    excp.o :	$(REFPLATDIR)\excp.c $(STDIOH) makefile
    
    #
    # Net/App interface  
    # 
    
    netlpb.o:	$(APPUTIL)\netlpb.c $(GENHDR) $(APPHDRS) $(STKHDRS) $(SWOPT) makefile
    
    netconf.o:	$(APPUTIL)\netconf.c $(APPHDRS) $(SWOPT) makefile
    
    netstart.o:	$(APPUTIL)\netstart.c $(APPHDRS) $(STKHDRS) $(STDIOH) $(SWOPT) makefile
    #
    # Common NET Example application files
    #
    #shell.o:	$(APPUTIL)\shell.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #app_ping.o:	$(APPUTIL)\app_ping.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #clintcmd.o:	$(APPUTIL)\clintcmd.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #dumpcmd.o:	$(APPUTIL)\dumpcmd.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #misccmd.o:	$(APPUTIL)\misccmd.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #statcmd.o:	$(APPUTIL)\statcmd.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #smtpcmds.o:	$(APPUTIL)\smtpcmds.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #cmdutil.o:	$(APPUTIL)\cmdutil.c  $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    printstk.o:	$(APPUTIL)\printstk.c $(APPHDRS) $(SWOPT) makefile
    
    vscreen.o:	$(APPUTIL)\vscreen.c $(APPHDRS) $(STKHDRS) $(STDIOH) $(SWOPT) makefile
    
    #ctcpecho.o:	$(APPUTIL)\ctcpecho.c  $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #cudpecho.o:	$(APPUTIL)\cudpecho.c  $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #ctcpsink.o:	$(APPUTIL)\ctcpsink.c  $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #cudpsink.o:	$(APPUTIL)\cudpsink.c  $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #stcpecho.o:	$(APPUTIL)\stcpecho.c  $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #stcpsink.o:	$(APPUTIL)\stcpsink.c  $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #menus.o:	$(APPUTIL)\menus.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    # rtxcbug/utilities related dependencies and resulting incremental link, cbug.o
    # 
    rtxcmain.o:	$(APPUTIL)\rtxcmain.c $(APPHDRS) $(STKHDRS) $(SWOPT) makefile
    
    rtxcbug.o :	$(APPUTIL)\rtxcbug.c $(REFPLATDIR)\rtxcbug.h $(GENHDR) $(SWOPT) makefile
    
    #config.o:	$(APPUTIL)\config.c $(GENHDR) $(SWOPT)
    #
    #APPLICATION FILES
    #
    #    Application Tasks
    #
    #appl.o:    $(APPL)\appl.c  $(GENHDR) $(KERNHDR) $(SWOPTS)
    #
    #demo.o: 	$(APPL)\demo.cpp  $(GENHDR) $(KERNHDR)
    #
    applctl.o:	$(APPUTIL)\applctl.c $(APPHDRS) $(STKHDRS) $(SWOPT) makefile
    
    #stelnet.o:	$(APPUTIL)\stelnet.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #elic.o:		$(APPUTIL)\elic.c $(APPHDRS) $(APUTILHDR)  $(STKHDRS) $(SWOPT)
    #
    #endpoint.o:	$(APPUTIL)\endpoint.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #csmdrv.o:	$(APPUTIL)\csmdrv.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #csminit.o:	$(APPUTIL)\csminit.c $(APPHDRS) $(STKHDRS) $(SWOPT)
    #
    #prog.o:		$(APPUTIL)\prog.c $(APPHDRS) $(APUTILHDR)  $(STKHDRS) $(SWOPT)
    #
    #    Application Tasks
    #
    #demo.o: 	demo.c $(GENHDR) $(KERNHDR)
    
    mainrom.o 	:   $(REFPLATDIR)\mainrom.c 
    
    main.o 	:       $(REFPLATDIR)\main.c 
    
    sysrom.o  	:   $(REFPLATDIR)\sysrom.c makefile
    
    Flash.o  	:   $(REFPLATDIR)\flash.c 
    
    isr9054.o	:   $(REFPLATDIR)\isr9054.c 
    
    IO860.o   	:   $(REFPLATDIR)\io860.c  makefile
    
    InitDma.o  	:   $(REFPLATDIR)\InitDma.c   
    
    #BspSup.o    :   $(REFPLATDIR)\BspSup.c   makefile
    #
    Uart.o      :   $(REFPLATDIR)\Uart.c  makefile
    
    PPCintr.o   :   $(REFPLATDIR)\PPCintr.c  makefile
    
    Csmisr.o   :    $(REFPLATDIR)\Csmisr.c  makefile
    
    Idma.o   	:   $(REFPLATDIR)\Idma.c     makefile 
    
    i2c.o   	:   $(REFPLATDIR)\i2c.c      makefile
    
    spi.o   	:   $(REFPLATDIR)\spi.c      makefile
    pcmdrv.o   	:   $(REFPLATDIR)\pcmdrv.c   makefile
    
    mmu.o      :    $(REFPLATDIR)\mmu.c 
    
    SeriDwld.o :    $(REFPLATDIR)\SeriDwld.c 
    
    BemSup.o   :    $(REFPLATDIR)\BemSup.c  
    
    BspAll.o   :    $(REFPLATDIR)\BspAll.c $(REFPLATHDR)  $(GENHDR)
    
    #
    #  RTXCgen Files
    #
    # following file are moved from extagrs.mak by vats
    
    ctask.o: $(MSRC)\ctask.c $(MINC)\ctask.h $(KERNHDR) $(SWOPT) makefile
    
    csema.o:	$(MSRC)\csema.c $(MINC)\csema.h $(KERNHDR) $(SWOPT) makefile
    
    cmbox.o:	$(MSRC)\cmbox.c $(MINC)\cmbox.h $(KERNHDR) $(SWOPT) makefile
    
    cpart.o:	$(MSRC)\cpart.c $(MINC)\cpart.h $(KERNHDR) $(SWOPT) makefile
    
    cqueue.o:	$(MSRC)\cqueue.c $(MINC)\cqueue.h $(KERNHDR) $(SWOPT) makefile
    
    cres.o:		$(MSRC)\cres.c $(MINC)\cres.h $(KERNHDR) $(SWOPT) makefile
    
    filecb.o: $(MSRC)\filecb.c $(KERNHDR) $(SWOPT) makefile
    
    cclock.o:	$(MSRC)\cclock.c $(MINC)\cclock.h $(KERNHDR) $(SWOPT) makefile
    
    !include $(SWMACRO)
    
    #####################################################
    #
    #  Clean Target deletes all files not include in the
    #  original distribution
    #
    #####################################################
    
    cleanall:	\
    	clnrtos \
    	clncsp \
    	clnstdio \
    	clnrtl \
    	cleannet \
    	clnexam
    
    !include $(EXRULES)
    # end of makefile
    
     
  5. asadullah.ansari

    asadullah.ansari TechCake

    Joined:
    Jan 9, 2008
    Messages:
    356
    Likes Received:
    14
    Trophy Points:
    0
    Occupation:
    Developer
    Location:
    NOIDA
    gmake "FileName of MakeFile" target name

    >> That's sit.
     
  6. answerme

    answerme New Member

    Joined:
    Dec 17, 2007
    Messages:
    114
    Likes Received:
    0
    Trophy Points:
    0
    Hye again
    iam giving the command as per your saying but getting error

    Code:
    makefile:55: *** commands commence before first target. 
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice