使用OCI插件编译Qt时遇到严重麻烦。
Qt版本为5.6.1,Oracle Instant Client版本为12.1.0.2.0。我已经按照Qt在线手册的要求安装了基本版本和SDK版本。
然后我尝试运行以下命令:
import React from "react";
import { Calendar, Select, Radio, Col, Row } from "antd";
import { FaChevronRight, FaChevronLeft } from "react-icons/fa";
import styled from "styled-components";
const { Group, Button } = Radio;
function onPanelChange(value, mode) {
console.log(value, mode);
}
const StylingCalendar = props => (
<div style={{ width: 300, border: "1px solid #d9d9d9", borderRadius: 4 }}>
<Calendar
fullscreen={false}
headerRender={({ value, type, onChange, onTypeChange }) => {
const start = 0;
const end = 12;
const monthOptions = [];
const current = value.clone();
const localeData = value.localeData();
const months = [];
for (let i = 0; i < 12; i++) {
current.month(i);
months.push(localeData.monthsShort(current));
}
for (let index = start; index < end; index++) {
monthOptions.push(
<Select.Option className="month-item" key={`${index}`}>
{months[index]}
</Select.Option>
);
}
const month = value.month();
const year = value.year();
const options = [];
for (let i = year - 10; i < year + 10; i += 1) {
options.push(
<Select.Option key={i} value={i} className="year-item">
{i}
</Select.Option>
);
}
return (
<div style={{ padding: 10 }}>
<div style={{ marginBottom: "10px" }}>{monthOptions.name}</div>
<Row type="flex" justify="space-between">
{/* <Col>
<Group
size="small"
onChange={e => onTypeChange(e.target.value)}
value={type}
>
<Button value="month">Month</Button>
<Button value="year">Year</Button>
</Group>
</Col> */}
{/* <Col>
<Select
size="small"
dropdownMatchSelectWidth={false}
className="my-year-select"
onChange={newYear => {
const now = value.clone().year(newYear);
onChange(now);
}}
value={String(year)}
>
{options}
</Select>
</Col> */}
<Col span={8}>
<LeftArrow onClick={null} />
</Col>
<Col span={8}>
{/* <FaChevronLeft /> */}
<Select
size="small"
dropdownMatchSelectWidth={false}
value={String(month)}
onChange={selectedMonth => {
const newValue = value.clone();
newValue.month(parseInt(selectedMonth, 10));
onChange(newValue);
}}
>
{monthOptions}
</Select>
</Col>
<Col span={8}>
<RightArrow onClick={null} />
</Col>
</Row>
</div>
);
}}
onPanelChange={onPanelChange}
/>
</div>
);
const RightArrow = styled(FaChevronRight)`
cursor: pointer;
`;
const LeftArrow = styled(FaChevronLeft)`
cursor: pointer;
`;
export default StylingCalendar;
哪个产生以下输出:
./configure -I /usr/include/oracle/12.1/client64/ -L /usr/lib/oracle/12.1/client64/lib -prefix /online/daq/antonin/qt_build -plugin-sql-oci -qt-xcb -v
如您所见,OCI .so文件之一有多个未定义的引用。我尝试过在线检查,但几乎找不到这些符号的引用。
有什么想法会导致这种情况吗?缺少的.so文件?库的版本错误?