Skip to content

fix configure bug about cusolver #3417

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 26, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/configure
Original file line number Diff line number Diff line change
Expand Up @@ -526,7 +526,7 @@ WARNING: CUDA will not be used!
fi

#add cusolver flags for newer toolkits
if [[ $CUSOLVER -eq true ]]; then
if [ $CUSOLVER -eq true ]; then
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think this is right either, I tried it out. The issue is -eq is for integers. Should be ==.

Copy link
Contributor

Choose a reason for hiding this comment

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

A quick search online shows these would all be acceptable:

if [ "$bool" = true ]; then
if [ "$bool" = "true" ]; then

if [[ "$bool" = true ]]; then
if [[ "$bool" = "true" ]]; then
if [[ "$bool" == true ]]; then
if [[ "$bool" == "true" ]]; then

if test "$bool" = true; then
if test "$bool" = "true"; then

I propose we go with:

if [ "$CUSOLVER" = true ]; then

Dan can you just edit the PR in the web browser and accept? I'm not sure if I'd have the ability to push into this existing PR and I don't know what time zone LVHang is on. Seems like modifying it in the web browser to look like the line above would be the quickest solution.

echo "CUDA_LDLIBS += -lcusolver" >> kaldi.mk
fi

Expand Down