实践Linux的理论
全部博文(61)
分类: LINUX
2014-07-04 07:25:57
原文地址:Ubuntu12.04安装LTIB 作者:清平世
点击(此处)折叠或打开
点击(此处)折叠或打开
[AESKey.o] Error 1的错误啊?
将下面内容保存为:elftosb-types_h-fix.patch并放在/opt/freescale/pkgs/目录
点击(此处)折叠或打开
-
diff -rupN elftosb-11.09.01/common/stdafx.h elftosb-11.09.01-new/common/stdafx.h
-
--- elftosb-11.09.01/common/stdafx.h 2011-03-01 05:05:19.000000000 +0100
-
+++ elftosb-11.09.01-new/common/stdafx.h 2013-05-07 06:03:56.399989483 +0200
-
@@ -27,7 +27,7 @@
-
// For Linux systems only, types.h only defines the signed
-
// integer types. This is not professional code.
-
// Update: They are defined in the header files in the more recent version of redhat enterprise gcc.
-
-#include "/usr/include/sys/types.h"
-
+#include <sys/types.h>
-
#include <stdint.h>
-
//typedef unsigned long uint32_t;
-
//typedef unsigned short uint16_t;
-
diff -rupN elftosb-11.09.01/stdafx.h elftosb-11.09.01-new/stdafx.h
-
--- elftosb-11.09.01/stdafx.h 2013-05-07 06:04:25.055987505 +0200
-
+++ elftosb-11.09.01-new/stdafx.h 2013-05-07 06:03:23.671990775 +0200
-
@@ -27,7 +27,7 @@
-
// For Linux systems only, types.h only defines the signed
-
// integer types. This is not professional code.
-
// Update: They are defined in the header files in the more recent version of redhat enterprise gcc.
-
-#include "/usr/include/sys/types.h"
-
+#include <sys/types.h>
-
//typedef unsigned long uint32_t;
-
//typedef unsigned short uint16_t;
-
//typedef unsigned char uint8_t;
再编辑文件ltib_root/dist/lfs-5.1/elftosb/elftosb.spec,增加如下红色部分内容:
...
Source : %{name}-%{version}-%{release}.tar.gz
Patch0 : elftosb-types_h-fix.patch
BuildRoot : %{_tmppath}/%{name}
...
%setup -n %{name}-%{version}-%{release}
%patch0 -p1
%Build
make
...
再删掉/opt/freescale/ltib/usr/src/rpm/BUILD/elftosb-3.0.35-4.0.0,或其它以elftosb开头的,如有的话
到这里我在Ubuntu12.04上安装的ltib就没有什么错误了。