The problem of compiling opencv-0.9.7 in linux: infileincludefrom...

Source: Internet
Author: User
Tags parse error
The problem of opencv-0.9.7 compilation under linux: infileincludefrom... -- Linux general technology-Linux technology and application information, the following is read details. [I = s] This post was last edited by youxiangtt at, 2011-1-13

When I cross-compile the opencv-0.9.7 in linux,./configure can pass, but make has the following problem:
In file sorted ded from/opt/xscalve1/arm-linux/include/linux/fs. h: 19,
From cvcap_v41.cpp: 142:
/Opt/xscalve1/arm-linux/include/linux/prio_tree.h: 22: error: 'Pgoff _ T' is used
As a type, but is not defined as a type.

/Opt/xscalve1/arm-linux/include/linux/prio_tree.h: 23: error: 'Pgoff _ T' is used
As a type, but is not defined as a type.

/Opt/xscalve1/arm-linux/include/linux/prio_tree.h: 27: error: Type specifier
Omitted for parameter 'pgoff _ t'

/Opt/xscalve1/arm-linux/include/linux/prio_tree.h: 27: error: Parse error before
', 'Token

/Opt/xscalve1/arm-linux/include/linux/prio_tree.h: 29: error: 'Iter 'undeclared
(First use this function)

/Opt/xscalve1/arm-linux/include/linux/prio_tree.h: 29: error :( Each undeclared
Identifier is reported only once for each function it appears in .)

/Opt/xscalve1/arm-linux/include/linux/prio_tree.h: 29: error: 'Root' undeclared
(First use this function)

/Opt/xscalve1/arm-linux/include/linux/prio_tree.h: 30: error: 'R _ Index'
Undeclared (first use this function)

/Opt/xscalve1/arm-linux/include/linux/prio_tree.h: 31: error: 'H _ Index'
Undeclared (first use this function)


Hope someone can help me solve the problem above. I am a newbie and I have searched a lot online. Still cannot be solved. It has been a long time .........


Prio_tree.h code
CODE: # ifndef _ LINUX_PRIO_TREE_H
# Define _ LINUX_PRIO_TREE_H

Struct prio_tree_node {
Struct prio_tree_node * left;
Struct prio_tree_node * right;
Struct prio_tree_node * parent;
};

Struct prio_tree_root {
Struct prio_tree_node * prio_tree_node;
Unsigned int index_bits;
};

Struct prio_tree_iter {
Struct prio_tree_node * cur;
Unsigned longmask;
Unsigned longvalue;
Intsize_level;

Struct prio_tree_root * root;
Pgoff_tr_index;
Pgoff_th_index;
};

Static inline void prio_tree_iter_init (struct prio_tree_iter * iter,
Struct prio_tree_root * root, pgoff_t r_index, pgoff_t h_index)
{
Iter-> root = root;
Iter-> r_index = r_index;
Iter-> h_index = h_index;
}

# Define INIT_PRIO_TREE_ROOT (ptr )\
Do {\
(Ptr)-> prio_tree_node = NULL ;\
(Ptr)-> index_bits = 1 ;\
} While (0)

# Define INIT_PRIO_TREE_NODE (ptr )\
Do {\
(Ptr)-> left = (ptr)-> right = (ptr)-> parent = (ptr );\
} While (0)

# Define INIT_PRIO_TREE_ITER (ptr )\
Do {\
(Ptr)-> cur = NULL ;\
(Ptr)-> mask = 0UL ;\
(Ptr)-> value = 0UL ;\
(Ptr)-> size_level = 0 ;\
} While (0)

# Define prio_tree_entry (ptr, type, member )\
(Type *) (char *) (ptr)-(unsigned long) (& (type *) 0)-> member )))

Static inline int prio_tree_empty (const struct prio_tree_root * root)
{
Return root-> prio_tree_node = NULL;
}

Static inline int prio_tree_root (const struct prio_tree_node * node)
{
Return node-> parent = node;
}

Static inline int prio_tree_left_empty (const struct prio_tree_node * node)
{
Return node-> left = node;
}

Static inline int prio_tree_right_empty (const struct prio_tree_node * node)
{
Return node-> right = node;
}

# Endif/* _ LINUX_PRIO_TREE_H */
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.