Skip to content
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

mysql bug on macosx #22086

Open
lorenko opened this issue Aug 20, 2024 · 0 comments
Open

mysql bug on macosx #22086

lorenko opened this issue Aug 20, 2024 · 0 comments
Labels
Build V build error on any OS/CPU architecture. Modules: db Bugs/feature requests, that are related to the `db.*` modules. Unit: vlib Bugs/feature requests, that are related to the vlib.

Comments

@lorenko
Copy link

lorenko commented Aug 20, 2024

V doctor:

V full version: V 0.4.7 7baff15
OS: macos, macOS, 14.5, 23F79
Processor: 10 cpus, 64bit, little endian, Apple M1 Pro

getwd: /Users/lorenko/v/examples/database
vexe: /opt/homebrew/Cellar/vlang/0.4.7/libexec/v
vexe mtime: 2024-07-26 04:41:00

vroot: OK, value: /opt/homebrew/Cellar/vlang/0.4.7/libexec
VMODULES: OK, value: /Users/lorenko/.vmodules
VTMP: OK, value: /tmp/v_501

Git version: git version 2.39.2
Git vroot status: 4.3.17 (59578 commit(s) behind V master)
.git/config present: false

CC version: Apple clang version 15.0.0 (clang-1500.3.9.4)
thirdparty/tcc: N/A

What did you do?
./v -g -o vdbg cmd/v && ./vdbg mysql.v

import db.mysql

fn main() {
	mut conn := mysql.connect(
		host:     'localhost'
		port:     3306
		username: 'root'
		password: ''
		dbname:   'mysql'
	)!
	res := conn.query('show tables')!
	for row in res.rows() {
		println(row.vals.join(', '))
	}
	conn.close()
}

What did you expect to see?

connection

What did you see instead?

================== C compilation error (from cc): ==============
cc:                       ^
cc: /tmp/v_501/mysql.01J5RP27RW6P5HHEWPQCPD9YSY.tmp.c:19263:43: error: use of undeclared identifier 'REFRESH_HOSTS'
cc:         _const_db__mysql__refresh_hosts = ((u32)(REFRESH_HOSTS));
cc:                                                  ^
cc: /tmp/v_501/mysql.01J5RP27RW6P5HHEWPQCPD9YSY.tmp.c:19265:45: error: use of undeclared identifier 'REFRESH_THREADS'
cc:         _const_db__mysql__refresh_threads = ((u32)(REFRESH_THREADS));
cc:                                                    ^
cc: /tmp/v_501/mysql.01J5RP27RW6P5HHEWPQCPD9YSY.tmp.c:19266:43: error: use of undeclared identifier 'REFRESH_SLAVE'
cc:         _const_db__mysql__refresh_slave = ((u32)(REFRESH_SLAVE));
cc:                                                  ^
cc: /tmp/v_501/mysql.01J5RP27RW6P5HHEWPQCPD9YSY.tmp.c:19267:44: error: use of undeclared identifier 'REFRESH_MASTER'
cc:         _const_db__mysql__refresh_master = ((u32)(REFRESH_MASTER));
... (the original output was 235 lines long, and was truncated to 12 lines)
================================================================
(You can pass `-cg`, or `-show-c-output` as well, to print all the C error messages).
builder error: 
==================
C error found. It should never happen, when compiling pure V code.
This is a V compiler bug, please report it using `v bug file.v`,
or goto https://github.com/vlang/v/issues/new/choose .
You can also use #help on Discord: https://discord.gg/vlang .

Note

You can use the 👍 reaction to increase the issue's priority for developers.

Please note that only the 👍 reaction to the issue itself counts as a vote.
Other reactions and those to comments will not be taken into account.

@felipensp felipensp added Unit: vlib Bugs/feature requests, that are related to the vlib. Build V build error on any OS/CPU architecture. Modules: db Bugs/feature requests, that are related to the `db.*` modules. labels Aug 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build V build error on any OS/CPU architecture. Modules: db Bugs/feature requests, that are related to the `db.*` modules. Unit: vlib Bugs/feature requests, that are related to the vlib.
Projects
None yet
Development

No branches or pull requests

2 participants