automake

gdb jumps previous lines after finish main

删除回忆录丶 提交于 2021-02-04 21:12:12
问题 I am trying to figure out why gdb is not behaving as expected. Not sure what triggered this. After seeing this problem, I wrote a minimal version of the main function. It finished the last line and exited properly. After adding one more function, the jumping came back. Even after commenting out the added line the jumping back does not go away. I am not sure this is related the the linking to my own library even after commenting out most of the code (not a single line reference my own library)

Automake flex output naming

家住魔仙堡 提交于 2021-01-28 20:08:37
问题 If if use, for example foo_SOURCES = bar.l then, automake generates via flex file bar.c . But, if I provide prefix AM_LFLAGS=-Psome_prefix , it generates lex.some_prefix.c , which is not known by other compilation rules, so it fails with bar.c: No such file or directory . Where is my mistake and how can I work around it? I really need prefix. 回答1: I think the only way around this is to write your own rule for the .l->.c translation. Something like: x_SOURCES = lex.some_prefix.c lex.some

autoconf AS_IF doesn't execute correct branch

我是研究僧i 提交于 2021-01-28 08:00:42
问题 I'm having a bit of a mystery in a autoconf script, specifically AS_IF . Here's the relevant code: AC_CHECK_FUNCS([eventfd], [AC_DEFINE([NN_HAVE_EVENTFD])]) AC_CHECK_FUNCS([pipe], [AC_DEFINE([NN_HAVE_PIPE])]) AC_CHECK_FUNCS([pipe2], [ AC_DEFINE([NN_HAVE_PIPE2]) CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" ]) AC_SEARCH_LIBS([socketpair], [], [AC_DEFINE([NN_HAVE_SOCKETPAIR])]) i.e. checking for their existance. These work correctly and define the correct symbols. In this case, only NN_HAVE_PIPE and NN

AM_PATH_PYTHON for python2 and python3

六眼飞鱼酱① 提交于 2021-01-27 06:59:25
问题 I am using automake's macro AM_PATH_PYTHON to find the pythondir variable. Till now I have been calling it without arguments which defaults to python 2.7 on Ubuntu. Now I also want to build it for python3.x (3.3 specifically). Is there a way where I can call AM_PATH_PYTHON([3]) to get python3.3 , store all the generated variables using AC_SUBST in a python3 specific variable and then call AM_PATH_PYTHON([2]) for python2 . I am doing this AM_PATH_PYTHON([3]) AC_SUBST(PYTHON3,$PYTHON) AC_SUBST

Linking against external libraries in gstreamer plugin using autotools

血红的双手。 提交于 2021-01-27 06:29:53
问题 I have written a gstreamer plugin using the boilerplate template refrenced in the gstreamer plugin writers guide (http://gstreamer.freedesktop.org/data/doc/gstreamer/head/pwg/html/chapter-building-boiler.html). I first built the plugin without full implementation of the chain function (basically an empty plugin that passed data from the source to sink with no changes). I am now implementing the chain function to perform a basic filtering on the data in the buffer. The filtering uses an

How a c++ program (.cpp) work with header(.h) and libtool (.la)?

不想你离开。 提交于 2020-07-10 07:29:50
问题 I have create a folder in linux called helloworld. Inside this folder have sub-directory: include lib src include/ In this directory I have create a header file called helloworld.h content are: class helloworld{ public: void getvalue(); }; lib/ In lib directory I have create a cpp file called helloworld.cpp content are mainly functions: #include<iostream> #include<helloworld.h> using namespace std; void helloworld::getvalue() { } src/ In src directory I have create a main cpp file called main

configure/make/make install的作用

£可爱£侵袭症+ 提交于 2020-04-04 06:22:18
configure/make/make install的作用_骨骨学习笔记_百度空间 configure/make/make install的作用 这些都是典型的使用GNU的AUTOCONF和AUTOMAKE产生的程序的安装步骤。 ./configure 是用来检测你的安装平台的目标特征的。比如它会检测你是不是有CC或GCC,并不是需要CC或GCC,它是个shell脚本。 make 是用来编译的,它从Makefile中读取指令,然后编译。 make install 是用来安装的,它也从Makefile中读取指令,安装到指定的位置。 AUTOMAKE和AUTOCONF 是非常有用的用来发布C程序的东西。如果你也写程序想使用AUTOMAKE和AUTOCONF,可以参考CNGNU.ORG上的相关文章。 来源: https://www.cnblogs.com/lexus/archive/2013/01/31/2887342.html

开发人员行走Unix的随身四艺

寵の児 提交于 2020-03-29 17:28:14
Unix系统永远只会越来越多,开发人员就没必要特意学习它们的安装、配置和管理了,就全部交给集成人员吧。 但开发人员行走于Unix之间,依然有四样东西要熟练。 一、VI 虽然Unix上的文本编辑器已经越来越好用,但不在Console前面,网速也不够连XWindows的时候,还是要依赖VI。 回想VI的时代背景,发现VI对开发人员已经周到得离谱了,热键多到你双手不离键盘就能完成大半编辑工作。 建议自己制作一张自己认为有用,但又经常忘记的命令的sheet,拿出考试的力气把它背熟。 二、文本处理 开发人员在Unix下干得最多的除了Make和除Bug外,大概就是处理日志文件、业务文件进行查错和统计了。 只会more和grep是不够的,开发老手会把awk,sed,grep,sort,unique,wc这些文本处理命令,通过管道玩具式的拆卸拼装,最后完成一件原本以为非编写大段代码不可的工作。周到的参数设定,让人再一次感叹那个简单的年代,复杂到极致的设计.......怪不得《Unix 编程艺术》的作者有那么骄傲的自觉。 比如车东的每月访问TOP10 统计脚本: awk -F ' t' '{ print $ 4 }' 2004_2 . txt| grep chedong . com / tech / | sort |uniq -c| sort -rn|head - 10 awk -F '/t'