Commits

jar...@76dc99ec-c13e-774f-a8c6-c1e57a12155e  committed d966e77

Uncommitted changes

  • Participants
  • Parent commits 48cf014

Comments (0)

Files changed (2)

 SET PATH=%PostgreSQL_HOME%\lib;%PostgreSQL_HOME%\bin;%PATH%
 
 echo Generating xml
-REM Need WIN32_LEAN_AND_MEAN to exclude most windows stuff
-h2xml -I "%PostgreSQL_HOME%\include" -D WIN32_LEAN_AND_MEAN libpq-fe.h -o libpq-fe.xml 
+h2xml -I "%PostgreSQL_HOME%\include" -I "%PostgreSQL_HOME%\server" internal/libpq-int.h -o libpq-fe.xml 
 
-echo generating python libs
-xml2py libpq-fe.xml -l libpq.dll -o "libpq_fe.py"
+if exist libpq-fe.xml (
+	echo generating python libs
+	xml2py libpq-fe.xml -l libpq.dll -o "libpq_fe.py"
+)
 pgstuff = [r'c:\program files\postgresql\bin', r'c:\program files\postgresql\lib']
 os.environ['PATH'] = ';'.join(pgstuff+[os.environ['PATH']])
 
-import libpq_fe
+import libpq_fe
+#import ctypes
+#libpq = ctypes.CDLL('libpq.dll')