Author: dmacvicar Date: Tue Apr 22 00:36:23 2008 New Revision: 46936 URL: http://svn.opensuse.org/viewcvs/yast?rev=46936&view=rev Log: changed y2_add_agent to y2_add_plugin. Most of core builds, even wfm. tricky things: docu (in lot of places is just bogus docu), and the testsuite. I am still thinking about a macro that allows to add a whole skeleton, something like y2_add_plugin_subdirectory Modified: branches/tmp/dmacvicar/yast2-cmake/core/CMakeLists.txt branches/tmp/dmacvicar/yast2-cmake/core/agent-any/CMakeLists.txt branches/tmp/dmacvicar/yast2-cmake/core/agent-any/src/CMakeLists.txt branches/tmp/dmacvicar/yast2-cmake/core/agent-dummy/src/CMakeLists.txt branches/tmp/dmacvicar/yast2-cmake/core/agent-ini/src/CMakeLists.txt branches/tmp/dmacvicar/yast2-cmake/core/agent-modules/CMakeLists.txt branches/tmp/dmacvicar/yast2-cmake/core/agent-modules/src/CMakeLists.txt branches/tmp/dmacvicar/yast2-cmake/core/libycp/src/CMakeLists.txt branches/tmp/dmacvicar/yast2-cmake/core/wfm/CMakeLists.txt branches/tmp/dmacvicar/yast2-cmake/core/wfm/src/CMakeLists.txt branches/tmp/dmacvicar/yast2-cmake/devtools/devtools/cmake/modules/YastCommon.cmake Modified: branches/tmp/dmacvicar/yast2-cmake/core/CMakeLists.txt URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/core/CMakeLists.txt?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/core/CMakeLists.txt (original) +++ branches/tmp/dmacvicar/yast2-cmake/core/CMakeLists.txt Tue Apr 22 00:36:23 2008 @@ -3,9 +3,12 @@ SET( CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/modules ) -include_directories(${CMAKE_SOURCE_DIR}/liby2util-r/src/include +include_directories(${CMAKE_CURRENT_SOURCE_DIR} + ${CMAKE_SOURCE_DIR}/liby2util-r/src/include ${CMAKE_SOURCE_DIR}/liby2/src/include ${CMAKE_SOURCE_DIR}/liby2/src/include/y2 + ${CMAKE_SOURCE_DIR}/wfm/src/include + ${CMAKE_SOURCE_DIR}/wfm/src/include/wfm ${CMAKE_SOURCE_DIR}/libscr/src/include ${CMAKE_SOURCE_DIR}/libscr/src/include/scr ${CMAKE_SOURCE_DIR}/libycp/src/include @@ -16,13 +19,15 @@ include_directories( ${CMAKE_BINARY_DIR} ) find_package(Bison REQUIRED) -#find_package(Flex REQUIRED) -#include(Flex) +find_package(Flex REQUIRED) +include(Flex) add_subdirectory(libycp) add_subdirectory(liby2) add_subdirectory(libscr) +add_subdirectory(wfm) add_subdirectory(agent-dummy) add_subdirectory(agent-ini) - +add_subdirectory(agent-any) +add_subdirectory(agent-modules) Modified: branches/tmp/dmacvicar/yast2-cmake/core/agent-any/CMakeLists.txt URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/core/agent-any/CMakeLists.txt?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/core/agent-any/CMakeLists.txt (original) +++ branches/tmp/dmacvicar/yast2-cmake/core/agent-any/CMakeLists.txt Tue Apr 22 00:36:23 2008 @@ -1,17 +1,4 @@ add_subdirectory(src) -add_subdirectory(doc) -add_subdirectory(testsuite) +#add_subdirectory(doc) +#add_subdirectory(testsuite) - -########### install files ############### - - - - -#original Makefile.am contents follow: - -## -## Makefile.am for core/agent-any -## -# -#SUBDIRS = src doc testsuite Modified: branches/tmp/dmacvicar/yast2-cmake/core/agent-any/src/CMakeLists.txt URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/core/agent-any/src/CMakeLists.txt?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/core/agent-any/src/CMakeLists.txt (original) +++ branches/tmp/dmacvicar/yast2-cmake/core/agent-any/src/CMakeLists.txt Tue Apr 22 00:36:23 2008 @@ -1,43 +1,2 @@ -########### next target ############### - -SET(y2ag_anyagent_STAT_SRCS - AnyAgent.cc - AnyAgent.h - AnyAgentBasic.cc - AnyAgentComplex.cc -) - -add_library(y2ag_anyagent STATIC ${y2ag_anyagent_STAT_SRCS}) - - -########### install files ############### - - - - -#original Makefile.am contents follow: - -## -## Makefile.am for core/agent-any/src -## -# -#AM_CXXFLAGS = -DY2LOG=\"agent-any\" -# -#plugin_LTLIBRARIES = libpy2ag_anyagent.la -#noinst_LTLIBRARIES = liby2ag_anyagent.la -# -#liby2ag_anyagent_la_SOURCES = \ -# AnyAgent.cc AnyAgent.h \ -# AnyAgentBasic.cc \ -# AnyAgentComplex.cc -#liby2ag_anyagent_la_LDFLAGS = -version-info 2:0 -#liby2ag_anyagent_la_LIBADD = @AGENT_LIBADD@ -# -#libpy2ag_anyagent_la_SOURCES = \ -# $(liby2ag_anyagent_la_SOURCES) \ -# Y2CCAnyAgent.cc -#libpy2ag_anyagent_la_LDFLAGS = -version-info 2:0 -#libpy2ag_anyagent_la_LIBADD = @AGENT_LIBADD@ -# -#INCLUDES = @AGENT_INCLUDES@ +y2_add_plugin(ag_any) Modified: branches/tmp/dmacvicar/yast2-cmake/core/agent-dummy/src/CMakeLists.txt URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/core/agent-dummy/src/CMakeLists.txt?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/core/agent-dummy/src/CMakeLists.txt (original) +++ branches/tmp/dmacvicar/yast2-cmake/core/agent-dummy/src/CMakeLists.txt Tue Apr 22 00:36:23 2008 @@ -1,3 +1,3 @@ -y2_add_agent(dummy) +y2_add_plugin(dummy) Modified: branches/tmp/dmacvicar/yast2-cmake/core/agent-ini/src/CMakeLists.txt URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/core/agent-ini/src/CMakeLists.txt?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/core/agent-ini/src/CMakeLists.txt (original) +++ branches/tmp/dmacvicar/yast2-cmake/core/agent-ini/src/CMakeLists.txt Tue Apr 22 00:36:23 2008 @@ -1,3 +1,3 @@ -y2_add_agent(ini IniAgent.cc IniAgent.h IniParser.cc IniParser.h IniFile.cc IniFile.h) +y2_add_plugin(ag_ini IniAgent.cc IniAgent.h IniParser.cc IniParser.h IniFile.cc IniFile.h) Modified: branches/tmp/dmacvicar/yast2-cmake/core/agent-modules/CMakeLists.txt URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/core/agent-modules/CMakeLists.txt?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/core/agent-modules/CMakeLists.txt (original) +++ branches/tmp/dmacvicar/yast2-cmake/core/agent-modules/CMakeLists.txt Tue Apr 22 00:36:23 2008 @@ -1,18 +1,5 @@ -add_subdirectory(conf) -add_subdirectory(doc) +#add_subdirectory(conf) +#add_subdirectory(doc) add_subdirectory(src) -add_subdirectory(testsuite) +#add_subdirectory(testsuite) - -########### install files ############### - - - - -#original Makefile.am contents follow: - -## -## Makefile.am for core/agent-modules -## -# -#SUBDIRS = conf doc src testsuite Modified: branches/tmp/dmacvicar/yast2-cmake/core/agent-modules/src/CMakeLists.txt URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/core/agent-modules/src/CMakeLists.txt?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/core/agent-modules/src/CMakeLists.txt (original) +++ branches/tmp/dmacvicar/yast2-cmake/core/agent-modules/src/CMakeLists.txt Tue Apr 22 00:36:23 2008 @@ -1,44 +1,3 @@ -########### next target ############### +y2_add_plugin(ag_modules) -SET(y2ag_modules_STAT_SRCS - ModulesConf.h - ModulesConf.cc - ModulesAgent.h - ModulesAgent.cc - Y2Logger.h -) - -add_library(y2ag_modules STATIC ${y2ag_modules_STAT_SRCS}) - - -########### install files ############### - - - - -#original Makefile.am contents follow: - -## -## Makefile.am for core/agent-modules/src -## -# -#AM_CXXFLAGS = -DY2LOG=\"agent-modules\" -# -#plugin_LTLIBRARIES = libpy2ag_modules.la -#noinst_LTLIBRARIES = liby2ag_modules.la -# -#liby2ag_modules_la_SOURCES = \ -# ModulesConf.h ModulesConf.cc \ -# ModulesAgent.h ModulesAgent.cc \ -# Y2Logger.h -#liby2ag_modules_la_LDFLAGS = -version-info 2:0 -#liby2ag_modules_la_LIBADD = @AGENT_LIBADD@ -# -#libpy2ag_modules_la_SOURCES = \ -# $(liby2ag_modules_la_SOURCES) \ -# Y2CCModulesAgent.cc -#libpy2ag_modules_la_LDFLAGS = -version-info 2:0 -#libpy2ag_modules_la_LIBADD = @AGENT_LIBADD@ -# -#INCLUDES = ${AGENT_INCLUDES} Modified: branches/tmp/dmacvicar/yast2-cmake/core/libycp/src/CMakeLists.txt URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/core/libycp/src/CMakeLists.txt?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/core/libycp/src/CMakeLists.txt (original) +++ branches/tmp/dmacvicar/yast2-cmake/core/libycp/src/CMakeLists.txt Tue Apr 22 00:36:23 2008 @@ -69,10 +69,9 @@ y2crypt.cc y2crypt.h ${BISON_ycpParser_OUTPUTS} - scanner.cc ) -#add_flex_files( ${ycp_lib_SRCS} scanner.ll) +add_flex_files( ${ycp_lib_SRCS} scanner.ll) add_library(ycp SHARED ${ycp_LIB_SRCS}) target_link_libraries(ycp xcrypt ycpvalues y) Modified: branches/tmp/dmacvicar/yast2-cmake/core/wfm/CMakeLists.txt URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/core/wfm/CMakeLists.txt?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/core/wfm/CMakeLists.txt (original) +++ branches/tmp/dmacvicar/yast2-cmake/core/wfm/CMakeLists.txt Tue Apr 22 00:36:23 2008 @@ -1,17 +1,4 @@ add_subdirectory(src) -add_subdirectory(doc) -add_subdirectory(testsuite) +#add_subdirectory(doc) +#add_subdirectory(testsuite) - -########### install files ############### - - - - -#original Makefile.am contents follow: - -## -## Makefile.am for core/wfm -## -# -#SUBDIRS = src doc testsuite Modified: branches/tmp/dmacvicar/yast2-cmake/core/wfm/src/CMakeLists.txt URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/core/wfm/src/CMakeLists.txt?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/core/wfm/src/CMakeLists.txt (original) +++ branches/tmp/dmacvicar/yast2-cmake/core/wfm/src/CMakeLists.txt Tue Apr 22 00:36:23 2008 @@ -1,54 +1,11 @@ -include_directories(${CMAKE_SOURCE_DIR}/libycp/src/include ${CMAKE_SOURCE_DIR}/liby2/src/include ${CMAKE_SOURCE_DIR}/libscr/src/include ) +#include_directories(${CMAKE_SOURCE_DIR}/libycp/src/include ${CMAKE_SOURCE_DIR}/liby2/src/include ${CMAKE_SOURCE_DIR}/libscr/src/include ) +add_definitions(-DSUSEVERSION=\\\"${VERSION}\\\") +include_directories(${CMAKE_CURRENT_SOURCE_DIR}) +y2_add_plugin(wfm) -########### install files ############### +#install(FILES Y2WFMComponent.h WFMSubAgent.h WFM.h DESTINATION /include/wfm) -install(FILES Y2WFMComponent.h WFMSubAgent.h WFM.h DESTINATION /include/wfm) -#original Makefile.am contents follow: - -## -## Makefile.am for core/wfm/src -## -# -#AM_CXXFLAGS = -DY2LOG=\"wfm\" -DSUSEVERSION=\"${SUSEVERSION}\" \ -# -DLOCALEDIR=\"${localedir}\" -# -#plugin_LTLIBRARIES = libpy2wfm.la -# -#libpy2wfm_la_SOURCES = \ -# Y2WFMComponent.cc Y2WFMComponent.h \ -# Y2CCWFM.cc Y2CCWFM.h \ -# WFM.cc WFM.h \ -# WFMSubAgent.cc WFMSubAgent.h \ -# Y2SystemNamespace.cc \ -# Y2SystemNamespace.h \ -# Y2StdioFunction.cc \ -# Y2StdioFunction.h \ -# Y2SystemFunction.h \ -# Y2SystemFunction.cc -# -# -## use this for KMTrace: libpy2wfm_la_LIBADD = liby2wfm.la /opt/kde3/lib/libktrace_s.a -#libpy2wfm_la_LDFLAGS = -version-info 2:0 -#libpy2wfm_la_LIBADD = \ -# ../../scr/src/libpy2scr.la \ -# ../../libscr/src/libscr.la \ -# ../../libycp/src/libycp.la \ -# ../../liby2/src/liby2.la \ -# ${Y2UTIL_LIBS} -# -#INCLUDES = \ -# -I$(top_srcdir)/libycp/src/include \ -# -I$(top_srcdir)/liby2/src/include \ -# -I$(top_srcdir)/libscr/src/include \ -# ${Y2UTIL_CFLAGS} -# -#wfmincludedir = $(includedir)/wfm -# -#wfminclude_HEADERS = \ -# Y2WFMComponent.h \ -# WFMSubAgent.h \ -# WFM.h Modified: branches/tmp/dmacvicar/yast2-cmake/devtools/devtools/cmake/modules/YastCommon.cmake URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/dmacvicar/yast2-cmake/devtools/devtools/cmake/modules/YastCommon.cmake?rev=46936&r1=46935&r2=46936&view=diff ============================================================================== --- branches/tmp/dmacvicar/yast2-cmake/devtools/devtools/cmake/modules/YastCommon.cmake (original) +++ branches/tmp/dmacvicar/yast2-cmake/devtools/devtools/cmake/modules/YastCommon.cmake Tue Apr 22 00:36:23 2008 @@ -10,8 +10,14 @@ # YAST_IMAGE_DIR # YAST_DATA_DIR # +# Y2_ADD_AGENT(name SRCS) - adds an agent using the provided +# name. If no SRCS is provided, the current srcdir will be scanned +# for .cc files. The agent will be installed in the YaST plugin dir +# +# +# +# # - #SET( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -O3 -Wall -Woverloaded-virtual" ) #SET( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -g -O3 -Wall" ) @@ -188,17 +194,18 @@ ) ENDMACRO(GENERATE_PACKAGING) -macro(y2_add_agent) +macro(y2_add_plugin) set(name ${ARGV0}) set(srcs ${ARGV1}) if(NOT srcs) file( GLOB srcs ${CMAKE_CURRENT_SOURCE_DIR}/*.cc ) endif(NOT srcs) - add_library(pyag_${name} SHARED ${srcs}) - SET_TARGET_PROPERTIES( pyag_${name} PROPERTIES VERSION 2.0 ) - SET_TARGET_PROPERTIES( pyag_${name} PROPERTIES SOVERSION 2 ) - add_definitions(-DY2LOG=\\\"pyag_${name}\\\") - install(TARGETS pyag_${name} DESTINATION YAST_PLUGIN_DIR) -endmacro(y2_add_agent) + add_library(py${name} SHARED ${srcs}) + SET_TARGET_PROPERTIES( py${name} PROPERTIES VERSION 2.0 ) + SET_TARGET_PROPERTIES( py${name} PROPERTIES SOVERSION 2 ) + add_definitions(-DY2LOG=\\\"py${name}\\\") + install(TARGETS py${name} DESTINATION YAST_PLUGIN_DIR) +endmacro(y2_add_plugin) + -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org