Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
changed the file structure to the traditional src/ebin/priv etc.
fixed a bug in sherk_ets:f2t git-svn-id: https://eper.googlecode.com/svn/trunk@76 5f96f306-4121-0410-aeb0-fb9935354dc2
- Loading branch information
1 parent
eaeb39e
commit 4b7cf8b
Showing
44 changed files
with
124 additions
and
106 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
SUBDIRS = dtop gperf ntop prf redbug sherk | ||
SUBDIRS = src bin | ||
|
||
clean-local: | ||
-find . -name "*~" -exec rm {} \; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
bindir = $(ERLANG_INSTALL_LIB_DIR_eper)/priv/bin | ||
dist_bin_SCRIPTS = dtop gperf gperf ntop redbug sherk | ||
|
||
EXTRA_DIST = $(dist_bin_SCRIPTS) |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
erlsrcdir = $(ERLANG_INSTALL_LIB_DIR_eper)/src | ||
|
||
erlsrc_DATA = ntop.erl ntopConsumer.erl \ | ||
dtop.erl dtopConsumer.erl \ | ||
gperf.erl gperfConsumer.erl gperfGtk.erl \ | ||
gperf.erl gperfConsumer.erl gperfGtk.erl \ | ||
prfNet.erl prfSys.erl prfPrc.erl prfTrc.erl \ | ||
prf.erl prfHost.erl prfTarg.erl prfClient.erl \ | ||
prfNet.erl prfSys.erl prfPrc.erl prfTrc.erl \ | ||
prf.erl prfHost.erl prfTarg.erl prfClient.erl \ | ||
prfNet.erl prfSys.erl prfPrc.erl prfTrc.erl \ | ||
prf.erl prfHost.erl prfTarg.erl prfClient.erl \ | ||
redbug.erl redbugConsumer.erl \ | ||
sherk.erl sherk_tab.erl sherk_prof.erl \ | ||
sherk_tree.erl sherk_list.erl sherk_scan.erl sherk_aquire.erl \ | ||
sherk_target.erl sherk_ets.erl | ||
|
||
gladedir = $(ERLANG_INSTALL_LIB_DIR_eper)/priv/glade | ||
glade_DATA = gperf.gladep gperf.glade \ | ||
sherk.gladep sherk.glade | ||
|
||
erlbeamdir = $(ERLANG_INSTALL_LIB_DIR_eper)/ebin | ||
erlbeam_DATA = $(patsubst %.erl, %.beam, $(erlsrc_DATA)) | ||
|
||
EXTRA_DIST = $(erlsrc_DATA) | ||
CLEANFILES = $(erlbeam_DATA) | ||
|
||
all: $(erlbeam_DATA) | ||
|
||
%.beam: %.erl | ||
echo $(PWD) | ||
$(ERLC) $(ERLCFLAGS) $< |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
%%%------------------------------------------------------------------- | ||
%%% File : sherk_tab.erl | ||
%%% Author : Mats Cronqvist <locmacr@mwlx084> | ||
%%% Description : | ||
%%% | ||
%%% Created : 21 Aug 2006 by Mats Cronqvist <locmacr@mwlx084> | ||
%%%------------------------------------------------------------------- | ||
-module(sherk_tab). | ||
|
||
-export([assert/1,check_file/1]). | ||
|
||
-import(filename,[dirname/1,join/1,basename/2]). | ||
|
||
-include_lib("kernel/include/file.hrl"). | ||
|
||
-define(LOG(T), sherk:log(process_info(self()),T)). | ||
|
||
assert(File) -> | ||
TabFile = dirname(File)++"/."++basename(File,".trz")++".etz", | ||
{ok,#file_info{mtime=MT}} = file:read_file_info(File), | ||
case file:read_file_info(TabFile) of | ||
{ok,#file_info{mtime=TabMT}} when MT < TabMT -> | ||
%% the tab file exists and is up-to-date | ||
case sherk_ets:lup(sherk_prof, file) of | ||
File -> ?LOG({is_cached,TabFile}); | ||
_ -> | ||
?LOG(restoring_tab), | ||
try sherk_ets:f2t(TabFile) | ||
catch | ||
_:X -> | ||
?LOG({deleting_bad_tab_file,X}), | ||
file:delete(TabFile), | ||
assert(File) | ||
end | ||
end; | ||
_ -> | ||
%% make tab and save it | ||
?LOG([creating_tab]), | ||
sherk_scan:go(File,'',sherk_prof,0,''), | ||
ets:insert(sherk_prof, {file, File}), | ||
try | ||
?LOG(storing_tab), | ||
sherk_ets:t2f([sherk_prof,sherk_scan],TabFile) | ||
catch | ||
_:_ -> ?LOG({creation_failed,TabFile}) | ||
end | ||
end, | ||
?LOG([folding_pids]), | ||
ets:foldl(fun store_pid/2, [], sherk_prof), | ||
?LOG([done]). | ||
|
||
store_pid({{{pid,time},P},_},_) -> ets:insert(sherk_prof,{sherk:to_str(P),P}); | ||
store_pid(_,_) -> ok. | ||
|
||
check_file(File) -> ".trz" = filename:extension(File). |
File renamed without changes.
File renamed without changes.