export 指令問題 - Linux

Hedwig avatar
By Hedwig
at 2011-12-13T19:03

Table of Contents

因為gcc不認得這些環境變數, 正確的作法是寫一個Makefile,把這些變數寫進去,再用
make編譯.

※ 引述《shihyuyao (shihyuyao)》之銘言:
: 我在 ~/.bashrc 加入
: export CPPFLAGS=-I/usr/local/sqlite/include/
: export LDFLAGS=-L/usr/local/sqlite/lib/
: export PKG_CONFIG_PATH=/usr/local/sqlite/pkgconfig/
: export LD_LIBRARY_PATH=/usr/local/sqlite/lib/
: export PATH=/usr/local/sqlite/bin:$PATH
: bin 有起作用
: 但是include,lib 好像都沒起作用
: 編譯必須指定include , lib路徑
: gcc -I /usr/local/sqlite/include/ -L /usr/local/sqlite/lib/ -lsqlite3
: 請問這樣設定有問題嗎?
: 為什麼加在 bashrc 的路徑沒作用?
: 謝謝

--
Tags: Linux

All Comments

pid為什麼會多1

Blanche avatar
By Blanche
at 2011-12-13T15:14
我用php的popen去呼叫Linux下面的指令 $exec = and#39;php /var/www/html/myapp.php andamp; andgt; /dev/null andamp; echo $!and#39;; $p = popen($exec,and#39;rand#39;); $ ...

LMDE 三百多個更新檔案?

Ivy avatar
By Ivy
at 2011-12-13T13:27
最近在虛擬機器裏面試著裝了LMDE 卻發現一個很奇怪的問題 我安裝的版本是201109 xfce (Gnome版本不知道為什麼在虛擬機下安裝完後無法開機) 進入系統後照著這個Blog的說法 http://way3sec.blogspot.com/2011/03/linux-mint-debian-editio ...

cannot connect to X server

Harry avatar
By Harry
at 2011-12-12T23:20
我在 Debian 下灌了paraview. 在文字介面下我打下 paraview 結果是 cannot connect to X server. 這是哪裡出了錯呢? 謝謝解答. - ...

Virtubox for Linux redhat6

Hedda avatar
By Hedda
at 2011-12-12T22:05
各位Linux 的前輩,想請教一個問題,關於Virtualbox 模擬redhat 6.0 x86_64 的問題. 我的電腦為Windows 7 32 bit 硬體支援均正常,我安裝virtual box 4.1.4,虛機Linux redhat 6.0 安裝正常,但無法啟動Xwindows ,startx ...

live usb

Robert avatar
By Robert
at 2011-12-12T19:12
我在usb灌完之後拿到一台電腦使用usb開機~ 可以成功啟動 但是拿到另一台電腦後就不行了... 一樣可以進入grub 但是選擇完之後就變成 (initramfs) Unable to find a media containing a live file system google了好久也沒有解答 ...