Skip to content

Get test suite building on Linux#165

Draft
justing-bq wants to merge 2 commits intoapache-odbcfrom
test_build_linux
Draft

Get test suite building on Linux#165
justing-bq wants to merge 2 commits intoapache-odbcfrom
test_build_linux

Conversation

@justing-bq
Copy link

Rationale for this change

What changes are included in this PR?

Are these changes tested?

Are there any user-facing changes?

Comment on lines 401 to 405
run: archery docker push ${{ matrix.image }}
- name: Build
run: |
ci/scripts/cpp_build.sh $(pwd) $(pwd)/build

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This step needs to be removed, cpp_build.sh happens in here:

arrow/compose.yaml

Lines 418 to 422 in 45997d2

command: >
/bin/bash -c "
/arrow/ci/scripts/cpp_build.sh /arrow /build &&
sudo /arrow/cpp/src/arrow/flight/sql/odbc/install/unix/install_odbc.sh /usr/local/lib/libarrow_flight_sql_odbc.so &&
/arrow/ci/scripts/cpp_test.sh /arrow /build"

Comment on lines 46 to -50
TYPED_TEST(TablesTest, SQLTablesTestInputData) {
SQLWCHAR catalog_name[] = L"";
SQLWCHAR schema_name[] = L"";
SQLWCHAR table_name[] = L"";
SQLWCHAR table_type[] = L"";

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is {0} same as empty string? On Linux, SQLWCHAR is same as short (an integer data type), but on macOS/Windows, SQLWCHAR is wchar_t. Not sure if it is doable assign integer to wchar_t array.

I suggest using

ASSIGN_SQLWCHAR_ARR(catalog_name, L"");

as fix

ASSIGN_SQLWCHAR_ARR(name, wstring_var) \
size_t name##_len = std::wcslen(reinterpret_cast<const wchar_t*>(name));
#else
# define ASSIGN_SQLWCHAR_ARR(name, wstring_var) SQLWCHAR name[] = wstring_var;
Copy link

@alinaliBQ alinaliBQ Mar 26, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this works

Suggested change
# define ASSIGN_SQLWCHAR_ARR(name, wstring_var) SQLWCHAR name[] = wstring_var;
# define ASSIGN_SQLWCHAR_ARR(name, wstring_var) SQLWCHAR* name = wstring_var;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants