<small id='C9tuo'></small><noframes id='C9tuo'>

    <i id='C9tuo'><tr id='C9tuo'><dt id='C9tuo'><q id='C9tuo'><span id='C9tuo'><b id='C9tuo'><form id='C9tuo'><ins id='C9tuo'></ins><ul id='C9tuo'></ul><sub id='C9tuo'></sub></form><legend id='C9tuo'></legend><bdo id='C9tuo'><pre id='C9tuo'><center id='C9tuo'></center></pre></bdo></b><th id='C9tuo'></th></span></q></dt></tr></i><div id='C9tuo'><tfoot id='C9tuo'></tfoot><dl id='C9tuo'><fieldset id='C9tuo'></fieldset></dl></div>

    <tfoot id='C9tuo'></tfoot>
      • <bdo id='C9tuo'></bdo><ul id='C9tuo'></ul>

    1. <legend id='C9tuo'><style id='C9tuo'><dir id='C9tuo'><q id='C9tuo'></q></dir></style></legend>

        {Makefile 错误}“命令在第一个目标之前开始.停下."

        {Makefile Error} quot;commands commence before first target. Stop.quot;({Makefile 错误}“命令在第一个目标之前开始.停下.)

        <tfoot id='n9XpR'></tfoot>

        <small id='n9XpR'></small><noframes id='n9XpR'>

                • <bdo id='n9XpR'></bdo><ul id='n9XpR'></ul>
                  <legend id='n9XpR'><style id='n9XpR'><dir id='n9XpR'><q id='n9XpR'></q></dir></style></legend>
                  <i id='n9XpR'><tr id='n9XpR'><dt id='n9XpR'><q id='n9XpR'><span id='n9XpR'><b id='n9XpR'><form id='n9XpR'><ins id='n9XpR'></ins><ul id='n9XpR'></ul><sub id='n9XpR'></sub></form><legend id='n9XpR'></legend><bdo id='n9XpR'><pre id='n9XpR'><center id='n9XpR'></center></pre></bdo></b><th id='n9XpR'></th></span></q></dt></tr></i><div id='n9XpR'><tfoot id='n9XpR'></tfoot><dl id='n9XpR'><fieldset id='n9XpR'></fieldset></dl></div>
                    <tbody id='n9XpR'></tbody>
                  本文介绍了{Makefile 错误}“命令在第一个目标之前开始.停下."的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我正在尝试制作一个与我的 Raspberry Pi 一起使用的 makefile,目的是使用 Pi 的相机板通过 opencv 检测人脸.但是我一直面临以下错误:

                  Makefile:12: *** 命令在第一个目标之前开始.停止.

                  我使用以下生成文件:

                  FLAGS = 'pkg-config --cflags opencv --libs opencv'CC = g++家 =/家/piLDFLAGS_CAMCV = -L$(HOME)/git/robidouille/raspicam_cv -lraspicamcvLDFLAGS_USER =-L$(HOME)/git/raspberrypi/userland/build/lib -lmmal_core -lmmal -$LDFLAGS_FACE = -l$(HOME)/git/emobot/libfacere0.04LDFLAGS = $(LDFLAGS_CAMCV) $(LDFLAGS_USER) $(LDFLAGS_FACE)包括 = -I$(HOME)/git/robidouille/raspicam_cv$(CC) -o emobot_test.exe: main.cpp $(INCLUDE) $(LDFLAGS)

                  LDFLAGS_CAMCVLDFLAGS_USER 是 raspicamcv 库所必需的,INCLUDE 是相关的头文件.LDFLAGS_FACE 需要在 opencv2.3 中检测人脸,因为 Pi 目前不支持 2.4.

                  我确信这个错误非常微不足道,但是关于 makefile 的清晰文档很少,如果有人能提供解决方案,我将不胜感激.

                  解决方案

                  喜欢:

                  <前>FLAGS = 'pkg-config --cflags opencv --libs opencv'CC = g++家 =/家/piLDFLAGS_CAMCV = -L$(HOME)/git/robidouille/raspicam_cv -lraspicamcvLDFLAGS_USER =-L$(HOME)/git/raspberrypi/userland/build/lib -lmmal_core -lmmal -$LDFLAGS_FACE = -l$(HOME)/git/emobot/libfacere0.04LDFLAGS = $(LDFLAGS_CAMCV) $(LDFLAGS_USER) $(LDFLAGS_FACE)包括 = -I$(HOME)/git/robidouille/raspicam_cv全部:emobot_testemobot_test:tab$(CC) -o emobot_test.exe main.cpp $(INCLUDE) $(LDFLAGS)

                  是文字按键,不知道如何将其插入到答案字段中.

                  说明:
                  $(CC) -o emobot_test... 是应该在目标调用时执行的命令.

                  all 是默认目标,当您只运行不带参数的 make 时会执行该目标.

                  all 取决于 emobot_test 目标emobot_test 不依赖于任何目标,但总是运行 $(CC) -o emobot_test... 以完成

                  I'm trying to produce a makefile for use with my Raspberry Pi, the intention is to use the Pi's camera board to detect faces with opencv. However I keep facing myself with the following error:

                  Makefile:12: *** commands commence before first target.  Stop.
                  

                  I use the following makefile:

                  FLAGS = 'pkg-config --cflags opencv --libs opencv'
                  CC = g++
                  HOME = /home/pi
                  LDFLAGS_CAMCV = -L$(HOME)/git/robidouille/raspicam_cv -lraspicamcv
                  LDFLAGS_USER =-L$(HOME)/git/raspberrypi/userland/build/lib -lmmal_core -lmmal -$
                  LDFLAGS_FACE = -l$(HOME)/git/emobot/libfacere0.04
                  LDFLAGS = $(LDFLAGS_CAMCV) $(LDFLAGS_USER)  $(LDFLAGS_FACE)
                  INCLUDE = -I$(HOME)/git/robidouille/raspicam_cv
                          $(CC) -o emobot_test.exe:  main.cpp $(INCLUDE) $(LDFLAGS)
                  

                  LDFLAGS_CAMCV and LDFLAGS_USER are required for the raspicamcv library and INCLUDE is the associated header file. LDFLAGS_FACE is needed to detect faces in opencv2.3 as 2.4 is currently unsupported by the Pi.

                  I'm certain this error is incredibly trivial however clear documentation about makefiles is few and far between if anyone can provide a solution I would be grateful.

                  解决方案

                  Smth like:

                  FLAGS = 'pkg-config --cflags opencv --libs opencv'
                  CC = g++
                  HOME = /home/pi
                  LDFLAGS_CAMCV = -L$(HOME)/git/robidouille/raspicam_cv -lraspicamcv
                  LDFLAGS_USER =-L$(HOME)/git/raspberrypi/userland/build/lib -lmmal_core -lmmal -$
                  LDFLAGS_FACE = -l$(HOME)/git/emobot/libfacere0.04
                  LDFLAGS = $(LDFLAGS_CAMCV) $(LDFLAGS_USER)  $(LDFLAGS_FACE)
                  INCLUDE = -I$(HOME)/git/robidouille/raspicam_cv
                  
                  all: emobot_test
                  
                  emobot_test:
                  tab$(CC) -o emobot_test.exe  main.cpp $(INCLUDE) $(LDFLAGS)
                  

                  <tab> is a literal keypress, donna how to insert it in the answer field.

                  Explanation:
                  $(CC) -o emobot_test... is a command which should be executed upon a target invocation.

                  all is the default target which is executed when you simply run make without parameters.

                  all depends on emobot_test target emobot_test doesn't depend on any target but always runs $(CC) -o emobot_test... for completion

                  这篇关于{Makefile 错误}“命令在第一个目标之前开始.停下."的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  C++ stl unordered_map implementation, reference validity(C++ stl unordered_map 实现,参考有效性)
                  C++: Is it possible to use a reference as the value in a map?(C++:是否可以使用引用作为映射中的值?)
                  Where ampersand quot;amp;quot; can be put when passing argument by reference?(其中符号“amp;通过引用传递参数时可以放置吗?)
                  Why can a non-const reference parameter be bound to a temporary object?(为什么可以将非常量引用参数绑定到临时对象?)
                  What is a dangling reference?(什么是悬空引用?)
                  C++ reference changes when push_back new element to std::vector(当 push_back 新元素到 std::vector 时,C++ 引用发生变化)
                • <legend id='Jks7t'><style id='Jks7t'><dir id='Jks7t'><q id='Jks7t'></q></dir></style></legend>

                          <bdo id='Jks7t'></bdo><ul id='Jks7t'></ul>

                          <i id='Jks7t'><tr id='Jks7t'><dt id='Jks7t'><q id='Jks7t'><span id='Jks7t'><b id='Jks7t'><form id='Jks7t'><ins id='Jks7t'></ins><ul id='Jks7t'></ul><sub id='Jks7t'></sub></form><legend id='Jks7t'></legend><bdo id='Jks7t'><pre id='Jks7t'><center id='Jks7t'></center></pre></bdo></b><th id='Jks7t'></th></span></q></dt></tr></i><div id='Jks7t'><tfoot id='Jks7t'></tfoot><dl id='Jks7t'><fieldset id='Jks7t'></fieldset></dl></div>
                        • <tfoot id='Jks7t'></tfoot>
                            <tbody id='Jks7t'></tbody>

                          <small id='Jks7t'></small><noframes id='Jks7t'>