RE: Adding include and library directories

<[email protected]> Thu, 4 Apr 2024 14:47:42 -0700
Newsgroups gmane.lisp.ecl.general
Message-ID <[email protected]>
This makes complete sense. Thank you!
	Dave

-----Original Message-----
From: Marius Gerbershagen <[email protected]>=20
Sent: Thursday, April 4, 2024 10:58 AM
To: [email protected]; [email protected]
Subject: Re: Adding include and library directories

Dear Dave,

c::*ecl-include-directory* tells ECL where to find ECL's own header =
files. Likewise, c::*ecl-library-directory* is the location of the =
libecl.so.

For including your own header files, please use c:*user-cc-flags*, for =
example as

(setf c:*user-cc-flags* "-DWXUSINGDLL -IC:/Dave/wx/include
-IC:/Dave/wx/include/msvc")

Additional linker flags and additional libraries to link in can be =
specified in c:*user-linker-flags* and c:*user-linker-libs* =
respectively, e.g.

(setf c:*user-linker-flags* "-LC:/Dave/wx/lib/vc_x64_dll"
       c:*user-linker-libs* "-lsome_shared_library")

Note that if you are running an ECL release older than 23.9.9, both =
types of linker flags belong in c:*user-ld-flags*, although that =
variable is now deprecated because it can lead to linker flags being put =
in the wrong position in the linker command line.

Best regards,

Marius Gerbershagen

Am 02.04.24 um 19:12 schrieb [email protected]:
> I am trying to add directories for #include directives and for linking =

> libraries. The below text is my make.lisp file for building my code:
>=20
> (require 'cmp)
> (setf c:*user-cc-flags* "-DWXUSINGDLL") (setf=20
> c::*ecl-include-directory*
> "C:/Dave/wx/include,C:/Dave/wx/include/msvc")
> (setf c::*ecl-library-directory* "C:/Dave/wx/lib/vc_x64_dll")=20
> (compile-file "wx.lisp" :system-p t) (c:build-fasl "wx"
> 	      :lisp-files '("wx.obj"))
>=20
> Although
>=20
> (setf c:*user-cc-flags* "-DWXUSINGDLL")
>=20
> Is working as evidenced by the argument list to run-program, there is=20
> no evidence that the include or library directories are being used at =
all.
> Moreover, the #include directive in the wx.lisp code cannot find the=20
> specified header file.
>=20
> How are c::*ecl-include-directory* and c::*ecl-library-directory*=20
> intended to be used?
>=20
> 	Dave
>=20
>=20
>=20
>=20