-
Notifications
You must be signed in to change notification settings - Fork 16
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
Package unixodbc-dev has incorrect include #36
Comments
I have the same problem, when i install the package in my docker container This issue is happening with Debian 10 and 11 with Drive 5.10.0 or 5.10.1 With driver 5.9.0 and Debian 10, PHP 7.4 but repo microsoft debian 9. Its Works !! My DockerFile |
In Debian 10, with php 8.1 changing the repository from Debian 10 to Debian 9. It will create the Docker script, I haven't tested if it will connect to the database, I believe so. Change |
Yeah, this hit us as well when trying to deploy a python application that uses |
With PHP 8.1 and Debian 11, changing the repository from 11 to 10 or from 11 to 9 does not fix the problem. I still get the error : |
Hello, Switching to the PHP image tag
https://hub.docker.com/_/php/tags?page=1&name=8.1-apache-buster |
Unfortunately, I can only use php:8.1-fpm-bullseye, I don't have the possibility to change it :/ |
i have the same problem. App built using 8.1.12-fpm-bullseye and i cannot replace this with something else. |
I also have this problem when trying to install SQL Server drivers for PHP 8.2 on Debian 11
|
I'm currently working around this on
|
I confirm that Jake's solution works, thanks ;) |
I had to run this on apt-get install unixodbc-dev=2.3* unixodbc=2.3* odbcinst1debian2=2.3* odbcinst=2.3* https://packages.debian.org/buster/unixodbc-dev 2.3.7 doesn't seem to exist on the official PPA... |
I can confirm the issue occurs for me as well, when using docker container based on debian11 distribution, The WA that worked for me for now is similar to suggested above - install 2.3.7 versions explicitly: |
Hit the same problem with pyodbc package (4.0.30) on python3.10.
Probably OK either because docker caches, or because using latest pyodbc version 4.0.35, which has binaries for x86_64_linux_glibc, so it skips compilation.. But the problem (broken include files) are still there. Problem can still be reproduced by disabling binary downloads;
Version pinning in How to check the cause
should NOT return a line like following;
because that file (unixodbc.h) is not packaged. Correct result;
|
ubuntu 22.04 i confirm Jake's solution works too. RUN ACCEPT_EULA=Y apt-get install -y RUN echo 'export PATH="$PATH:/opt/mssql-tools17/bin"' >> ~/.bashrc RUN exec bash |
We are aware of the problem and are working on an updated 2.3.11 package for unixodbc-dev, ASAP. Regards, |
I could build my PHP Docker container with Debian 9. curl https://packages.microsoft.com/keys/microsoft.asc | apt-key add - Kudos to Bjverde |
I am having the same issue, is there a timeline for a fix? |
On apt-get --allow-downgrades -y install unixodbc-dev=2.3.7 unixodbc=2.3.7 odbcinst1debian2=2.3.7 odbcinst=2.3.7 |
This issue comes up when installing pdo_sqlsrv and sqlsrv PHP extensions on Ubuntu with PHP-FPM. Reproduced on 2 machines, making an upgrade to PHP8.1 not possible. This documentation is currently not functional then: |
This is still an issue in I tried this: with Exception is the same: When I downgrade to Debian 9 everything works as expected. |
Update: works with |
Why has Microsoft started providing the unixodbc packages? Why can't we use the packages provided by Ubuntu? |
Update: works with |
In ubuntu 20 the solution was downgraded to
|
Closing as the original issue (unixodbc.h) has been resolved. |
Update package dependencies. The installers update includes several changes: - Support for Fedora v34 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Migrating dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
Update package dependencies. The installers update includes several changes: - Support for Fedora v34 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Migrating dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
Update package dependencies. The installers update includes several changes: - Support for Fedora v34 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Migrating dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
The package already installed on the system results in build errors when trying to use it: In file included from /usr/include/sql.h:19:0, from /usr/include/sqlext.h:43, from /home/runner/work/soci/soci/include/soci/odbc/soci-odbc.h:25, from /home/runner/work/soci/soci/src/backends/odbc/factory.cpp:9: /usr/include/sqltypes.h:56:10: fatal error: unixodbc.h: No such file or directory #include "unixodbc.h" ^~~~~~~~~~~~ so remove it before installing the Debian version. See microsoft/linux-package-repositories#36
Hello, I tried to use Ubuntu's MS repo in Debian 11 and it works. https://packages.microsoft.com/config/ubuntu/22.04/prod.list For Debian's repo, it generates an error
|
The package already installed on the system results in build errors when trying to use it: In file included from /usr/include/sql.h:19:0, from /usr/include/sqlext.h:43, from /home/runner/work/soci/soci/include/soci/odbc/soci-odbc.h:25, from /home/runner/work/soci/soci/src/backends/odbc/factory.cpp:9: /usr/include/sqltypes.h:56:10: fatal error: unixodbc.h: No such file or directory #include "unixodbc.h" ^~~~~~~~~~~~ so remove it before installing the Debian version. See microsoft/linux-package-repositories#36
I am running into this error now on Ubuntu 22.04 Edit: My bad, using the MS repo it failed. Using the Ubuntu repo it suceeded. |
Update package dependencies Upgrade to Laravel 9 The installers update includes several changes: - Support of Fedora v34, v35 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Upgrade dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
Update package dependencies Upgrade to Laravel 9 The installers update includes several changes: - Support of Fedora v34, v35 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Upgrade dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
Update package dependencies Upgrade to Laravel 9 The installers update includes several changes: - Support of Fedora v34, v35 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Upgrade dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
Update package dependencies Upgrade to Laravel 9 The installers update includes several changes: - Support of Fedora v34, v35 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Upgrade dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
Update package dependencies Upgrade to Laravel 9 The installers update includes several changes: - Support of Fedora v34, v35 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Upgrade dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
Update package dependencies Upgrade to Laravel 9 The installers update includes several changes: - Support of Fedora v34, v35 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Upgrade dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
Update package dependencies Upgrade to Laravel 9 The installers update includes several changes: - Support of Fedora v34, v35 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Upgrade dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
Update package dependencies Upgrade to Laravel 9 The installers update includes several changes: - Support of Fedora v34, v35 and Ubuntu v18 has been discontinued. - Add support for Fedora v37 and Ubuntu v22. - Upgrade dependencies to PHP 8.1. There is an issue with the include in the latest version of unixodbc-dev v2.3.11. As a temporary solution, we have reverted to a previous version that does not have this problem. For more information, please refer to the related issues: - microsoft/linux-package-repositories#36 - microsoft/linux-package-repositories#39
* try fix compilation for solaris * this commit for issue #3843 and #3643 changes in Types.h allow ignore problem with declaration of std::int8_t. int8_t can be defined as char or signed char. IMHO we need strong types for Poco::Int's Envelop.cpp contains initializer for EVP_CIPHER_CTX_init, because this function prototype depends on openssl version. Application.cpp contains includes especial for SOLARIS, for ioctl support ClassLoaderTest.cpp and SharedLibraryTest.cpp contains changes because loadlibrary(dlopen) doesn't load library from current directory by default LocalDateTimeTest.cpp contains changes because SOLARIS use std::tm without tm_gmtoff * fix : define of SOLARIOS OS in LocalDateTimeTest * remove unnecessary wrapper * fix output dir for windows build with multi-config build * try to fix bug with unixodbc version in linux-builds [read here](microsoft/linux-package-repositories#36) * try to fix bug with unixodbc version in linux-builds [read here](microsoft/linux-package-repositories#36) * fix : warning in main cmake for if-condition for multi-config build fix : error for linux-gcc-make-cxx20, use --allow-downgrades for unixodbc * fix : warning for cmake windows builds revert changes for linux-gcc-make-cxx20 * revert ci.yml, remove unixodbc version * try re-run build --------- Co-authored-by: Aleksandar Fabijanic <[email protected]>
* try fix compilation for solaris * this commit for issue #3843 and #3643 changes in Types.h allow ignore problem with declaration of std::int8_t. int8_t can be defined as char or signed char. IMHO we need strong types for Poco::Int's Envelop.cpp contains initializer for EVP_CIPHER_CTX_init, because this function prototype depends on openssl version. Application.cpp contains includes especial for SOLARIS, for ioctl support ClassLoaderTest.cpp and SharedLibraryTest.cpp contains changes because loadlibrary(dlopen) doesn't load library from current directory by default LocalDateTimeTest.cpp contains changes because SOLARIS use std::tm without tm_gmtoff * fix : define of SOLARIOS OS in LocalDateTimeTest * remove unnecessary wrapper * fix output dir for windows build with multi-config build * try to fix bug with unixodbc version in linux-builds [read here](microsoft/linux-package-repositories#36) * try to fix bug with unixodbc version in linux-builds [read here](microsoft/linux-package-repositories#36) * fix : warning in main cmake for if-condition for multi-config build fix : error for linux-gcc-make-cxx20, use --allow-downgrades for unixodbc * fix : warning for cmake windows builds revert changes for linux-gcc-make-cxx20 * revert ci.yml, remove unixodbc version * try re-run build --------- Co-authored-by: Aleksandar Fabijanic <[email protected]>
Describe the issue
The package unixodbc-dev is trying to include the file "unixodbc.h" in version 2.3.11. That file does not exist in the package so it fails.
In version 2.3.7 the file of "unixodbc_conf.h" is part of the installed package and is used.
In version 2.3.11 the file of "unixodbc_conf.h" is part of the installed package but for some reason, the file "unixodbc.h" is referenced in sqltypes.h which is also part of the unixodbc-dev package.
Also, the file "unixodbc_conf.h" in 2.3.11 looks like it has been generated for a particular computer, compared to the file in 2.3.7 that looks like a generic source file ready to be compiled.
When did the issue occur?
The problem was first noticed yesterday, but if you're asking when the problem originated, it is somewhere between unixodbc-dev_2.3.7 and unixodbc-dev_2.3.11.
unixodbc-dev_2.3.7/usr/include/sqltypes.h:
unixodbc-dev_2.3.11/usr/include/sqltypes.h line 55-57:
If appplicable, what package did you attempt to install, and from which repo?
Package is unixodbc-dev and appears to be installed from:
Debugging was done by manually downloading files from https://packages.microsoft.com/ubuntu/20.04/prod/pool/main/u/unixodbc/ and inspecting contents of files.
Steps to Reproduce
Short version, try to compile unixodbc into an application and it will fail
I don't have a standalone test case.
Actual Result
Fails to find file as it is looking for the wrong file name.
Expected Result
Compilation succeeds
Screenshots
Additional context
This was noticed as part of PHP's ci
The text was updated successfully, but these errors were encountered: